|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.odata4j.consumer.AbstractConsumerEntityPayloadRequest org.odata4j.consumer.ConsumerEntityModificationRequest<T>
public class ConsumerEntityModificationRequest<T>
Modification-request implementation.
Field Summary |
---|
Fields inherited from class org.odata4j.consumer.AbstractConsumerEntityPayloadRequest |
---|
entitySetName, links, metadata, props, serviceRootUri |
Constructor Summary | |
---|---|
ConsumerEntityModificationRequest(T updateRoot,
ODataClient client,
String serviceRootUri,
EdmDataServices metadata,
String entitySetName,
OEntityKey key,
String ifMatch)
|
Method Summary | |
---|---|
void |
execute()
Sends the modification request to the OData service. |
OModifyRequest<T> |
ifMatch(String precondition)
Overrides the If-Match precondition. |
OModifyRequest<T> |
link(String navProperty,
OEntity target)
Defines an explicit link to another related entity. |
OModifyRequest<T> |
link(String navProperty,
OEntityKey targetKey)
Defines an explicit link to another related entity. |
OModifyRequest<T> |
nav(String navProperty,
OEntityKey key)
Selects a new modification entity by navigating to a referenced entity in a child collection. |
OModifyRequest<T> |
properties(Iterable<OProperty<?>> props)
Sets properties on the new entity. |
OModifyRequest<T> |
properties(OProperty<?>... props)
Sets properties on the new entity. |
Methods inherited from class org.odata4j.consumer.AbstractConsumerEntityPayloadRequest |
---|
inline, link, link, properties, properties |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ConsumerEntityModificationRequest(T updateRoot, ODataClient client, String serviceRootUri, EdmDataServices metadata, String entitySetName, OEntityKey key, String ifMatch)
Method Detail |
---|
public void execute() throws ODataProducerException
OModifyRequest
execute
in interface OModifyRequest<T>
ODataProducerException
- error from the producerpublic OModifyRequest<T> ifMatch(String precondition)
OModifyRequest
The If-Match header will default to the entity-tag of the entity used to start the builder sequence.
ifMatch
in interface OModifyRequest<T>
precondition
- null
, an entity-tag, or *
public OModifyRequest<T> link(String navProperty, OEntity target)
OModifyRequest
link
in interface OModifyRequest<T>
navProperty
- the entity's relationship navigation propertytarget
- the link target entity
public OModifyRequest<T> link(String navProperty, OEntityKey targetKey)
OModifyRequest
link
in interface OModifyRequest<T>
navProperty
- the entity's relationship navigation propertytargetKey
- the key of the link target entity
public OModifyRequest<T> nav(String navProperty, OEntityKey key)
OModifyRequest
nav
in interface OModifyRequest<T>
navProperty
- the child collectionkey
- the referenced entity's key
public OModifyRequest<T> properties(Iterable<OProperty<?>> props)
OModifyRequest
properties
in interface OModifyRequest<T>
props
- the properties
public OModifyRequest<T> properties(OProperty<?>... props)
OModifyRequest
properties
in interface OModifyRequest<T>
props
- the properties
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |