Class AbstractEffectiveModule<D extends DeclaredStatement<UnqualifiedQName>,​E extends DataTreeAwareEffectiveStatement<UnqualifiedQName,​D>>

    • Method Detail

      • getName

        public String getName()
        Description copied from interface: ModuleLike
        Returns the name of the module which is specified as argument of YANG module statement.
        Specified by:
        getName in interface ModuleLike
        Returns:
        string with the name of the module
      • getPrefix

        public String getPrefix()
        Description copied from interface: ModuleLike
        Returns the prefix of the module.
        Specified by:
        getPrefix in interface ModuleLike
        Returns:
        string with the module prefix which is specified as argument of YANG prefix statement
      • getOrganization

        public Optional<String> getOrganization()
        Description copied from interface: ModuleLike
        Returns the module organization.
        Specified by:
        getOrganization in interface ModuleLike
        Returns:
        string with the name of the organization specified in the module as the argument of YANG organization statement
      • getContact

        public Optional<String> getContact()
        Description copied from interface: ModuleLike
        Returns the module contact.

        The contact represents the person or persons to whom technical queries concerning this module should be sent, such as their name, postal address, telephone number, and electronic mail address.

        Specified by:
        getContact in interface ModuleLike
        Returns:
        string with the contact data specified in the module as the argument of YANG contact statement
      • getImports

        public Collection<? extends @NonNull ModuleImport> getImports()
        Description copied from interface: ModuleLike
        Returns imports which represents YANG modules which are imported to this module via import statement.
        Specified by:
        getImports in interface ModuleLike
        Returns:
        set of module imports which are specified in the module as the argument of YANG import statements.
      • getFeatures

        public Collection<? extends @NonNull FeatureDefinition> getFeatures()
        Description copied from interface: ModuleLike
        Returns FeatureDefinition instances which contain data from feature statements defined in the module.

        The feature is used to define a mechanism by which portions of the schema are marked as conditional.

        Specified by:
        getFeatures in interface ModuleLike
        Returns:
        feature statements in lexicographical order which are specified in the module as the argument of YANG feature statements.
      • getAugmentations

        public Collection<? extends @NonNull AugmentationSchemaNode> getAugmentations()
        Description copied from interface: ModuleLike
        Returns AugmentationSchemaNode instances which contain data from augment statements defined in the module.
        Specified by:
        getAugmentations in interface ModuleLike
        Returns:
        set of the augmentation schema instances which are specified in the module as YANG augment statement and are lexicographically ordered
      • getRpcs

        public Collection<? extends @NonNull RpcDefinition> getRpcs()
        Description copied from interface: ModuleLike
        Returns RpcDefinition instances which contain data from rpc statements defined in the module.
        Specified by:
        getRpcs in interface ModuleLike
        Returns:
        set of the RPC definition instances which are specified in the module as YANG rpc statements and are lexicographicaly ordered
      • getDeviations

        public Collection<? extends @NonNull Deviation> getDeviations()
        Description copied from interface: ModuleLike
        Returns Deviation instances which contain data from deviation statements defined in the module.
        Specified by:
        getDeviations in interface ModuleLike
        Returns:
        set of the deviation instances
      • getExtensionSchemaNodes

        public Collection<? extends @NonNull ExtensionDefinition> getExtensionSchemaNodes()
        Description copied from interface: ModuleLike
        Returns ExtensionDefinition instances which contain data from extension statements defined in the module.
        Specified by:
        getExtensionSchemaNodes in interface ModuleLike
        Returns:
        set of extension definition instances which are specified in the module as YANG extension statements and are lexicographically ordered
      • getIdentities

        public Collection<? extends @NonNull IdentitySchemaNode> getIdentities()
        Description copied from interface: ModuleLike
        Returns IdentitySchemaNode instances which contain data from identity statements defined in the module.
        Specified by:
        getIdentities in interface ModuleLike
        Returns:
        set of identity schema node instances which are specified in the module as YANG identity statements and are lexicographically ordered
      • getChildNodes

        public final Collection<? extends DataSchemaNode> getChildNodes()
        Description copied from interface: DataNodeContainer
        Returns set of all child nodes defined within this DataNodeContainer. Although the return type is a collection, each node is guaranteed to be present at most once.

        Note that the nodes returned are NOT data nodes, but rather DataSchemaNodes, hence ChoiceSchemaNode and CaseSchemaNode are present instead of their children. This is consistent with schema tree.

        Specified by:
        getChildNodes in interface DataNodeContainer
        Returns:
        child nodes in lexicographical order
      • getSemanticVersion

        public Optional<SemVer> getSemanticVersion()
        Description copied from interface: ModuleLike
        Returns the semantic version of YANG module. If the semantic version is not specified, default semantic version of module is returned.
        Specified by:
        getSemanticVersion in interface ModuleLike
        Returns:
        SemVer semantic version of YANG module which is specified as argument of (urn:opendaylight:yang:extension:semantic-version?revision=2016-02-02)semantic-version statement
      • maskList

        protected static final @NonNull Object maskList​(ImmutableList<?> list)
        Utility method for squashing singleton lists into single objects. This is a CPU/mem trade-off, which we are usually willing to make: for the cost of an instanceof check we can save one object and re-create it when needed. The inverse operation is #unmaskSubstatements(Object)}.
        Parameters:
        list - list to mask
        Returns:
        Masked list
        Throws:
        NullPointerException - if list is null
      • unmaskSet

        protected static final <T> @NonNull ImmutableSet<? extends T> unmaskSet​(@NonNull Object masked,
                                                                                @NonNull Class<T> type)