GigaSpaces XAP 10.0.1 API

org.openspaces.jpa.openjpa.query
Class FieldPathNode

java.lang.Object
  extended by org.openspaces.jpa.openjpa.query.FieldPathNode
All Implemented Interfaces:
Serializable, org.apache.openjpa.kernel.exps.Path, org.apache.openjpa.kernel.exps.Value, ExpressionNode

public class FieldPathNode
extends Object
implements org.apache.openjpa.kernel.exps.Path, ExpressionNode

Represents a field path in the expression tree. The get(FieldMetaData, boolean) method is called when passing through each ClassMetaData so this method saves the entire path to the given column so it can be later converted to a string.

Since:
8.0
Author:
idan
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.openspaces.jpa.openjpa.query.ExpressionNode
ExpressionNode.NodeType
 
Constructor Summary
FieldPathNode()
           
 
Method Summary
 void acceptVisit(org.apache.openjpa.kernel.exps.ExpressionVisitor visitor)
           
 void appendSql(StringBuilder sql)
          Appends the node SQL string to the string builder.
 void get(org.apache.openjpa.meta.FieldMetaData fmd, boolean nullTraversal)
           
 void get(org.apache.openjpa.meta.FieldMetaData fieldMetaData, org.apache.openjpa.meta.XMLMetaData xmlMetaData)
           
 void get(org.apache.openjpa.meta.XMLMetaData xmlMetaData, String name)
           
 String getAlias()
           
 String getCorrelationVar()
           
 org.apache.openjpa.meta.ClassMetaData getMetaData()
           
 String getName()
           
 ExpressionNode.NodeType getNodeType()
          Gets the node type
 org.apache.openjpa.kernel.exps.Path getPath()
           
 String getSchemaAlias()
           
 org.apache.openjpa.kernel.exps.Value getSelectAs()
           
 Class getType()
           
 org.apache.openjpa.meta.XMLMetaData getXmlMapping()
           
 boolean isAggregate()
           
 boolean isVariable()
           
 boolean isXPath()
           
 org.apache.openjpa.meta.FieldMetaData last()
           
 void setAlias(String alias)
           
 void setCollection(boolean collection)
          Sets whether the JOINED property is a collection or not.
 void setImplicitType(Class type)
           
 void setJoinedFieldName(String collectionName)
          In a JOIN statement - sets the JOINED property name.
 void setMetaData(org.apache.openjpa.meta.ClassMetaData classMetaData)
           
 void setSchemaAlias(String schemaAliasName)
           
 void setSubqueryContext(org.apache.openjpa.kernel.exps.Context arg0, String arg1)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FieldPathNode

public FieldPathNode()
Method Detail

acceptVisit

public void acceptVisit(org.apache.openjpa.kernel.exps.ExpressionVisitor visitor)
Specified by:
acceptVisit in interface org.apache.openjpa.kernel.exps.Value

getAlias

public String getAlias()
Specified by:
getAlias in interface org.apache.openjpa.kernel.exps.Value

getMetaData

public org.apache.openjpa.meta.ClassMetaData getMetaData()
Specified by:
getMetaData in interface org.apache.openjpa.kernel.exps.Value

getName

public String getName()
Specified by:
getName in interface org.apache.openjpa.kernel.exps.Value

getPath

public org.apache.openjpa.kernel.exps.Path getPath()
Specified by:
getPath in interface org.apache.openjpa.kernel.exps.Value

getSelectAs

public org.apache.openjpa.kernel.exps.Value getSelectAs()
Specified by:
getSelectAs in interface org.apache.openjpa.kernel.exps.Value

getType

public Class getType()
Specified by:
getType in interface org.apache.openjpa.kernel.exps.Value

isAggregate

public boolean isAggregate()
Specified by:
isAggregate in interface org.apache.openjpa.kernel.exps.Value

isVariable

public boolean isVariable()
Specified by:
isVariable in interface org.apache.openjpa.kernel.exps.Value

isXPath

public boolean isXPath()
Specified by:
isXPath in interface org.apache.openjpa.kernel.exps.Value

setAlias

public void setAlias(String alias)
Specified by:
setAlias in interface org.apache.openjpa.kernel.exps.Value

setImplicitType

public void setImplicitType(Class type)
Specified by:
setImplicitType in interface org.apache.openjpa.kernel.exps.Value

setMetaData

public void setMetaData(org.apache.openjpa.meta.ClassMetaData classMetaData)
Specified by:
setMetaData in interface org.apache.openjpa.kernel.exps.Value

get

public void get(org.apache.openjpa.meta.FieldMetaData fmd,
                boolean nullTraversal)
Specified by:
get in interface org.apache.openjpa.kernel.exps.Path

get

public void get(org.apache.openjpa.meta.FieldMetaData fieldMetaData,
                org.apache.openjpa.meta.XMLMetaData xmlMetaData)
Specified by:
get in interface org.apache.openjpa.kernel.exps.Path

get

public void get(org.apache.openjpa.meta.XMLMetaData xmlMetaData,
                String name)
Specified by:
get in interface org.apache.openjpa.kernel.exps.Path

getCorrelationVar

public String getCorrelationVar()
Specified by:
getCorrelationVar in interface org.apache.openjpa.kernel.exps.Path

getSchemaAlias

public String getSchemaAlias()
Specified by:
getSchemaAlias in interface org.apache.openjpa.kernel.exps.Path

getXmlMapping

public org.apache.openjpa.meta.XMLMetaData getXmlMapping()
Specified by:
getXmlMapping in interface org.apache.openjpa.kernel.exps.Path

last

public org.apache.openjpa.meta.FieldMetaData last()
Specified by:
last in interface org.apache.openjpa.kernel.exps.Path

setSchemaAlias

public void setSchemaAlias(String schemaAliasName)
Specified by:
setSchemaAlias in interface org.apache.openjpa.kernel.exps.Path

setSubqueryContext

public void setSubqueryContext(org.apache.openjpa.kernel.exps.Context arg0,
                               String arg1)
Specified by:
setSubqueryContext in interface org.apache.openjpa.kernel.exps.Path

toString

public String toString()
Overrides:
toString in class Object

appendSql

public void appendSql(StringBuilder sql)
Description copied from interface: ExpressionNode
Appends the node SQL string to the string builder.

Specified by:
appendSql in interface ExpressionNode
Parameters:
sql - The SQL string builder to append to.

getNodeType

public ExpressionNode.NodeType getNodeType()
Description copied from interface: ExpressionNode
Gets the node type

Specified by:
getNodeType in interface ExpressionNode
Returns:
The node type.

setJoinedFieldName

public void setJoinedFieldName(String collectionName)
In a JOIN statement - sets the JOINED property name.

Parameters:
collectionName -

setCollection

public void setCollection(boolean collection)
Sets whether the JOINED property is a collection or not.


GigaSpaces XAP 10.0.1 API

Copyright © GigaSpaces.