java.lang.Object
java.lang.Record
org.opendaylight.yangtools.yang.parser.api.YangLibModule
Record Components:
identifier - SourceIdentifier of this module, e.g. the combination of name and revision
namespace - XMLNamespace of this module
submodules - Submodules of this module
features - The set of supported features in this module
deviationModuleNames - Names of modules containing deviate statements targetting this module
source - A SchemaSourceRepresentation of the module

public record YangLibModule(@NonNull org.opendaylight.yangtools.yang.model.repo.api.SourceIdentifier identifier, @NonNull XMLNamespace namespace, @NonNull com.google.common.collect.ImmutableMap<UnresolvedQName.Unqualified,YangLibSubmodule> submodules, @NonNull com.google.common.collect.ImmutableSet<UnresolvedQName.Unqualified> features, @NonNull com.google.common.collect.ImmutableSet<UnresolvedQName.Unqualified> deviationModuleNames, @NonNull org.opendaylight.yangtools.yang.model.repo.api.SchemaSourceRepresentation source) extends Record
A single RFC8525 module or import-only-module list entry. Note that the YANG definition has two dissimilar instances, but that really is an artifact of how indexes work in YANG.
  • Constructor Details

    • YangLibModule

      public YangLibModule(@NonNull org.opendaylight.yangtools.yang.model.repo.api.SourceIdentifier identifier, @NonNull XMLNamespace namespace, @NonNull com.google.common.collect.ImmutableMap<UnresolvedQName.Unqualified,YangLibSubmodule> submodules, @NonNull com.google.common.collect.ImmutableSet<UnresolvedQName.Unqualified> features, @NonNull com.google.common.collect.ImmutableSet<UnresolvedQName.Unqualified> deviationModuleNames, @NonNull org.opendaylight.yangtools.yang.model.repo.api.SchemaSourceRepresentation source)
      Creates an instance of a YangLibModule record class.
      Parameters:
      identifier - the value for the identifier record component
      namespace - the value for the namespace record component
      submodules - the value for the submodules record component
      features - the value for the features record component
      deviationModuleNames - the value for the deviationModuleNames record component
      source - the value for the source record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • identifier

      public @NonNull org.opendaylight.yangtools.yang.model.repo.api.SourceIdentifier identifier()
      Returns the value of the identifier record component.
      Returns:
      the value of the identifier record component
    • namespace

      public @NonNull XMLNamespace namespace()
      Returns the value of the namespace record component.
      Returns:
      the value of the namespace record component
    • submodules

      public @NonNull com.google.common.collect.ImmutableMap<UnresolvedQName.Unqualified,YangLibSubmodule> submodules()
      Returns the value of the submodules record component.
      Returns:
      the value of the submodules record component
    • features

      public @NonNull com.google.common.collect.ImmutableSet<UnresolvedQName.Unqualified> features()
      Returns the value of the features record component.
      Returns:
      the value of the features record component
    • deviationModuleNames

      public @NonNull com.google.common.collect.ImmutableSet<UnresolvedQName.Unqualified> deviationModuleNames()
      Returns the value of the deviationModuleNames record component.
      Returns:
      the value of the deviationModuleNames record component
    • source

      public @NonNull org.opendaylight.yangtools.yang.model.repo.api.SchemaSourceRepresentation source()
      Returns the value of the source record component.
      Returns:
      the value of the source record component