code style opt, reduce build time : 1m30s
This commit is contained in:
@@ -1,14 +1,6 @@
|
||||
package com.zhidao.roadcondition.model
|
||||
|
||||
|
||||
fun CommonConfig.isActiveNonNull():Boolean{
|
||||
return active!=null
|
||||
}
|
||||
|
||||
//fun CommonConfig.isPromotionNonNull():Boolean{
|
||||
// return promotion!=null
|
||||
//}
|
||||
|
||||
class CommonConfig {
|
||||
|
||||
var active:Active //活动配置
|
||||
|
||||
@@ -1,16 +1,13 @@
|
||||
package com.zhidao.roadcondition.model.proxy
|
||||
|
||||
import androidx.annotation.IntDef
|
||||
import java.lang.annotation.Retention
|
||||
import java.lang.annotation.RetentionPolicy
|
||||
|
||||
|
||||
const val INFO_TYPE_GONE = 0
|
||||
const val INFO_TYPE_SHOW = 1
|
||||
|
||||
|
||||
@IntDef(INFO_TYPE_GONE, INFO_TYPE_SHOW)
|
||||
@Retention(RetentionPolicy.SOURCE)
|
||||
@Retention(AnnotationRetention.SOURCE)
|
||||
annotation class ActiveInfoType
|
||||
|
||||
fun isActiveShow(@ActiveInfoType type: Int): Boolean {
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
package com.zhidao.roadcondition.model.proxy
|
||||
|
||||
import androidx.annotation.IntDef
|
||||
import java.lang.annotation.Retention
|
||||
import java.lang.annotation.RetentionPolicy
|
||||
|
||||
|
||||
const val INFO_TYPE_IMG = 0 //图片
|
||||
@@ -12,5 +10,5 @@ const val INFO_TYPE_WORD = 3
|
||||
|
||||
|
||||
@IntDef(INFO_TYPE_IMG, INFO_TYPE_VIDEO, INFO_TYPE_VOICE, INFO_TYPE_WORD)
|
||||
@Retention(RetentionPolicy.SOURCE)
|
||||
@Retention(AnnotationRetention.SOURCE)
|
||||
annotation class InformationsType
|
||||
|
||||
Reference in New Issue
Block a user