Tushar Gosavi created APEXMALHAR-2536:
-----------------------------------------

             Summary: Support for setters on nested Pojo
                 Key: APEXMALHAR-2536
                 URL: https://issues.apache.org/jira/browse/APEXMALHAR-2536
             Project: Apache Apex Malhar
          Issue Type: Improvement
            Reporter: Tushar Gosavi
            Priority: Minor


Getters support getting values from nested Pojo by adding suitable 
methods/fields in the chain

for example
{code}
class Inner {
  private int b;
  public int getB() { return b; }
  public void setB(int b) { this.b = b; }
}

class Nested {
  private in a;
  private Inner inner;
  public int getA() { return a; }
  public void getA(int a) { this.a = a; }
  public Inner getInner() { return inner; }
  public void setInner(Inner i) { this.inner = i; }
}
{code}

With above objects  If getter is specified as `inner.b` then the expression is 
created with
`object.getInner().getB()` which compiles and gives result correctly. 

If setter is specified with same expression it fails to compile as inner is a 
private object.
We plan to include similar functionality for setters by following chain of 
objects and constructing valid java expressions.






--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to