citysdk.tourism.client.poi.base
Class Relationship

java.lang.Object
  extended by citysdk.tourism.client.poi.base.POIBaseType
      extended by citysdk.tourism.client.poi.base.POITermType
          extended by citysdk.tourism.client.poi.base.Relationship

public class Relationship
extends POITermType

Representation of the Relationship class of the UML diagram found in: http://www.w3.org/2010/POI/documents/Core/core-20111216.html#poi-data-model.

The Relationship entity is derived from POITermType and establishes 1-to-1 or 1-to-many relationships between POIs

Author:
Pedro Cruz

Constructor Summary
Relationship()
          Initializes an empty Relationship.
 
Method Summary
 java.lang.String getTargetEvent()
          Returns which target is a given Event related with.
 java.lang.String getTargetPOI()
          Returns which target is a given POI related with.
 boolean hasTargetEvent()
          Checks whether this relationship has a event as a target
 boolean hasTargetPOI()
          Checks whether this relationship has a POI as a target
 void setTargetEvent(java.lang.String targetEvent)
          Sets the Event that a given Event is related with.
 void setTargetPOI(java.lang.String targetPOI)
          Sets the POI that a given POI is related with.
 
Methods inherited from class citysdk.tourism.client.poi.base.POITermType
getScheme, getTerm, setScheme, setTerm
 
Methods inherited from class citysdk.tourism.client.poi.base.POIBaseType
getAuthor, getBase, getCreated, getDeleted, getHref, getId, getLang, getLicense, getType, getUpdated, getValue, setAuthor, setBase, setCreated, setDeleted, setHref, setId, setLang, setLicense, setType, setUpdated, setValue
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Relationship

public Relationship()
Initializes an empty Relationship.

Method Detail

getTargetPOI

public java.lang.String getTargetPOI()
Returns which target is a given POI related with.

Returns:
the POI id related with another POI

getTargetEvent

public java.lang.String getTargetEvent()
Returns which target is a given Event related with.

Returns:
the Event id related with another Event

setTargetPOI

public void setTargetPOI(java.lang.String targetPOI)
Sets the POI that a given POI is related with.

Parameters:
targetPOI - POI id related with another POI/Event

setTargetEvent

public void setTargetEvent(java.lang.String targetEvent)
Sets the Event that a given Event is related with.

Parameters:
targetEvent - Event id related with another POI/Event

hasTargetEvent

public boolean hasTargetEvent()
Checks whether this relationship has a event as a target

Returns:
true if has an Event as a target, false otherwise

hasTargetPOI

public boolean hasTargetPOI()
Checks whether this relationship has a POI as a target

Returns:
true if has a POI as a target, false otherwise