public class SelectItem
extends java.lang.Object
Encapsulates an OData select item. A select item indicates a property (or expression) that is used in the $select system query option.
Constructor and Description |
---|
SelectItem() |
Modifier and Type | Method and Description |
---|---|
DataPath |
getPath()
Return a path to be expanded in the query results.
|
boolean |
isHidden()
Return was this select item added for internal use
(e.g.
|
static SelectItem |
of(PropertyPath item)
Return a new select item for the specified property.
|
void |
setHidden(boolean value)
Set was this select item added for internal use
(e.g.
|
void |
setPath(DataPath value)
Set a path to be expanded in the query results.
|
Property |
toProperty()
If this select item references a simple property path, then return the property.
|
Property |
toRequiredProperty()
If this select item references a simple property path, then return the property.
|
java.lang.String |
toString()
Return a string representation of this select item.
|
public DataPath getPath()
Return a path to be expanded in the query results.
public boolean isHidden()
Return was this select item added for internal use (e.g. needed for server-side query processing, but not requested by client).
public static SelectItem of(PropertyPath item)
Return a new select item for the specified property.
item
- Item to be selected.public void setHidden(boolean value)
Set was this select item added for internal use (e.g. needed for server-side query processing, but not requested by client).
value
- Was this select item added for internal usepublic void setPath(DataPath value)
Set a path to be expanded in the query results.
value
- A path to be expanded in the query results.public Property toProperty()
If this select item references a simple property path, then return the property. Otherwise return null
.
null
.public Property toRequiredProperty()
If this select item references a simple property path, then return the property. Otherwise throw an exception.
UndefinedException
if this select item does not reference a simple property path.
public java.lang.String toString()
Return a string representation of this select item.
toString
in class java.lang.Object