Reflection
object Reflection
Content copied to clipboard
Types
InstanceMethodDispatcher
Link copied to clipboard
class InstanceMethodDispatcher(instance: Any, methodName: String, matchNumbersLeniently: Boolean, matchClassesQualnames: Boolean, resolveAmbiguousSpecificity: Boolean) : FunctionDispatcher
Content copied to clipboard
Dynamic multiple dispatch for Any Kotlin instances by methodName.
PathElement
Link copied to clipboard
data class PathElement(type: Reflection.PathElementType, name: String, doEval: Boolean, params: List<Any?>)
Content copied to clipboard
PathElementType
Link copied to clipboard
Functions
evalKotlinString
Link copied to clipboard
makeInstanceMethodDispatcher
Link copied to clipboard
fun makeInstanceMethodDispatcher(instance: Any, methodName: String): Reflection.InstanceMethodDispatcher
Content copied to clipboard
parseKotlinPath
Link copied to clipboard
readClassProperty
Link copied to clipboard
readInstanceItem
Link copied to clipboard
readInstanceProperty
Link copied to clipboard
removeInstanceItem
Link copied to clipboard
removeInstancePath
Link copied to clipboard
fun removeInstancePath(instance: Any?, path: List<Reflection.PathElement>)
Content copied to clipboard
resolveInstancePath
Link copied to clipboard
fun resolveInstancePath(instance: Any?, path: List<Reflection.PathElement>): Any?
Content copied to clipboard
setInstanceItem
Link copied to clipboard
setInstancePath
Link copied to clipboard
fun setInstancePath(instance: Any?, path: List<Reflection.PathElement>, value: Any?)
Content copied to clipboard
setInstanceProperty
Link copied to clipboard
fun <T> setInstanceProperty(instance: Any, propertyName: String, value: T?)
Content copied to clipboard
splitToplevelExprs
Link copied to clipboard
fun splitToplevelExprs(code: String, delimiters: CharSequence = ",", bracketPairs: Map<Char, Char> = mapOf('(' to ')', '[' to ']'), maxParts: Int = 0, backSlashEscape: Boolean = false): List<String>
Content copied to clipboard
stringifyKotlinPath
Link copied to clipboard
Properties
Sources
jvm source
Link copied to clipboard