增加了小地图代码

This commit is contained in:
董宏宇
2020-12-10 14:13:49 +08:00
parent 605231d307
commit e59b89164a
11 changed files with 130 additions and 14 deletions

View File

@@ -1,19 +1,23 @@
plugins {
id 'com.android.library'
}
apply plugin: 'com.android.library'
apply plugin: 'com.alibaba.arouter'
android {
compileSdkVersion 29
buildToolsVersion "29.0.3"
compileSdkVersion rootProject.ext.android.compileSdkVersion
// buildToolsVersion rootProject.ext.android.buildToolsVersion
defaultConfig {
minSdkVersion 19
targetSdkVersion 29
versionCode 1
versionName "1.0"
minSdkVersion rootProject.ext.android.minSdkVersion
targetSdkVersion rootProject.ext.android.targetSdkVersion
versionCode Integer.valueOf(VERSION_CODE)
versionName getValueFromRootProperties("${project.name.replace("-", "_").toUpperCase()}_VERSION")
javaCompileOptions {
annotationProcessorOptions {
arguments = [AROUTER_MODULE_NAME: project.getName()]
}
}
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
consumerProguardFiles "consumer-rules.pro"
consumerProguardFiles 'consumer-rules.pro'
}
buildTypes {
@@ -22,6 +26,7 @@ android {
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
@@ -30,7 +35,25 @@ android {
dependencies {
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'com.google.android.material:material:1.2.1'
implementation rootProject.ext.dependencies.androidxappcompat
implementation rootProject.ext.dependencies.androidxconstraintlayout
implementation rootProject.ext.dependencies.arouter
annotationProcessor rootProject.ext.dependencies.aroutercompiler
if (Boolean.valueOf(RELEASE)) {
api rootProject.ext.dependencies.mogomap
api rootProject.ext.dependencies.mogomapapi
api rootProject.ext.dependencies.mogoutils
api rootProject.ext.dependencies.mogocommons
api rootProject.ext.dependencies.mogoserviceapi
implementation rootProject.ext.dependencies.modulecommon
} else {
api project(":libraries:mogo-map")
api project(":libraries:mogo-map-api")
api project(":foudations:mogo-utils")
api project(":foudations:mogo-commons")
api project(':services:mogo-service-api')
implementation project(':modules:mogo-module-common')
}
}
}
apply from: new File(rootProject.rootDir, "gradle/upload.gradle").toString()

View File

@@ -0,0 +1,3 @@
GROUP=com.mogo.module
POM_ARTIFACT_ID=module-small-map
VERSION_CODE=1

View File

@@ -0,0 +1,12 @@
package com.mogo.module.small.map;
import com.mogo.service.module.IMogoModuleProvider;
/**
* @author donghongyu
* @date 12/10/20 1:36 PM
*/
public interface IMogoSmallMapProvider extends IMogoModuleProvider {
String path = "/small_map/api";
}

View File

@@ -0,0 +1,8 @@
package com.mogo.module.small.map;
/**
* @author donghongyu
* @date 12/10/20 1:35 PM
*/
public class SmallMapService {
}

View File

@@ -0,0 +1,8 @@
package com.mogo.module.small.map;
/**
* @author donghongyu
* @date 12/10/20 1:35 PM
*/
public class SmallMapView {
}

View File

@@ -0,0 +1,8 @@
package com.mogo.module.small.map;
/**
* @author donghongyu
* @date 12/10/20 1:35 PM
*/
public class SmallMapViewHandler {
}

View File

@@ -0,0 +1,46 @@
package com.mogo.module.small.map;
import android.content.Context;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;
import com.alibaba.android.arouter.facade.annotation.Route;
/**
* @author donghongyu
* @date 12/10/20 1:34 PM
*/
@Route(path = IMogoSmallMapProvider.path)
public class SmallVisionProvider implements IMogoSmallMapProvider {
private static final String TAG = "SmallVisionProvider";
@Override
public Fragment createFragment(Context context, Bundle data) {
return null;
}
@Override
public View createView(Context context) {
return null;
}
@NonNull
@Override
public String getModuleName() {
return null;
}
@Override
public int getType() {
return 0;
}
@Override
public void init(Context context) {
Log.d(TAG, "小地图模块初始化……");
}
}