Class YangNames
- java.lang.Object
-
- org.opendaylight.yangtools.yang.common.YangNames
-
-
Field Summary
Fields Modifier and Type Field Description static CharMatcher
IDENTIFIER_START
static CharMatcher
NOT_IDENTIFIER_PART
ACharMatcher
NOT matching second and later characters of a YANGidentifier
ABNF production,(ALPHA / DIGIT / "_" / "-" / ".")
.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Map.Entry<String,@Nullable String>
parseFilename(String baseName)
Parse a file name according to rules outlined in https://tools.ietf.org/html/rfc6020#section-5.2.
-
-
-
Field Detail
-
IDENTIFIER_START
public static final CharMatcher IDENTIFIER_START
-
NOT_IDENTIFIER_PART
public static final CharMatcher NOT_IDENTIFIER_PART
ACharMatcher
NOT matching second and later characters of a YANGidentifier
ABNF production,(ALPHA / DIGIT / "_" / "-" / ".")
.
-
-
Method Detail
-
parseFilename
public static Map.Entry<String,@Nullable String> parseFilename(String baseName)
Parse a file name according to rules outlined in https://tools.ietf.org/html/rfc6020#section-5.2. Input string should be the base path with file extension stripped.- Parameters:
baseName
- file base name- Returns:
- A tuple containing the module name and parsed revision, if present.
- Throws:
NullPointerException
- ifbaseName
is null
-
-