Package org.goplanit.utils.zoning
Interface TransferZone
-
- All Superinterfaces:
Comparable<IdAble>
,ExternalIdAble
,IdAble
,ManagedId
,Zone
- All Known Implementing Classes:
TransferZoneImpl
public interface TransferZone extends Zone
A zone where transfers between different network layers may occur. Trips do not terminate at transfer zones- Author:
- markr
-
-
Field Summary
Fields Modifier and Type Field Description static TransferZoneType
DEFAULT_TYPE
default transfer zone typestatic Class<TransferZone>
TRANSFER_ZONE_ID_CLASS
the class to use for the id generation-
Fields inherited from interface org.goplanit.utils.zoning.Zone
LOGGER, ZONE_ID_CLASS
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
addToTransferZoneGroup(TransferZoneGroup transferZoneGroup)
register this transfer zone group as a group this transfer zone is part ofboolean
addTransferZonePlatformName(String platformName)
Add platform name for this transfer zonedefault void
addTransferZonePlatformNames(String[] platformNames)
Add all platform names provideddefault void
addTransferZonePlatformNames(Collection<String> platformNames)
Add all platform names providedTransferZone
deepClone()
An id entity should always support a deep copy, i.e., all "owned" members will be deep copied when a clone of this instance is created via this call.Set<TransferZoneGroup>
getTransferZoneGroups()
All transfer zone groups the transfer zone resides in (unmodifiable)long
getTransferZoneId()
In addition to a zone id across all zones of any derived type, each transfer zone also has a unique id across the transfer zones specificallydefault Class<TransferZone>
getTransferZoneIdClass()
List<String>
getTransferZonePlatformNames()
Unmodifiable list of registered platform names for this transfer zone (if any).TransferZoneType
getTransferZoneType()
collect the type of this transfer zonedefault boolean
hasPlatformNames()
Verify if any platform names are presentboolean
hasTransferZoneGroup()
Verify if a transfer zone is part of one or more transfer zone groupsboolean
isInTransferZoneGroup(TransferZoneGroup transferZoneGroup)
Verify if transfer zone is part of passed in transfer zone groupvoid
removeFromAllTransferZoneGroups()
remove this transfer zone from all groups it is registered on (and also update the group referencesboolean
removeFromTransferZoneGroup(TransferZoneGroup transferZoneGroup)
remove from transfer zone group provided and also remove ths transfer zone from group providedboolean
removeTransferZonePlatformName(String platformName)
Remove a platform name if presentvoid
setType(TransferZoneType transferZoneType)
set the type of this transfer zoneTransferZone
shallowClone()
Create a shallow copy of this entity-
Methods inherited from interface org.goplanit.utils.id.ExternalIdAble
appendExternalId, appendExternalId, getExternalId, getIdsAsString, getSplitExternalId, getSplitExternalId, getXmlId, hasExternalId, hasXmlId, setExternalId, setXmlId, setXmlId
-
Methods inherited from interface org.goplanit.utils.id.IdAble
compareTo, getId, idEquals, idHashCode
-
Methods inherited from interface org.goplanit.utils.id.ManagedId
recreateManagedIds, resetChildManagedIdEntities
-
Methods inherited from interface org.goplanit.utils.zoning.Zone
addInputProperty, getCentroid, getEnvelope, getGeometry, getGeometry, getIdClass, getInputProperty, getName, hasCentroid, hasGeometry, hasInputProperty, hasName, setGeometry, setName
-
-
-
-
Field Detail
-
TRANSFER_ZONE_ID_CLASS
static final Class<TransferZone> TRANSFER_ZONE_ID_CLASS
the class to use for the id generation
-
DEFAULT_TYPE
static final TransferZoneType DEFAULT_TYPE
default transfer zone type
-
-
Method Detail
-
getTransferZoneId
long getTransferZoneId()
In addition to a zone id across all zones of any derived type, each transfer zone also has a unique id across the transfer zones specifically- Returns:
- transfer zone specific id
-
getTransferZonePlatformNames
List<String> getTransferZonePlatformNames()
Unmodifiable list of registered platform names for this transfer zone (if any).- Returns:
- transfer zone platform names if any were registered
-
addTransferZonePlatformName
boolean addTransferZonePlatformName(String platformName)
Add platform name for this transfer zone- Parameters:
platformName
- to add- Returns:
- true if newly added, false otherwise
-
removeTransferZonePlatformName
boolean removeTransferZonePlatformName(String platformName)
Remove a platform name if present- Parameters:
platformName
- to remove- Returns:
- true when removed, false otherwise
-
hasPlatformNames
default boolean hasPlatformNames()
Verify if any platform names are present- Returns:
- true when present, false otherwise
-
addTransferZonePlatformNames
default void addTransferZonePlatformNames(String[] platformNames)
Add all platform names provided- Parameters:
platformNames
- to add
-
addTransferZonePlatformNames
default void addTransferZonePlatformNames(Collection<String> platformNames)
Add all platform names provided- Parameters:
platformNames
- to add
-
setType
void setType(TransferZoneType transferZoneType)
set the type of this transfer zone- Parameters:
transferZoneType
- to set
-
getTransferZoneType
TransferZoneType getTransferZoneType()
collect the type of this transfer zone- Returns:
- transfer zone type
-
hasTransferZoneGroup
boolean hasTransferZoneGroup()
Verify if a transfer zone is part of one or more transfer zone groups- Returns:
- true when in transfer zone group, false otherwise
-
isInTransferZoneGroup
boolean isInTransferZoneGroup(TransferZoneGroup transferZoneGroup)
Verify if transfer zone is part of passed in transfer zone group- Parameters:
transferZoneGroup
- to check- Returns:
- true when part of group, false otherwise
-
addToTransferZoneGroup
void addToTransferZoneGroup(TransferZoneGroup transferZoneGroup)
register this transfer zone group as a group this transfer zone is part of- Parameters:
transferZoneGroup
- to register as being part of
-
removeFromTransferZoneGroup
boolean removeFromTransferZoneGroup(TransferZoneGroup transferZoneGroup)
remove from transfer zone group provided and also remove ths transfer zone from group provided- Parameters:
transferZoneGroup
- to remove ourselves as member from- Returns:
- true when removal was successful, false otherwise
-
getTransferZoneGroups
Set<TransferZoneGroup> getTransferZoneGroups()
All transfer zone groups the transfer zone resides in (unmodifiable)- Returns:
- transfer zone groups of the transfer zone
-
removeFromAllTransferZoneGroups
void removeFromAllTransferZoneGroups()
remove this transfer zone from all groups it is registered on (and also update the group references
-
shallowClone
TransferZone shallowClone()
Create a shallow copy of this entity- Specified by:
shallowClone
in interfaceIdAble
- Specified by:
shallowClone
in interfaceZone
- Returns:
- shallow copy of entity
-
deepClone
TransferZone deepClone()
An id entity should always support a deep copy, i.e., all "owned" members will be deep copied when a clone of this instance is created via this call. To be used with caution if not called by managed id container related code
-
getTransferZoneIdClass
default Class<TransferZone> getTransferZoneIdClass()
-
-