Class Entity

Direct Known Subclasses:
DeletedEntity

public class Entity extends Linked
Data representation for a single entity.
  • Constructor Details

    • Entity

      public Entity()
  • Method Details

    • getETag

      public String getETag()
      Gets ETag.
      Returns:
      ETag.
    • setETag

      public void setETag(String eTag)
      Sets ETag
      Parameters:
      eTag - ETag
    • getType

      public String getType()
      Gets entity type.
      Returns:
      entity type.
    • setType

      public void setType(String type)
      Sets entity type.
      Parameters:
      type - entity type.
    • getSelfLink

      public Link getSelfLink()
      Gets entity self link.
      Returns:
      self link.
    • setSelfLink

      public void setSelfLink(Link selfLink)
      Sets entity self link.
      Parameters:
      selfLink - self link.
    • getEditLink

      public Link getEditLink()
      Gets entity edit link.
      Returns:
      edit link.
    • setEditLink

      public void setEditLink(Link editLink)
      Sets entity edit link.
      Parameters:
      editLink - edit link.
    • getMediaEditLinks

      public List<Link> getMediaEditLinks()
      Gets media entity links.
      Returns:
      links.
    • getOperations

      public List<Operation> getOperations()
      Gets operations.
      Returns:
      operations.
    • addProperty

      public Entity addProperty(Property property)
      Add property to this Entity.
      Parameters:
      property - property which is added
      Returns:
      this Entity for fluid/flow adding
    • getProperties

      public List<Property> getProperties()
      Gets properties.
      Returns:
      properties.
    • getProperty

      public Property getProperty(String name)
      Gets property with given name.
      Parameters:
      name - property name
      Returns:
      property with given name if found, null otherwise
    • getMediaContentType

      public String getMediaContentType()
      Gets media content type.
      Returns:
      media content type.
    • setMediaContentType

      public void setMediaContentType(String mediaContentType)
      Set media content type.
      Parameters:
      mediaContentType - media content type.
    • getMediaContentSource

      public URI getMediaContentSource()
      Gets media content resource.
      Returns:
      media content resource.
    • setMediaContentSource

      public void setMediaContentSource(URI mediaContentSource)
      Set media content source.
      Parameters:
      mediaContentSource - media content source.
    • getMediaETag

      public String getMediaETag()
      ETag of the binary stream represented by this media entity or named stream property.
      Returns:
      media ETag value
    • setMediaETag

      public void setMediaETag(String eTag)
      Set media ETag.
      Parameters:
      eTag - media ETag value
    • isMediaEntity

      public boolean isMediaEntity()
      Checks if the current entity is a media entity.
      Returns:
      'TRUE' if is a media entity; 'FALSE' otherwise.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Linked
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Linked
    • toString

      public String toString()
      Overrides:
      toString in class Object