| Interface | osid.topology.GraphHierarchySession | ||
|---|---|---|---|
| Implements | osid.OsidSession | ||
| Description | 
                 This session defines methods for traversing a hierarchy of 
                  A user may not be authorized to traverse the entire 
                hierarchy. Parts of the hierarchy may be made invisible 
                through omission from the returns of  This session defines views that offer differing behaviors when retrieving multiple objects. 
  | ||
| Method | getGraphHierarchyId | ||
| Description | 
                     Gets the hierarchy   | ||
| Return | osid.id.Id | the hierarchy  Id  associated with this session  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getGraphHierarchy | ||
| Description | 
                     Gets the hierarchy associated with this session.  | ||
| Return | osid.hierarchy.Hierarchy | the hierarchy associated with this session | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canAccessGraphHierarchy | ||
| Description | 
                     Tests if this user can perform hierarchy queries. 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   | ||
| Return | boolean |  false  if hierarchy traversal methods are not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | useComparativeGraphView | ||
| Description | 
                     The returns from the graph 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.  | ||
| Compliance | mandatory | This method is must be implemented. | |
| Method | usePlenaryGraphView | ||
| Description | 
                     A complete view of the   | ||
| Compliance | mandatory | This method is must be implemented. | |
| Method | getRootGraphIds | ||
| Description | 
                     Gets the root graph   | ||
| Return | osid.id.IdList | the root catalog  Ids   | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getRootGraphs | ||
| Description | 
                     Gets the root graph in the graph hierarchy. A node with 
                    no parents is an orphan. While all graph   | ||
| Return | osid.topology.GraphList | the root graphs | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method is must be implemented. | |
| Method | hasParentGraphs | ||
| Description | 
                     Tests if the   | ||
| Parameters | osid.id.Id | graphId | a catalog  Id   | 
| Return | boolean |  true  if the catalog has parents, f  alse  
otherwise  | |
| Errors | NOT_FOUND |  graphId  is not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | isParentOfGraph | ||
| Description | 
                     Tests if an   | ||
| Parameters | osid.id.Id | id | an  Id   | 
osid.id.Id | graphId | the  Id  of a graph  | |
| Return | boolean |  true  if this  id  is a parent of  
graphId,  f  alse  otherwise  | |
| Errors | NOT_FOUND |  graphId  is not found  |                 |
| NULL_ARGUMENT |  id  or  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Provider Notes | 
                                       If   | ||
| Method | getParentGraphIds | ||
| Description | 
                     Gets the parent   | ||
| Parameters | osid.id.Id | graphId | a catalog  Id   | 
| Return | osid.id.IdList | the parent  Ids  of the graph  | |
| Errors | NOT_FOUND |  graphId  is not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getParentGraphs | ||
| Description | 
                     Gets the parents of the given graph.  | ||
| Parameters | osid.id.Id | graphId | the  Id  to query  | 
| Return | osid.topology.GraphList | the parents of the graph | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | isAncestorOfGraph | ||
| Description | 
                     Tests if an   | ||
| Parameters | osid.id.Id | id | an  Id   | 
osid.id.Id | graphId | the  Id  of a catalog  | |
| Return | boolean |  tru  e if this  id  is an ancestor of  
graphId,   false  otherwise  | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  or  id  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Provider Notes | 
                                       If   | ||
| Method | hasChildGraphs | ||
| Description | 
                     Tests if a graph has any children.  | ||
| Parameters | osid.id.Id | graphId | a graph  Id   | 
| Return | boolean |  true  if the  graphId  has children,  
false  otherwise  | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | isChildOfGraph | ||
| Description | 
                     Tests if a graph is a direct child of another.  | ||
| Parameters | osid.id.Id | id | an  Id   | 
osid.id.Id | graphId | the  Id  of a graph  | |
| Return | boolean |  true  if the  id  is a child of  graphId, 
  false  otherwise  | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  id  or  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Provider Notes | 
                                       If   | ||
| Method | getChildGraphIds | ||
| Description | 
                     Gets the child   | ||
| Parameters | osid.id.Id | graphId | the  Id  to query  | 
| Return | osid.id.IdList | the children of the catalog | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getChildGraphs | ||
| Description | 
                     Gets the children of the given graph.  | ||
| Parameters | osid.id.Id | graphId | the  Id  to query  | 
| Return | osid.topology.GraphList | the children of the graph | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | isDescendantOfGraph | ||
| Description | 
                     Tests if an   | ||
| Parameters | osid.id.Id | id | an  Id   | 
osid.id.Id | graphId | the  Id  of a catalog  | |
| Return | boolean |  true  if the  id  is a descendant of the  
graphId,   false  otherwise  | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  id  or  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Provider Notes | 
                                       If   | ||
| Method | getGraphNodeIds | ||
| Description | 
                     Gets a portion of the hierarchy for the given graph.  | ||
| Parameters | osid.id.Id | graphId | the  Id  to query  | 
cardinal | ancestorLevels | the maximum number of ancestor levels to include. A value of 0 returns no parents in the node. | |
cardinal | descendantLevels | the maximum number of descendant levels to include. A value of 0 returns no children in the node. | |
boolean | includeSiblings |  true  to include the siblings of the given node,  false 
 to omit the siblings  | |
| Return | osid.hierarchy.Node | a catalog node | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getGraphNodes | ||
| Description | 
                     Gets a portion of the hierarchy for the given graph.  | ||
| Parameters | osid.id.Id | graphId | the  Id  to query  | 
cardinal | ancestorLevels | the maximum number of ancestor levels to include. A value of 0 returns no parents in the node. | |
cardinal | descendantLevels | the maximum number of descendant levels to include. A value of 0 returns no children in the node. | |
boolean | includeSiblings |  true  to include the siblings of the given node,  false 
 to omit the siblings  | |
| Return | osid.topology.GraphNode | a graph node | |
| Errors | NOT_FOUND |  graphId  not found  |                 |
| NULL_ARGUMENT |  graphId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |