Skip to content

Commit b71e214

Browse files
committed
提交代码
提交代码
0 parents  commit b71e214

File tree

92 files changed

+13221
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+13221
-0
lines changed

HttpSender.iml

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<module external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" type="JAVA_MODULE" version="4">
3+
<component name="FacetManager">
4+
<facet type="java-gradle" name="Java-Gradle">
5+
<configuration>
6+
<option name="BUILD_FOLDER_PATH" value="$MODULE_DIR$/build" />
7+
</configuration>
8+
</facet>
9+
</component>
10+
<component name="NewModuleRootManager" inherit-compiler-output="false">
11+
<output url="file://$MODULE_DIR$/build/classes/main" />
12+
<output-test url="file://$MODULE_DIR$/build/classes/test" />
13+
<exclude-output />
14+
<content url="file://$MODULE_DIR$">
15+
<excludeFolder url="file://$MODULE_DIR$/.gradle" />
16+
</content>
17+
<orderEntry type="inheritedJdk" />
18+
<orderEntry type="sourceFolder" forTests="false" />
19+
</component>
20+
</module>
21+

app/.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/build

app/app.iml

+90
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<module external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$/.." external.system.id="GRADLE" type="JAVA_MODULE" version="4">
3+
<component name="FacetManager">
4+
<facet type="android-gradle" name="Android-Gradle">
5+
<configuration>
6+
<option name="GRADLE_PROJECT_PATH" value=":app" />
7+
</configuration>
8+
</facet>
9+
<facet type="android" name="Android">
10+
<configuration>
11+
<option name="SELECTED_BUILD_VARIANT" value="debug" />
12+
<option name="ASSEMBLE_TASK_NAME" value="assembleDebug" />
13+
<option name="COMPILE_JAVA_TASK_NAME" value="compileDebugSources" />
14+
<option name="ASSEMBLE_TEST_TASK_NAME" value="assembleDebugTest" />
15+
<option name="SOURCE_GEN_TASK_NAME" value="generateDebugSources" />
16+
<option name="TEST_SOURCE_GEN_TASK_NAME" value="generateDebugTestSources" />
17+
<option name="ALLOW_USER_CONFIGURATION" value="false" />
18+
<option name="MANIFEST_FILE_RELATIVE_PATH" value="/src/main/AndroidManifest.xml" />
19+
<option name="RES_FOLDER_RELATIVE_PATH" value="/src/main/res" />
20+
<option name="RES_FOLDERS_RELATIVE_PATH" value="file://$MODULE_DIR$/src/main/res" />
21+
<option name="ASSETS_FOLDER_RELATIVE_PATH" value="/src/main/assets" />
22+
</configuration>
23+
</facet>
24+
</component>
25+
<component name="NewModuleRootManager" inherit-compiler-output="false">
26+
<output url="file://$MODULE_DIR$/build/intermediates/classes/debug" />
27+
<exclude-output />
28+
<content url="file://$MODULE_DIR$">
29+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/debug" isTestSource="false" generated="true" />
30+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/debug" isTestSource="false" generated="true" />
31+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
32+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/debug" isTestSource="false" generated="true" />
33+
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/debug" type="java-resource" />
34+
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/debug" type="java-resource" />
35+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/test/debug" isTestSource="true" generated="true" />
36+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/test/debug" isTestSource="true" generated="true" />
37+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/test/debug" isTestSource="true" generated="true" />
38+
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/test/debug" isTestSource="true" generated="true" />
39+
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/test/debug" type="java-test-resource" />
40+
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/test/debug" type="java-test-resource" />
41+
<sourceFolder url="file://$MODULE_DIR$/src/debug/res" type="java-resource" />
42+
<sourceFolder url="file://$MODULE_DIR$/src/debug/resources" type="java-resource" />
43+
<sourceFolder url="file://$MODULE_DIR$/src/debug/assets" type="java-resource" />
44+
<sourceFolder url="file://$MODULE_DIR$/src/debug/aidl" isTestSource="false" />
45+
<sourceFolder url="file://$MODULE_DIR$/src/debug/java" isTestSource="false" />
46+
<sourceFolder url="file://$MODULE_DIR$/src/debug/jni" isTestSource="false" />
47+
<sourceFolder url="file://$MODULE_DIR$/src/debug/rs" isTestSource="false" />
48+
<sourceFolder url="file://$MODULE_DIR$/src/main/res" type="java-resource" />
49+
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
50+
<sourceFolder url="file://$MODULE_DIR$/src/main/assets" type="java-resource" />
51+
<sourceFolder url="file://$MODULE_DIR$/src/main/aidl" isTestSource="false" />
52+
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
53+
<sourceFolder url="file://$MODULE_DIR$/src/main/jni" isTestSource="false" />
54+
<sourceFolder url="file://$MODULE_DIR$/src/main/rs" isTestSource="false" />
55+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
56+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
57+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
58+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
59+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
60+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
61+
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
62+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/assets" />
63+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/bundles" />
64+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/classes" />
65+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/coverage-instrumented-classes" />
66+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dependency-cache" />
67+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dex" />
68+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dex-cache" />
69+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental" />
70+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/jacoco" />
71+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/javaResources" />
72+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/libs" />
73+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/lint" />
74+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/manifests" />
75+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/ndk" />
76+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/pre-dexed" />
77+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/proguard" />
78+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/res" />
79+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/rs" />
80+
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/symbols" />
81+
<excludeFolder url="file://$MODULE_DIR$/build/outputs" />
82+
</content>
83+
<orderEntry type="jdk" jdkName="Android API 21 Platform" jdkType="Android SDK" />
84+
<orderEntry type="sourceFolder" forTests="false" />
85+
<orderEntry type="library" exported="" name="support-v4-22.0.0" level="project" />
86+
<orderEntry type="library" exported="" name="support-annotations-22.0.0" level="project" />
87+
<orderEntry type="library" exported="" name="appcompat-v7-22.0.0" level="project" />
88+
</component>
89+
</module>
90+

