public interface ODataEntity extends ODataPayload
ODataPayload.Type
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getAnnotation(AnnotationName name)
Returns the annotation value specified by the given fully qualified local annotation name.
|
java.lang.String |
getAnnotation(java.lang.String namespace,
java.lang.String name)
Returns the annotation value specified by the given local annotation namespace and localname.
|
java.util.Set<AnnotationName> |
getAnnotationNames()
Returns a set of fully qualified local annotation names.
|
java.net.URL |
getEditMediaLink()
Returns the edit media link of this entity.
|
java.lang.String |
getEditResourcePath()
Returns the path to the endpoint through which this entity can be edited.
|
java.lang.String |
getEntityType()
Returns the type of the entity in it's fully-qualified form which includes the namespace prefix.
|
java.lang.String |
getEtag()
Returns the ETag of the entry backing this entity.
|
java.lang.String |
getMediaContentType()
Returns the content type of the media.
|
java.lang.String |
getMediaEtag()
Returns the ETag of the media resource.
|
java.net.URL |
getMediaLink()
Returns the media link of this entity.
|
ODataNavigationProperty |
getNavigationProperty(java.lang.String key)
Returns the navigation property associated with the given key.
|
java.util.Set<java.lang.String> |
getNavigationPropertyNames()
Returns the set containing the names of navigation properties.
|
ODataPropMap |
getProperties()
Returns the current map containing the data properties of this entity.
|
java.lang.String |
getResourcePath()
Returns the path from which this entity has been obtained.
|
boolean |
isMediaEntry()
Convenience method telling whether this entity is a media entry.
|
void |
setEtag(java.lang.String etag)
Sets the ETag of the entry backing this entity.
|
void |
setMediaEtag(java.lang.String mediaEtag)
Sets the media ETag
|
void |
setMediaLink(java.lang.String mediaContentType,
java.net.URL link,
java.net.URL editLink)
Sets the media links and the media content type of this entity.
|
ODataNavigationProperty |
setNavigationProperty(java.lang.String key,
ODataNavigationProperty link)
Associates the specified key with the specified navigation property.
|
void |
setResourcePath(java.lang.String resourcePath,
java.lang.String editResourcePath)
Sets resource paths.
|
java.lang.String getEntityType()
java.lang.String getResourcePath()
java.lang.String getEditResourcePath()
void setResourcePath(java.lang.String resourcePath, java.lang.String editResourcePath)
resourcePath
- the resource path, can be nulleditResourcePath
- the edit resource path, can be nullboolean isMediaEntry()
java.lang.String getMediaContentType()
java.net.URL getMediaLink()
java.net.URL getEditMediaLink()
void setMediaLink(java.lang.String mediaContentType, java.net.URL link, java.net.URL editLink)
mediaContentType
- the media content type, can be nulllink
- the media link, can be nulleditLink
- the edit media link, can be nulljava.util.Set<java.lang.String> getNavigationPropertyNames()
ODataNavigationProperty getNavigationProperty(java.lang.String key)
key
- the key of the property, can be nullODataNavigationProperty setNavigationProperty(java.lang.String key, ODataNavigationProperty link)
key
- the key, must be non-nulllink
- the property, must be non-nullODataPropMap getProperties()
java.lang.String getEtag()
java.lang.String getMediaEtag()
void setMediaEtag(java.lang.String mediaEtag)
mediaEtag
- the media etag, can be nullvoid setEtag(java.lang.String etag)
etag
- the entity tag, can be nulljava.util.Set<AnnotationName> getAnnotationNames()
java.lang.String getAnnotation(AnnotationName name)
name
- fully qualified local annotation namejava.lang.String getAnnotation(java.lang.String namespace, java.lang.String name)
namespace
- annotation namespace, can be nullname
- annotation local name. It MUST be non-null, otherwise NullPointerException is thrownjava.lang.NullPointerException
- if name parameter is null