├── news ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ └── values │ │ │ │ └── strings.xml │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── material │ │ │ └── com │ │ │ └── news │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── material │ │ └── com │ │ └── news │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── page_body ├── .gitignore ├── libs │ └── core-release.aar ├── src │ └── main │ │ ├── res │ │ ├── values │ │ │ └── strings.xml │ │ └── layout │ │ │ ├── page_body_fi.xml │ │ │ └── page_body_se.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ └── com │ │ └── cangwang │ │ ├── page_body │ │ ├── BodyCreate.java │ │ └── PageBodyModule.java │ │ └── service │ │ └── BodyService.java ├── proguard-rules.pro └── build.gradle ├── page_name ├── .gitignore ├── src │ └── main │ │ ├── res │ │ ├── values │ │ │ └── strings.xml │ │ └── layout │ │ │ └── page_name_layout.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ └── com │ │ └── cangwang │ │ └── page_name │ │ ├── NameCreate.java │ │ └── PageNameModule.java ├── proguard-rules.pro └── build.gradle ├── page_view ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ └── strings.xml │ │ │ └── layout │ │ │ │ └── page_view_layout.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ │ └── com │ │ │ └── cangwang │ │ │ └── page_view │ │ │ └── PageViewModule.java │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── cangwang │ │ │ └── page_view │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── cangwang │ │ └── page_view │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── page_body_bt ├── .gitignore ├── src │ └── main │ │ ├── res │ │ ├── values │ │ │ └── strings.xml │ │ └── layout │ │ │ ├── page_body_bt.xml │ │ │ └── page_body_bts.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ └── com │ │ └── cangwang │ │ └── page_body_bt │ │ └── PageBodyBTModule.java ├── proguard-rules.pro └── build.gradle ├── .DS_Store ├── app ├── lib │ └── core-release.aar ├── src │ └── main │ │ ├── res │ │ ├── values │ │ │ ├── strings.xml │ │ │ ├── colors.xml │ │ │ ├── dimens.xml │ │ │ └── styles.xml │ │ ├── drawable-xxhdpi │ │ │ └── dream.jpg │ │ ├── mipmap-hdpi │ │ │ └── ic_launcher.png │ │ ├── mipmap-mdpi │ │ │ └── ic_launcher.png │ │ ├── mipmap-xhdpi │ │ │ └── ic_launcher.png │ │ ├── mipmap-xxhdpi │ │ │ └── ic_launcher.png │ │ ├── mipmap-xxxhdpi │ │ │ └── ic_launcher.png │ │ ├── values-w820dp │ │ │ └── dimens.xml │ │ ├── layout │ │ │ ├── activity_start.xml │ │ │ ├── activity_example.xml │ │ │ ├── activity_main_module.xml │ │ │ ├── activity_main.xml │ │ │ └── fragment_module.xml │ │ └── menu │ │ │ └── navigation.xml │ │ ├── java │ │ └── com │ │ │ └── cangwang │ │ │ └── modulebus │ │ │ ├── ModuleExampleActivity.java │ │ │ ├── AdaviceActivity.java │ │ │ ├── ViewPagerAdapter.java │ │ │ ├── ModuleMainActivity.java │ │ │ ├── PageConfig.java │ │ │ ├── ModuleApplication.java │ │ │ ├── ModuleExampleFragment.java │ │ │ └── MainActivity.java │ │ └── AndroidManifest.xml ├── .gitignore ├── proguard-rules.pro ├── build.gradle └── fat-aar.gradle ├── a ├── src │ ├── debug │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── colors.xml │ │ │ └── layout │ │ │ │ ├── activity_main.xml │ │ │ │ └── layout_a.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ │ └── com │ │ │ └── cangwang │ │ │ └── a │ │ │ └── MainActivity.java │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ └── strings.xml │ │ │ └── layout │ │ │ │ └── layout_a.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ │ └── com │ │ │ └── cangwang │ │ │ └── a │ │ │ └── FragmentA.java │ └── release │ │ └── AndroidManifest.xml ├── .gitignore ├── proguard-rules.pro └── build.gradle ├── b ├── src │ └── main │ │ ├── res │ │ ├── values │ │ │ └── strings.xml │ │ └── layout │ │ │ ├── activity_b.xml │ │ │ └── layout_b.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ └── com │ │ └── cangwang │ │ └── b │ │ ├── BActivity.java │ │ └── FragmentB.java ├── .gitignore ├── proguard-rules.pro └── build.gradle ├── .idea ├── caches │ ├── gradle_models.ser │ └── build_file_checksums.ser ├── copyright │ └── profiles_settings.xml ├── encodings.xml ├── compiler.xml ├── vcs.xml ├── runConfigurations.xml ├── checkstyle-idea.xml ├── jarRepositories.xml ├── gradle.xml ├── modules.xml ├── codeStyles │ └── Project.xml ├── misc.xml └── workspace.xml ├── base ├── src │ └── main │ │ ├── res │ │ ├── values │ │ │ ├── strings.xml │ │ │ ├── colors.xml │ │ │ └── styles.xml │ │ └── mipmap-xhdpi │ │ │ └── ic_launcher.png │ │ ├── java │ │ └── com │ │ │ └── cangwang │ │ │ └── base │ │ │ └── IFBClient.java │ │ └── AndroidManifest.xml ├── .gitignore ├── proguard-rules.pro ├── gradle.properties └── build.gradle ├── core ├── src │ └── main │ │ ├── res │ │ └── values │ │ │ └── strings.xml │ │ ├── java │ │ └── com │ │ │ └── cangwang │ │ │ └── core │ │ │ ├── IBaseClient.java │ │ │ ├── cwmodule │ │ │ ├── Component.java │ │ │ ├── ELAbsModule.java │ │ │ ├── ELModuleFactory.java │ │ │ ├── ELBasicModule.java │ │ │ ├── ELModuleContext.java │ │ │ ├── ModuleManageFragment.java │ │ │ ├── ModuleManagerView.java │ │ │ ├── ModuleManageActivity.java │ │ │ ├── ModuleManager.java │ │ │ ├── FragmentModuleManager.java │ │ │ ├── ViewModuleManager.java │ │ │ └── ActivityModuleManager.java │ │ │ ├── util │ │ │ ├── ModuleImpl.java │ │ │ └── ModuleUtil.java │ │ │ ├── info │ │ │ └── MethodInfo.java │ │ │ ├── ModuleEvent.java │ │ │ ├── ModuleClient.java │ │ │ └── ModuleBus.java │ │ └── AndroidManifest.xml ├── .gitignore ├── proguard-rules.pro └── build.gradle ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── settings.gradle ├── .gitignore ├── local.properties ├── common_config.gradle ├── gradle.properties ├── ModuleBus.iml ├── README.md ├── gradlew.bat └── gradlew /news/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /page_body/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /page_name/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /page_view/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /page_body_bt/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/.DS_Store -------------------------------------------------------------------------------- /app/lib/core-release.aar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/lib/core-release.aar -------------------------------------------------------------------------------- /a/src/debug/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | a 3 | 4 | -------------------------------------------------------------------------------- /a/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | a 3 | 4 | -------------------------------------------------------------------------------- /b/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | b 3 | 4 | -------------------------------------------------------------------------------- /.idea/caches/gradle_models.ser: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/.idea/caches/gradle_models.ser -------------------------------------------------------------------------------- /base/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Base 3 | 4 | -------------------------------------------------------------------------------- /core/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Core 3 | 4 | -------------------------------------------------------------------------------- /news/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | News 3 | 4 | -------------------------------------------------------------------------------- /page_body/libs/core-release.aar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/page_body/libs/core-release.aar -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | ModuleBus 3 | 4 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /.idea/caches/build_file_checksums.ser: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/.idea/caches/build_file_checksums.ser -------------------------------------------------------------------------------- /page_body/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Page_body 3 | 4 | -------------------------------------------------------------------------------- /page_name/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Page_Name 3 | 4 | -------------------------------------------------------------------------------- /page_view/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Page_view 3 | 4 | -------------------------------------------------------------------------------- /page_body_bt/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | page_body_bt 3 | 4 | -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app', ':base', ':a', ':b', ':core', ':page_name', ':page_body', ':page_body_bt', ':page_view', ':news' 2 | -------------------------------------------------------------------------------- /a/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/dream.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/src/main/res/drawable-xxhdpi/dream.jpg -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /b/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | -------------------------------------------------------------------------------- /core/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /base/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | -------------------------------------------------------------------------------- /base/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cangwang/ModuleBus/HEAD/base/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | *.iml 10 | app/app.iml -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/IBaseClient.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core; 2 | 3 | /** 4 | * Created by zjl on 16/11/18. 5 | */ 6 | 7 | public class IBaseClient { 8 | } 9 | -------------------------------------------------------------------------------- /.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/cwmodule/Component.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core.cwmodule; 2 | 3 | /** 4 | * Created by air on 2016/12/26. 5 | */ 6 | 7 | public class Component { 8 | } 9 | -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /base/src/main/java/com/cangwang/base/IFBClient.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.base; 2 | 3 | 4 | import com.cangwang.core.IBaseClient; 5 | 6 | /** 7 | * Created by air on 16/11/22. 8 | */ 9 | 10 | public class IFBClient extends IBaseClient { 11 | } 12 | -------------------------------------------------------------------------------- /a/src/debug/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16dp 4 | 16dp 5 | 6 | -------------------------------------------------------------------------------- /base/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | 7 | -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/util/ModuleImpl.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core.util; 2 | 3 | import android.app.Application; 4 | 5 | /** 6 | * Created by cangwang on 2017/2/25. 7 | */ 8 | 9 | public interface ModuleImpl { 10 | void onLoad(Application app); 11 | } 12 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Tue Oct 12 17:31:31 CST 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip 7 | -------------------------------------------------------------------------------- /a/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /a/src/release/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /base/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /core/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /news/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /page_view/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /page_body_bt/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /page_body/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /page_name/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/values-w820dp/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 64dp 6 | 7 | -------------------------------------------------------------------------------- /local.properties: -------------------------------------------------------------------------------- 1 | ## This file must *NOT* be checked into Version Control Systems, 2 | # as it contains information specific to your local configuration. 3 | # 4 | # Location of the SDK. This is only used by Gradle. 5 | # For customization when using a Version Control System, please read the 6 | # header note. 7 | #Tue Oct 12 16:20:39 CST 2021 8 | ndk.dir=D\:\\android_sdk\\ndk-bundle 9 | sdk.dir=E\:\\AndroidSdk 10 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_start.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/util/ModuleUtil.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core.util; 2 | 3 | import java.util.Map; 4 | 5 | /** 6 | * Created by air on 2016/12/26. 7 | */ 8 | 9 | public class ModuleUtil { 10 | 11 | public static boolean empty(Map c){ 12 | return c == null || c.isEmpty(); 13 | } 14 | 15 | public static boolean empty(String s){ 16 | return s == null || s.isEmpty(); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /base/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /common_config.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | project.ext { 3 | compileSdkVersion = 30 4 | buildToolsVersion = "30.0.3" 5 | minSdkVersion = 21 6 | targetSdkVersion = 30 7 | applicationId = "com.cangwang.modulebus" 8 | 9 | isDebug = false; 10 | isLib = false; 11 | 12 | //混淆 13 | // minifyEnable = true 14 | // shrinkResEnable = minifyEnable 15 | } 16 | -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/info/MethodInfo.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core.info; 2 | 3 | import java.lang.reflect.Method; 4 | 5 | /** 6 | * Created by air on 2016/12/18. 7 | */ 8 | 9 | public class MethodInfo { 10 | public String methodName; 11 | public Method m; 12 | public boolean single; 13 | 14 | public MethodInfo(String methodName, Method m, boolean single) { 15 | this.methodName = methodName; 16 | this.m = m; 17 | this.single = single; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /page_body/src/main/java/com/cangwang/page_body/BodyCreate.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.page_body; 2 | 3 | import android.app.Application; 4 | import android.util.Log; 5 | 6 | import com.cangwang.core.util.ModuleImpl; 7 | 8 | /** 9 | * Created by cangwang on 2017/2/25. 10 | */ 11 | 12 | public class BodyCreate implements ModuleImpl{ 13 | @Override 14 | public void onLoad(Application app) { 15 | for (int i=0;i<5;i++){ 16 | Log.v("BodyCreate","BodyCreate onLoad"); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /page_name/src/main/java/com/cangwang/page_name/NameCreate.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.page_name; 2 | 3 | import android.app.Application; 4 | import android.util.Log; 5 | 6 | import com.cangwang.core.util.ModuleImpl; 7 | 8 | /** 9 | * Created by cangwang on 2017/2/25. 10 | */ 11 | 12 | public class NameCreate implements ModuleImpl{ 13 | @Override 14 | public void onLoad(Application app) { 15 | for (int i=0;i<5;i++){ 16 | Log.v("NameCreate","NameCreate onLoad"); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /page_view/src/test/java/com/cangwang/page_view/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.page_view; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() throws Exception { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /news/src/test/java/material/com/news/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package material.com.news; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() throws Exception { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/ModuleEvent.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core; 2 | 3 | import java.lang.annotation.Documented; 4 | import java.lang.annotation.ElementType; 5 | import java.lang.annotation.Retention; 6 | import java.lang.annotation.RetentionPolicy; 7 | import java.lang.annotation.Target; 8 | 9 | /** 10 | * Created by zjl on 16/11/17. 11 | */ 12 | @Retention(RetentionPolicy.RUNTIME) 13 | @Target({ElementType.METHOD,ElementType.FIELD}) 14 | @Documented 15 | public @interface ModuleEvent { 16 | Class coreClientClass(); 17 | boolean single() default false; 18 | } 19 | -------------------------------------------------------------------------------- /app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 14 | 15 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/checkstyle-idea.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 14 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/menu/navigation.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 9 | 12 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_example.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /b/src/main/res/layout/activity_b.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /page_body/src/main/res/layout/page_body_fi.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 16 | 17 | -------------------------------------------------------------------------------- /page_name/src/main/res/layout/page_name_layout.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 16 | 17 | -------------------------------------------------------------------------------- /page_view/src/main/res/layout/page_view_layout.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 16 | 17 | -------------------------------------------------------------------------------- /app/src/main/java/com/cangwang/modulebus/ModuleExampleActivity.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.modulebus; 2 | 3 | import android.os.Bundle; 4 | 5 | import androidx.annotation.Nullable; 6 | import androidx.appcompat.app.AppCompatActivity; 7 | 8 | /** 9 | * Created by air on 2016/12/28. 10 | */ 11 | 12 | public class ModuleExampleActivity extends AppCompatActivity { 13 | 14 | @Override 15 | protected void onCreate(@Nullable Bundle savedInstanceState) { 16 | super.onCreate(savedInstanceState); 17 | setContentView(R.layout.activity_example); 18 | getSupportFragmentManager().beginTransaction().replace(R.id.container,new ModuleExampleFragment()).commit(); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /page_body/src/main/java/com/cangwang/service/BodyService.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.service; 2 | 3 | import android.app.Service; 4 | import android.content.Intent; 5 | import android.os.IBinder; 6 | import android.support.annotation.Nullable; 7 | 8 | 9 | /** 10 | * Created by air on 2017/2/19. 11 | */ 12 | 13 | public class BodyService extends Service{ 14 | @Nullable 15 | @Override 16 | public IBinder onBind(Intent intent) { 17 | return null; 18 | } 19 | 20 | @Override 21 | public void onCreate() { 22 | super.onCreate(); 23 | } 24 | 25 | @Override 26 | public void onDestroy() { 27 | super.onDestroy(); 28 | } 29 | 30 | 31 | } 32 | -------------------------------------------------------------------------------- /page_body_bt/src/main/res/layout/page_body_bt.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 16 | 17 | -------------------------------------------------------------------------------- /a/src/debug/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /b/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/cwmodule/ELAbsModule.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core.cwmodule; 2 | 3 | import android.os.Bundle; 4 | 5 | import java.util.Map; 6 | 7 | /** 8 | * Created by cangwang on 2016/12/26. 9 | */ 10 | 11 | public abstract class ELAbsModule { 12 | 13 | public abstract void init(ELModuleContext moduleContext,String extend); 14 | 15 | public abstract void onSaveInstanceState(Bundle outState); 16 | 17 | public abstract void onResume(); 18 | 19 | public abstract void onPause(); 20 | 21 | public abstract void onStop(); 22 | 23 | public abstract void onOrientationChanges(boolean isLandscape); 24 | 25 | public abstract void onDestroy(); 26 | 27 | } 28 | -------------------------------------------------------------------------------- /a/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /a/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /b/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /base/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /core/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /core/src/main/java/com/cangwang/core/ModuleClient.java: -------------------------------------------------------------------------------- 1 | package com.cangwang.core; 2 | 3 | import java.util.ArrayList; 4 | 5 | /** 6 | * Created by zjl on 2016/11/23. 7 | */ 8 | 9 | public class ModuleClient { 10 | Class clientClass; 11 | ArrayList clientList; 12 | 13 | public ModuleClient(Class clientClass,ArrayList clients){ 14 | this.clientClass = clientClass; 15 | this.clientList = clients; 16 | } 17 | public ModuleClient(Class clientClass){ 18 | this.clientClass = clientClass; 19 | } 20 | 21 | public void addClient(Object c){ 22 | if (clientList == null) 23 | clientList = new ArrayList<>(); 24 | clientList.add(c); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /news/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in D:\android_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 | #} 18 | -------------------------------------------------------------------------------- /page_body/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /page_body_bt/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /page_name/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /page_view/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/air/Library/Android/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 | #} 18 | -------------------------------------------------------------------------------- /b/src/main/res/layout/layout_b.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 |