OSID Logo
OSID Specifications
topology package
Version 3.0.0
Release Candidate Preview
Interfaceosid.topology.TopologyTraversalSession
Implementsosid.OsidSession
Description

This session defines methods to traverse through a graph.

MethodgetGraphId
Description

Gets the Graph Id associated with this session.

Returnosid.id.Idthe Graph Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetGraph
Description

Gets the Graph associated with this session.

Returnosid.topology.Graphthe graph
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanTraverseTopology
Description

Tests if this user can traverse the topology. A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a PERMISSION_DENIED. This is intended as a hint to an application that may not offer lookup operations to unauthorized users.

Returnboolean false if topology methods are not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoduseComparativeNodeView
Description

The returns from the traversal methods may omit or translate elements based on this session, such as authorization, and not result in an error. This view is used when greater interoperability is desired at the expense of precision.

CompliancemandatoryThis method is must be implemented.
MethodusePlenaryNodeView
Description

A complete view of the method returns is desired. Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability.

CompliancemandatoryThis method is must be implemented.
MethoduseFederatedGraphView
Description

Federates the view for methods in this session. A federated view will include edges in graphs which are children of this graph in the graph hierarchy.

CompliancemandatoryThis method is must be implemented.
MethoduseIsolatedGraphView
Description

Isolates the view for methods in this session. An isolated view restricts retrievals to this graph only.

CompliancemandatoryThis method is must be implemented.
MethodgetConnectedEdges
Description

Gets all the edges for a given node.

Parametersosid.id.IdnodeIdthe given node Id
cardinalhopsthe number of hops to include. 0 returns an empty list. 1 returns the immediate connected edges.
Returnosid.topology.EdgeLista list of edges
ErrorsNOT_FOUND nodeId is not found
NULL_ARGUMENT nodeId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetNeighboringNodes
Description

Gets the neighboring nodes of the given node.

Parametersosid.id.IdnodeIdthe given node Id
cardinalhopsthe number of hops to include. 0 returns the given node. 1 returns the immediate neighbors.
Returnosid.topology.NodeListthe list of neighboring nodes
ErrorsNOT_FOUND nodeId is not found
NULL_ARGUMENT nodeId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetInboundEdges
Description

Gets a list of directional edges into the given node.

Parametersosid.id.IdnodeIdthe given node Id
cardinalhopsthe number of hops to include. 0 returns an empty list. 1 returns the immediate connected edges.
Returnosid.topology.EdgeLista list of inbound edges
ErrorsNOT_FOUND nodeId is not found
NULL_ARGUMENT nodeId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetOutboundEdges
Description

Gets a list of directional edges out of the given node.

Parametersosid.id.IdnodeIdthe given node Id
cardinalhopsthe number of hops to include. 0 returns an empty list. 1 returns the immediate connected edges.
Returnosid.topology.EdgeLista list of outbound edges
ErrorsNOT_FOUND nodeId is not found
NULL_ARGUMENT nodeId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetDisconnectedNodes
Description

Gets the nodes with no edges.

Returnosid.topology.NodeListthe list of neighboring nodes
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.