Interface SchemaContext

    • Field Detail

      • NAME

        static final @NonNull QName NAME
        QName of NETCONF top-level data node.
    • Method Detail

      • getDataDefinitions

        Set<DataSchemaNode> getDataDefinitions()
        Returns data schema node instances which represents direct subnodes (like leaf, leaf-list, list, container) in all YANG modules in the context.
        Returns:
        set of DataSchemaNode instances which represents YANG data nodes at the module top level
      • getModules

        Set<Module> getModules()
        Returns modules which are part of the schema context. Returned set is required to have its iteration ordered by module revision, so that if modules are filtered by Module.getName() or Module.getNamespace(), modules having the same attribute are encountered newest revision first.
        Returns:
        set of the modules which belong to the schema context
      • getOperations

        Set<RpcDefinition> getOperations()
        Returns rpc definition instances which are defined as the direct subelements in all YANG modules in the context.
        Returns:
        set of RpcDefinition instances which represents nodes defined via rpc YANG keyword
      • getExtensions

        Set<ExtensionDefinition> getExtensions()
        Returns extension definition instances which are defined as the direct subelements in all YANG modules in the context.
        Returns:
        set of ExtensionDefinition instances which represents nodes defined via extension YANG keyword
      • findModule

        default Optional<Module> findModule​(@NonNull URI namespace)
        Returns module instance (from the context) with specified namespace and no revision.
        Parameters:
        namespace - module namespace
        Returns:
        module instance which has name and revision the same as are the values specified in parameters namespace and no revision.
      • findModule

        default Optional<Module> findModule​(@NonNull URI namespace,
                                            @Nullable Revision revision)
        Returns module instance (from the context) with specified namespace and revision.
        Parameters:
        namespace - module namespace
        revision - module revision, may be null
        Returns:
        module instance which has name and revision the same as are the values specified in parameters namespace and revision.
      • findModule

        default Optional<Module> findModule​(@NonNull URI namespace,
                                            @NonNull Optional<Revision> revision)
        Returns module instance (from the context) with specified namespace and revision.
        Parameters:
        namespace - module namespace
        revision - module revision, may be null
        Returns:
        module instance which has name and revision the same as are the values specified in parameters namespace and revision.
      • findModule

        default Optional<Module> findModule​(String name,
                                            Optional<Revision> revision)
        Returns module instance (from the context) with specified name and an optional revision.
        Parameters:
        name - string with the module name
        revision - date of the module revision
        Returns:
        module instance which has name and revision the same as are the values specified in parameters name and revision.
      • findModule

        default Optional<Module> findModule​(String name,
                                            @Nullable Revision revision)
        Returns module instance (from the context) with specified name and revision.
        Parameters:
        name - string with the module name
        revision - date of the module revision, may be null
        Returns:
        module instance which has name and revision the same as are the values specified in parameters name and revision.
      • findModule

        default Optional<Module> findModule​(String name)
        Returns module instance (from the context) with specified name and no revision.
        Parameters:
        name - string with the module name
        Returns:
        module instance which has name and revision the same as are the values specified in name and no revision.
        Throws:
        NullPointerException - if name is null
      • findModules

        default Set<Module> findModules​(String name)
        Returns module instances (from the context) with a concrete name. Returned Set is required to have its iteration order guarantee that the latest revision is encountered first.
        Parameters:
        name - string with the module name
        Returns:
        set of module instances with specified name.
      • findModules

        default Set<Module> findModules​(URI namespace)
        Returns module instance (from the context) with concrete namespace. Returned Set is required to have its iteration order guarantee that the latest revision is encountered first.
        Parameters:
        namespace - URI instance with specified namespace
        Returns:
        module instance which has namespace equal to the namespace or null in other cases
      • getDescription

        default Optional<String> getDescription()
        Description copied from interface: DocumentedNode
        Returns the value of the argument of YANG description keyword.
        Specified by:
        getDescription in interface DocumentedNode
        Returns:
        string with the description, or empty if description was not provided.
      • getReference

        default Optional<String> getReference()
        Description copied from interface: DocumentedNode
        Returns the value of the argument of YANG reference keyword.
        Specified by:
        getReference in interface DocumentedNode
        Returns:
        string with reference to some other document, or empty if reference was not provided.
      • getWhenCondition

        default Optional<RevisionAwareXPath> getWhenCondition()
        Description copied from interface: WhenConditionAware
        Returns when statement.

        If when condition is present node defined by the parent data definition statement is only valid when the returned XPath expression conceptually evaluates to "true" for a particular instance, then the node defined by the parent data definition statement is valid; otherwise, it is not.

        Specified by:
        getWhenCondition in interface WhenConditionAware
        Returns:
        XPath condition