carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ravipesala <...@git.apache.org>
Subject [GitHub] carbondata pull request #1469: [WIP] Spark-2.2 Carbon Integration - Phase 1
Date Wed, 22 Nov 2017 13:57:05 GMT
Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/1469#discussion_r152570799
  
    --- Diff: integration/spark-common/src/main/scala/org/apache/spark/sql/optimizer/CarbonDecoderOptimizerHelper.scala
---
    @@ -59,6 +61,26 @@ case class CarbonDictionaryTempDecoder(
     
     class CarbonDecoderProcessor {
     
    +  val rm = universe.runtimeMirror(getClass.getClassLoader)
    +
    +//  def getFields[T: TypeTag: reflect.ClassTag]( name: String, obj: T): Any = {
    +//    val im = rm.reflect(obj)
    +//    typeOf[T].members.collect {
    +//      case m : MethodSymbol if m.isCaseAccessor  && m.name.toString.equalsIgnoreCase(name)
=>
    +//        val value = im.reflectMethod(m).apply()
    +//        value
    +//    } (collection.breakOut)
    +//  }
    +
    +  def getField[T: TypeTag: reflect.ClassTag]( name: String, obj: T): Any = {
    --- End diff --
    
    Move all reflection methods to one common utility class


---

Mime
View raw message