app/build.gradle

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
apply plugin: 'com.android.library'
2+
3+
android {
4+
compileSdkVersion 21
5+
buildToolsVersion "21.1.2"
6+
7+
defaultConfig {
8+
applicationId "derson.com.httpsender"
9+
minSdkVersion 17
10+
targetSdkVersion 21
11+
versionCode 1
12+
versionName "1.0"
13+
}
14+
buildTypes {
15+
release {
16+
minifyEnabled false
17+
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
18+
}
19+
}
20+
}
21+
22+
dependencies {
23+
compile fileTree(dir: 'libs', include: ['*.jar'])
24+
compile 'com.android.support:appcompat-v7:22.0.0'
25+
}

app/proguard-rules.pro

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Add project specific ProGuard rules here.
2+
# By default, the flags in this file are appended to flags specified
3+
# in /Users/chengli/Desktop/sdk/tools/proguard/proguard-android.txt
4+
# You can edit the include path and order by changing the proguardFiles
5+
# directive in build.gradle.
6+
#
7+
# For more details, see
8+
# http://developer.android.com/guide/developing/tools/proguard.html
9+
10+
# Add any project specific keep options here:
11+
12+
# If your project uses WebView with JS, uncomment the following
13+
# and specify the fully qualified class name to the JavaScript interface
14+
# class:
15+
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16+
# public *;
17+
#}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package derson.com.httpsender;
2+
3+
import android.app.Application;
4+
import android.test.ApplicationTestCase;
5+
6+
/**
7+
* <a href="http://d.android.com/tools/testing/testing_android.html">Testing Fundamentals</a>
8+
*/
9+
public class ApplicationTest extends ApplicationTestCase<Application> {
10+
public ApplicationTest() {
11+
super(Application.class);
12+
}
13+
}

app/src/main/AndroidManifest.xml

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
2+
package="derson.com.httpsender">
3+
4+
<application android:allowBackup="true" android:label="@string/app_name"
5+
android:icon="@drawable/ic_launcher" android:theme="@style/AppTheme">
6+
7+
</application>
8+
9+
</manifest>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
/*
2+
Android Asynchronous Http Client
3+
Copyright (c) 2011 James Smith <[email protected]>
4+
http://loopj.com
5+
6+
Licensed under the Apache License, Version 2.0 (the "License");
7+
you may not use this file except in compliance with the License.
8+
You may obtain a copy of the License at
9+
10+
http://www.apache.org/licenses/LICENSE-2.0
11+
12+
Unless required by applicable law or agreed to in writing, software
13+
distributed under the License is distributed on an "AS IS" BASIS,
14+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
See the License for the specific language governing permissions and
16+
limitations under the License.
17+
*/
18+
19+
package derson.com.httpsender.AsyncHttpClient;
20+
21+
/**
22+
* Internal class, used to make some asserts, throw AssertError if asserts fail.
23+
*/
24+
class AssertUtils {
25+
26+
private AssertUtils() {
27+
}
28+
29+
public static void asserts(final boolean expression, final String failedMessage) {
30+
if (!expression) {
31+
throw new AssertionError(failedMessage);
32+
}
33+
}
34+
}

0 commit comments

Comments
 (0)