X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=restconf%2Fsal-rest-connector%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Frestconf%2Futils%2Fparser%2FParserIdentifier.java;h=6fb58f5a2b923677ccceead051460b8b7bc9ea89;hb=96fa29a30499d4ae0ad21cb9a5c8fe9d401512a4;hp=891784a29903aa7e3f27fc64548c9ae94f0a6f84;hpb=b2fd55e123e82a350337c3733e0809a6f8a02fb3;p=netconf.git diff --git a/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/utils/parser/ParserIdentifier.java b/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/utils/parser/ParserIdentifier.java index 891784a299..6fb58f5a2b 100644 --- a/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/utils/parser/ParserIdentifier.java +++ b/restconf/sal-rest-connector/src/main/java/org/opendaylight/restconf/utils/parser/ParserIdentifier.java @@ -64,6 +64,18 @@ public final class ParserIdentifier { return new InstanceIdentifierContext(deserialize, child.getDataSchemaNode(), null, schemaContext); } + /** + * Make {@link String} from {@link YangInstanceIdentifier} + * + * @param instanceIdentifier + * @param schemaContext + * @return + */ + public static String stringFromYangInstanceIdentifier(final YangInstanceIdentifier instanceIdentifier, + final SchemaContext schemaContext) { + return IdentifierCodec.serialize(instanceIdentifier, schemaContext); + } + /** * Make a {@link QName} from identifier *