findFieldValue

fun Any.findFieldValue(findSuper: Boolean? = null, query: FieldQuery.() -> Unit): Any?

按查询条件查找字段并直接获取值。

val value = instance.findFieldValue {
filter { name.startsWith("m") }
type(String::class.java)
}

Parameters

findSuper

null=智能搜索(默认), false=仅当前类, true=强制搜索继承链

query

查询条件块