private def get()

in scala-repl/src/main/scala/org/jetbrains/ztools/scala/handlers/impls/ObjectHandler.scala [87:107]


  private def get(instanceMirror: ru.InstanceMirror, symbol: ru.Symbol, path: String): ScalaVariableInfo = {
    if (!problems.contains(path))
      try {
        // is public property
        if (!symbol.isMethod && symbol.isTerm && symbol.asTerm.getter.isPublic) {
          val term = symbol.asTerm
          val f = instanceMirror.reflectField(term)
          val fieldPath = s"$path.${term.name.toString.trim}"
          val value = f.get
          val tpe = term.typeSignature.toString
          return ScalaVariableInfo(isAccessible = tpe != "<notype>", isLazy = term.isLazy, value, tpe,
            fieldPath, referenceManager.getRef(value, fieldPath))
        }
      } catch {
        case e: Throwable => problems(path) = ReflectionProblem(e, symbol.toString, 1)
      }
    else
      problems(path).count += 1

    INACCESSIBLE
  }