@Beta public final class RevisionSourceIdentifier extends SourceIdentifier
Simple transfer object represents revision identifier of source for YANG schema (module or submodule), which consists of
SourceIdentifier.getName()
SourceIdentifier.getRevision())
Revision source identifier is designated to be carry only necessary information to look-up YANG model source and to be used by various SchemaSourceProviders.
Note:On source retrieval layer it is impossible to distinguish between YANG module and/or submodule unless source is present.
(For further reference see: http://tools.ietf.org/html/rfc6020#section-5.2 and http://tools.ietf.org/html/rfc6022#section-3.1 ).
NOT_PRESENT_FORMATTED_REVISION, REVISION_PATTERN| Modifier and Type | Method and Description |
|---|---|
static RevisionSourceIdentifier |
create(String moduleName)
Creates new YANG Schema revision source identifier for sources without
a revision.
|
static RevisionSourceIdentifier |
create(String moduleName,
com.google.common.base.Optional<String> revision)
Creates new YANG Schema revision source identifier.
|
static RevisionSourceIdentifier |
create(String moduleName,
String revision)
Creates new YANG Schema revision source identifier.
|
boolean |
equals(Object obj) |
int |
hashCode() |
String |
toString() |
getName, getRevision, intern, toYangFilename, toYangFileNamepublic static RevisionSourceIdentifier create(String moduleName, com.google.common.base.Optional<String> revision)
moduleName - Name of schemarevision - Revision of source in format YYYY-mm-dd. If not present,
default value will be used.public static RevisionSourceIdentifier create(String moduleName, String revision)
moduleName - Name of schemarevision - Revision of source in format YYYY-mm-ddpublic static RevisionSourceIdentifier create(String moduleName)
moduleName - Name of schemapublic int hashCode()
hashCode in interface IdentifierhashCode in class Objectpublic boolean equals(Object obj)
equals in interface Identifierequals in class Objectpublic String toString()
toString in interface IdentifiertoString in class ObjectCopyright © 2018 OpenDaylight. All rights reserved.