Interface RouteSegment
- All Superinterfaces:
Browsable, Extensible, Identifiable, OsidObject
A route segment represents a portion of a route.
-
Method Summary
Modifier and TypeMethodDescriptionGets the length of the entire segment.Gets the ending instructions for this segment.getETA()Gets the estimated travel time across the entire segment.getPath()Gets the corresponding path on which this segment travels.Gets the corresponding pathIdon which this segment travels.getRouteSegmentRecord(Type routeSegmentRecordType) Gets the route segment record corresponding to the givenRouteSegmentrecordType.Gets the starting instructions for this segment.booleanhasPath()Tests if this segment has a corresponding path.Methods inherited from interface Browsable
getProperties, getPropertiesByRecordTypeModifier and TypeMethodDescriptionGets a list of properties.getPropertiesByRecordType(Type recordType) Gets a list of properties corresponding to the specified record type.Methods inherited from interface Extensible
getRecordTypes, hasRecordTypeModifier and TypeMethodDescriptionGets the record types available in this object.booleanhasRecordType(Type recordType) Tests if this object supports the given recordType.Methods inherited from interface Identifiable
getId, isCurrentMethods inherited from interface OsidObject
getDescription, getDisplayName, getGenusType, isOfGenusTypeModifier and TypeMethodDescriptionGets the description associated with this instance of this OSID object.Gets the preferred display name associated with this instance of this OSID object appropriate for display to the user.Gets the genus type of this object.booleanisOfGenusType(Type genusType) Tests if this object is of the given genusType.
-
Method Details
-
getStartingInstructions
DisplayText getStartingInstructions()Gets the starting instructions for this segment.- Returns:
- the starting instructions
- Compliance:
mandatory- This method must be implemented.
-
getEndingInstructions
DisplayText getEndingInstructions()Gets the ending instructions for this segment.- Returns:
- the ending instructions
- Compliance:
mandatory- This method must be implemented.
-
getDistance
Distance getDistance()Gets the length of the entire segment.- Returns:
- the distance
- Compliance:
mandatory- This method must be implemented.
-
getETA
Duration getETA()Gets the estimated travel time across the entire segment.- Returns:
- the estimated travel time
- Compliance:
mandatory- This method must be implemented.
-
hasPath
boolean hasPath()Tests if this segment has a corresponding path.- Returns:
trueif there is a path,falseotherwise- Compliance:
mandatory- This method must be implemented.
-
getPathId
Id getPathId()Gets the corresponding pathIdon which this segment travels.- Returns:
- the path
- Throws:
IllegalStateException-hasPath()isnull- Compliance:
mandatory- This method must be implemented.
-
getPath
Gets the corresponding path on which this segment travels.- Returns:
- the path
- Throws:
IllegalStateException-hasPath()isnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getRouteSegmentRecord
RouteSegmentRecord getRouteSegmentRecord(Type routeSegmentRecordType) throws OperationFailedException Gets the route segment record corresponding to the givenRouteSegmentrecordType.- Parameters:
routeSegmentRecordType- a route segment record type- Returns:
- the route segment record
- Throws:
NullArgumentException-routeRecordTypeisnullOperationFailedException- unable to complete requestUnsupportedException-hasDomainType(routeSegmentRecordType)isfalse- Compliance:
mandatory- This method must be implemented.
-