Nadav Samet created SPARK-23511:
-----------------------------------

             Summary: Catalyst: Implement GetField
                 Key: SPARK-23511
                 URL: https://issues.apache.org/jira/browse/SPARK-23511
             Project: Spark
          Issue Type: New Feature
          Components: SQL
    Affects Versions: 2.2.1
            Reporter: Nadav Samet


Similar to Invoke, InvokeStatic and NewInstance, it would be nice to have 
GetStaticField(expression, fieldName).

My use case is invoking a method on a companion object given the class of the 
companion object itself - it turns out they are not static. I'd like to be able 
to do something like this:

Invoke(GetStaticField(cls, "MODULE$", ...), "someMethod", ...)

My workaround is passing the companion to Invoke() directly to 
Literal.fromObject but I think having a general solution to call method on 
companion objects would be better.

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to