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 TransferZoneTypeDEFAULT_TYPEdefault transfer zone typestatic Class<TransferZone>TRANSFER_ZONE_ID_CLASSthe 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 voidaddToTransferZoneGroup(TransferZoneGroup transferZoneGroup)register this transfer zone group as a group this transfer zone is part ofbooleanaddTransferZonePlatformName(String platformName)Add platform name for this transfer zonedefault voidaddTransferZonePlatformNames(String[] platformNames)Add all platform names provideddefault voidaddTransferZonePlatformNames(Collection<String> platformNames)Add all platform names providedTransferZonedeepClone()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)longgetTransferZoneId()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).TransferZoneTypegetTransferZoneType()collect the type of this transfer zonedefault booleanhasPlatformNames()Verify if any platform names are presentbooleanhasTransferZoneGroup()Verify if a transfer zone is part of one or more transfer zone groupsbooleanisInTransferZoneGroup(TransferZoneGroup transferZoneGroup)Verify if transfer zone is part of passed in transfer zone groupvoidremoveFromAllTransferZoneGroups()remove this transfer zone from all groups it is registered on (and also update the group referencesbooleanremoveFromTransferZoneGroup(TransferZoneGroup transferZoneGroup)remove from transfer zone group provided and also remove ths transfer zone from group providedbooleanremoveTransferZonePlatformName(String platformName)Remove a platform name if presentvoidsetType(TransferZoneType transferZoneType)set the type of this transfer zoneTransferZoneshallowClone()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:
shallowClonein interfaceIdAble- Specified by:
shallowClonein 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()
-
-