<groupId>org.onap.ccsdk.sli.plugins</groupId>
<artifactId>ccsdk-restconf-client</artifactId>
- <version>2.2.0-SNAPSHOT</version>
+ <version>2.3.0-SNAPSHOT</version>
<packaging>feature</packaging>
<name>ccsdk-sli-plugins :: features :: ${project.artifactId}</name>
<type>xml</type>
<classifier>features</classifier>
</dependency>
- <!-- Commented out for now pending Scandium fix-->
- <!--
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>ccsdk-restconf-client</artifactId>
<type>xml</type>
<classifier>features</classifier>
</dependency>
- -->
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>ccsdk-sshapi-call-node</artifactId>
</exclusion>
</exclusions>
</dependency>
- <!--
<dependency>
<groupId>org.onap.ccsdk.sli.plugins</groupId>
<artifactId>ccsdk-restconf-client</artifactId>
</exclusion>
</exclusions>
</dependency>
- -->
<dependency>
<groupId>org.onap.ccsdk.sli.plugins</groupId>
<artifactId>ccsdk-sshapi-call-node</artifactId>
<module>ccsdk-gr-toolkit</module>
<module>ccsdk-properties-node</module>
<module>ccsdk-restapi-call-node</module>
- <!-- <module>ccsdk-restconf-client</module> -->
+ <module>ccsdk-restconf-client</module>
<module>ccsdk-sshapi-call-node</module>
<module>ccsdk-template-node</module>
<module>ccsdk-sli-plugins-all</module>
<module>properties-node</module>
<module>restapi-call-node</module>
<module>sshapi-call-node</module>
- <!--
<module>restconf-client</module>
- -->
<module>template-node</module>
<module>grToolkit</module>
<module>features</module>
<groupId>org.onap.ccsdk.sli.plugins</groupId>
<artifactId>restconf-client-installer</artifactId>
- <version>2.2.0-SNAPSHOT</version>
+ <version>2.3.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>ccsdk-sli-plugins :: ${project.artifactId}</name>
<groupId>org.onap.ccsdk.sli.plugins</groupId>
<artifactId>restconf-client</artifactId>
- <version>2.2.0-SNAPSHOT</version>
+ <version>2.3.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>ccsdk-sli-plugins :: ${project.artifactId}</name>
<groupId>org.onap.ccsdk.sli.plugins</groupId>
<artifactId>restconf-client-provider</artifactId>
- <version>2.2.0-SNAPSHOT</version>
+ <version>2.3.0-SNAPSHOT</version>
<packaging>bundle</packaging>
<name>ccsdk-sli-plugins :: ${project.artifactId}</name>
<version>${project.version}</version>
</dependency>
<dependency>
- <groupId>org.opendaylight.netconf</groupId>
- <artifactId>restconf-nb</artifactId>
- <version>6.0.6</version>
- <exclusions>
- <exclusion>
- <groupId>javax.xml</groupId>
- <artifactId>jsr173</artifactId>
- </exclusion>
- </exclusions>
+ <groupId>org.opendaylight.yangtools</groupId>
+ <artifactId>yang-model-spi</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.opendaylight.yangtools</groupId>
+ <artifactId>yang-data-util</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.opendaylight.yangtools</groupId>
<!-- For test -->
+ <dependency>
+ <groupId>javax.annotation</groupId>
+ <artifactId>javax.annotation-api</artifactId>
+ <version>1.3.2</version>
+ <scope>test</scope>
+ </dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<artifactId>httpclient</artifactId>
</dependency>
</dependencies>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <argLine>
+ --add-opens java.base/java.lang=ALL-UNNAMED
+ ${surefireArgLine}
+ </argLine>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
</project>
--- /dev/null
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP - CCSDK
+ * ================================================================================
+ * Copyright (C) 2025 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.ccsdk.sli.plugins.restconfapicall;
+
+import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
+import org.opendaylight.yangtools.yang.model.api.SchemaNode;
+
+/**
+ * Local replacement for ODL's InstanceIdentifierContext which was removed
+ * in OpenDaylight Scandium. Holds the schema node and schema context
+ * resolved from a RESTCONF URI.
+ */
+public class InstanceIdentifierContext {
+
+ private final SchemaNode schemaNode;
+ private final EffectiveModelContext schemaContext;
+
+ /**
+ * Creates an instance identifier context.
+ *
+ * @param schemaNode the resolved schema node
+ * @param schemaContext the schema context
+ */
+ public InstanceIdentifierContext(SchemaNode schemaNode,
+ EffectiveModelContext schemaContext) {
+ this.schemaNode = schemaNode;
+ this.schemaContext = schemaContext;
+ }
+
+ /**
+ * Returns the schema node resolved from the URI.
+ *
+ * @return schema node
+ */
+ public SchemaNode getSchemaNode() {
+ return schemaNode;
+ }
+
+ /**
+ * Returns the schema context.
+ *
+ * @return schema context (EffectiveModelContext)
+ */
+ public EffectiveModelContext getSchemaContext() {
+ return schemaContext;
+ }
+}
import static org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiUtils.getUpdatedXmlReq;
import static org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiUtils.getYangParameters;
import static org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiUtils.parseUrl;
+import static org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiUtils.toInstanceIdentifier;
import static org.onap.ccsdk.sli.plugins.yangserializers.dfserializer.DfListenerFactory.instance;
import static org.onap.ccsdk.sli.plugins.yangserializers.dfserializer.DfSerializerUtil.FORMAT_ERR;
import static org.onap.ccsdk.sli.plugins.yangserializers.dfserializer.DfSerializerUtil.UTF_HEADER;
import org.onap.ccsdk.sli.plugins.yangserializers.pnserializer.MdsalPropertiesNodeSerializer;
import org.onap.ccsdk.sli.plugins.yangserializers.pnserializer.Namespace;
import org.onap.ccsdk.sli.plugins.yangserializers.pnserializer.PropertiesNodeSerializer;
-import org.opendaylight.restconf.common.context.InstanceIdentifierContext;
-import org.opendaylight.restconf.nb.rfc8040.utils.parser.ParserIdentifier;
import org.opendaylight.yangtools.yang.common.XMLNamespace;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
import org.opendaylight.yangtools.yang.model.api.SchemaNode;
String uri)
throws SvcLogicException {
EffectiveModelContext context = getSchemaContext(params);
- return ParserIdentifier.toInstanceIdentifier(uri, context, null);
+ return toInstanceIdentifier(uri, context, null);
}
/**
import java.net.URISyntaxException;
import java.nio.file.Path;
import java.nio.file.Paths;
+import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import org.onap.ccsdk.sli.core.sli.SvcLogicException;
import org.onap.ccsdk.sli.plugins.restapicall.HttpMethod;
import org.onap.ccsdk.sli.plugins.yangserializers.dfserializer.YangParameters;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.CaseSchemaNode;
+import org.opendaylight.yangtools.yang.model.api.ChoiceSchemaNode;
+import org.opendaylight.yangtools.yang.model.api.DataNodeContainer;
+import org.opendaylight.yangtools.yang.model.api.DataSchemaNode;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
-import org.opendaylight.yangtools.yang.model.repo.api.YangTextSchemaSource;
+import org.opendaylight.yangtools.yang.model.api.Module;
+import org.opendaylight.yangtools.yang.model.api.OperationDefinition;
+import org.opendaylight.yangtools.yang.model.api.RpcDefinition;
+import org.opendaylight.yangtools.yang.model.api.SchemaContext;
+import org.opendaylight.yangtools.yang.model.api.SchemaNode;
+import org.opendaylight.yangtools.yang.model.spi.source.FileYangTextSource;
import org.opendaylight.yangtools.yang.parser.api.YangParser;
import org.opendaylight.yangtools.yang.parser.api.YangParserException;
import org.opendaylight.yangtools.yang.parser.api.YangParserFactory;
YangParser parser = parserFactory.createParser();
for (File file : yangFiles) {
try {
- parser.addSource(YangTextSchemaSource.forPath(file.toPath()));
+ parser.addSource(new FileYangTextSource(file.toPath()));
} catch (IOException | YangSyntaxErrorException e) {
throw new SvcLogicException(YANG_FILE_ERR + e.getMessage(), e);
}
req = req + "</" + nodeName + ">";
return req.replaceAll(">\\s+<", "><");
}
+
+ /**
+ * Resolves a RESTCONF URI path against the given schema context and
+ * returns an InstanceIdentifierContext wrapping the resolved SchemaNode
+ * and schema context.
+ *
+ * <p>This is a local replacement for the ODL ParserIdentifier.toInstanceIdentifier()
+ * which was removed in OpenDaylight Scandium.
+ *
+ * @param uri RESTCONF-style URI path (e.g., "module:container/child=key")
+ * @param context the effective model context
+ * @param unused unused parameter (kept for API compatibility)
+ * @return instance identifier context
+ * @throws IllegalArgumentException if the URI cannot be resolved
+ */
+ public static InstanceIdentifierContext toInstanceIdentifier(
+ String uri, EffectiveModelContext context, Object unused) {
+ if (uri == null || uri.isEmpty()) {
+ return new InstanceIdentifierContext(context, context);
+ }
+
+ String path = uri;
+ if (path.startsWith(SLASH)) {
+ path = path.substring(1);
+ }
+ // Remove trailing slash
+ if (path.endsWith(SLASH)) {
+ path = path.substring(0, path.length() - 1);
+ }
+
+ String[] segments = path.split(SLASH);
+ SchemaNode currentNode = context;
+
+ for (String segment : segments) {
+ // Remove list keys (everything after =)
+ String nodeName = segment;
+ if (nodeName.contains("=")) {
+ nodeName = nodeName.substring(0, nodeName.indexOf("="));
+ }
+
+ String moduleName = null;
+ String localName = nodeName;
+
+ // Split module:name
+ if (nodeName.contains(COLON)) {
+ String[] parts = nodeName.split(COLON, 2);
+ moduleName = parts[0];
+ localName = parts[1];
+ }
+
+ SchemaNode childNode = null;
+
+ if (moduleName != null) {
+ Iterator<? extends Module> modules = context.findModules(moduleName).iterator();
+ if (modules.hasNext()) {
+ Module module = modules.next();
+ QName qname = QName.create(module.getQNameModule(), localName);
+ childNode = findDataChild(currentNode, qname);
+ }
+ } else {
+ // Use the namespace of the current node
+ if (currentNode != null && currentNode.getQName() != null) {
+ QName qname = QName.create(currentNode.getQName().getModule(), localName);
+ childNode = findDataChild(currentNode, qname);
+ }
+ }
+
+ if (childNode == null) {
+ throw new IllegalArgumentException(
+ "Could not find schema node for: " + segment + " in URI: " + uri);
+ }
+
+ currentNode = childNode;
+ }
+
+ return new InstanceIdentifierContext(currentNode, context);
+ }
+
+ /**
+ * Finds a data child schema node by QName, traversing into choice/case
+ * nodes transparently (as RESTCONF URIs don't include choice/case names).
+ *
+ * @param parent parent schema node
+ * @param qname QName of the target data node
+ * @return the found schema node, or null if not found
+ */
+ private static SchemaNode findDataChild(SchemaNode parent, QName qname) {
+ if (parent instanceof DataNodeContainer) {
+ DataNodeContainer container = (DataNodeContainer) parent;
+ // Try direct lookup first
+ DataSchemaNode child = container.dataChildByName(qname);
+ if (child != null) {
+ return child;
+ }
+ // Search inside choice/case nodes (transparent in data tree)
+ SchemaNode found = findInChoices(container, qname);
+ if (found != null) {
+ return found;
+ }
+ }
+ // Search RPCs/operations (for RESTCONF operations URIs)
+ if (parent instanceof SchemaContext) {
+ for (RpcDefinition rpc : ((SchemaContext) parent).getOperations()) {
+ if (qname.equals(rpc.getQName())) {
+ return rpc;
+ }
+ }
+ }
+ if (parent instanceof OperationDefinition) {
+ switch (qname.getLocalName()) {
+ case "input":
+ return ((OperationDefinition) parent).getInput();
+ case "output":
+ return ((OperationDefinition) parent).getOutput();
+ default:
+ break;
+ }
+ }
+ if (parent instanceof ChoiceSchemaNode) {
+ return findInChoice((ChoiceSchemaNode) parent, qname);
+ }
+ return null;
+ }
+
+ /**
+ * Searches for a data node inside choice/case nodes of a container.
+ */
+ private static SchemaNode findInChoices(DataNodeContainer container, QName qname) {
+ for (DataSchemaNode child : container.getChildNodes()) {
+ if (child instanceof ChoiceSchemaNode) {
+ SchemaNode found = findInChoice((ChoiceSchemaNode) child, qname);
+ if (found != null) {
+ return found;
+ }
+ }
+ }
+ return null;
+ }
+
+ /**
+ * Searches for a data node inside a choice's cases.
+ */
+ private static SchemaNode findInChoice(ChoiceSchemaNode choice, QName qname) {
+ for (CaseSchemaNode caze : choice.getCases()) {
+ DataSchemaNode found = caze.dataChildByName(qname);
+ if (found != null) {
+ return found;
+ }
+ // Recursively check nested choices within this case
+ SchemaNode nested = findInChoices(caze, qname);
+ if (nested != null) {
+ return nested;
+ }
+ }
+ return null;
+ }
}
}
mod = it.next();
- return new Namespace(mod.getName(), mod.getQNameModule().getNamespace(),
+ return new Namespace(mod.getName(), mod.getQNameModule().namespace(),
getRevision(mod.getRevision()));
}
import java.util.Map;
import org.onap.ccsdk.sli.core.sli.SvcLogicException;
import org.onap.ccsdk.sli.core.sli.provider.YangUtils;
-import org.opendaylight.restconf.common.errors.RestconfDocumentedException;
import org.opendaylight.yangtools.yang.common.XMLNamespace;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
import org.opendaylight.yangtools.yang.model.api.Module;
import org.opendaylight.yangtools.yang.model.api.SchemaNode;
-import org.opendaylight.yangtools.yang.model.util.SchemaContextUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
String fixedUri = fixedUrl.getUri().replaceAll(
SLASH, DOT_REGEX);
fixedParams.put(fixedUri, entry.getValue());
- } catch (IllegalArgumentException | RestconfDocumentedException
+ } catch (IllegalArgumentException
| NullPointerException e) {
log.info("Exception while processing properties by replacing " +
"underscore with colon. Process the properties as it is." + e);
import static com.google.common.base.Preconditions.checkArgument;
import static java.lang.String.format;
import static java.util.regex.Pattern.quote;
-import static org.opendaylight.restconf.nb.rfc8040.utils.parser.ParserIdentifier.toInstanceIdentifier;
+import static org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiUtils.toInstanceIdentifier;
import java.util.Collection;
import java.util.Deque;
import java.util.Iterator;
import java.util.Optional;
-import com.sun.xml.txw2.annotation.XmlNamespace;
import org.onap.ccsdk.sli.core.sli.SvcLogicException;
import org.onap.ccsdk.sli.core.sli.provider.YangUtils;
-import org.opendaylight.restconf.common.context.InstanceIdentifierContext;
-import org.opendaylight.restconf.common.errors.RestconfDocumentedException;
+import org.onap.ccsdk.sli.plugins.restconfapicall.InstanceIdentifierContext;
import org.opendaylight.yangtools.yang.common.QName;
import org.opendaylight.yangtools.yang.common.Revision;
import org.opendaylight.yangtools.yang.common.XMLNamespace;
import org.opendaylight.yangtools.yang.data.util.codec.IdentityCodecUtil;
import org.opendaylight.yangtools.yang.model.api.*;
import org.opendaylight.yangtools.yang.model.api.Module;
-import org.opendaylight.yangtools.yang.model.util.SchemaInferenceStack;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
InstanceIdentifierContext id = toInstanceIdentifier(
uri1, context, Optional.ofNullable(null));
return new SchemaPathHolder(id, uri1);
- } catch (IllegalArgumentException | RestconfDocumentedException
+ } catch (IllegalArgumentException
| NullPointerException e) {
log.info("Exception while converting uri to instance identifier" +
" context. Process each node in uri to get instance identifier" +
try {
id = toInstanceIdentifier(prefix + val, context, null);
return new SchemaPathHolder(id, val);
- } catch (IllegalArgumentException | RestconfDocumentedException |
+ } catch (IllegalArgumentException |
NullPointerException e) {
log.info(format(INFO_MSG, val, e));
}
try {
id = toInstanceIdentifier(prefix + val, context, null);
return new SchemaPathHolder(id, val);
- } catch (IllegalArgumentException | RestconfDocumentedException |
+ } catch (IllegalArgumentException |
NullPointerException e1) {
throw new IllegalArgumentException(EXC_MSG, e1);
}
Iterator<? extends Module> it = ctx.findModules(modName).iterator();
if (it.hasNext()) {
Module m = it.next();
- return new Namespace(modName, m.getQNameModule().getNamespace(),
+ return new Namespace(modName, m.getQNameModule().namespace(),
getRevision(m.getRevision()));
}
return null;
throw new SvcLogicException("Could not find module node");
}
Module m = module.get();
- return new Namespace(m.getName(), m.getQNameModule().getNamespace(),
+ return new Namespace(m.getName(), m.getQNameModule().namespace(),
getRevision(m.getRevision()));
}
package org.onap.ccsdk.sli.plugins.yangserializers.pnserializer;
-import org.opendaylight.restconf.common.context.InstanceIdentifierContext;
+import org.onap.ccsdk.sli.plugins.restconfapicall.InstanceIdentifierContext;
/**
* Representation of a holder for a proper path and its corresponding schema.
import org.onap.ccsdk.sli.plugins.restapicall.HttpResponse;
import org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode;
import org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiCallNode;
-import org.opendaylight.restconf.common.context.InstanceIdentifierContext;
+import org.onap.ccsdk.sli.plugins.restconfapicall.InstanceIdentifierContext;
import org.opendaylight.yangtools.yang.parser.api.YangParserFactory;
import org.opendaylight.yangtools.yang.parser.impl.DefaultYangParserFactory;
*
* @throws SvcLogicException when test case fails
*/
- /*
- * Fails for potassium - commenting out for now
+ /*
+ * Fails for potassium - commenting out for now
@Test
public void encodeForAnyXml() throws SvcLogicException {
String pre = "execution-service_process.";
import org.onap.ccsdk.sli.plugins.restapicall.HttpResponse;
import org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode;
import org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiCallNode;
-import org.opendaylight.restconf.common.context.InstanceIdentifierContext;
+import org.onap.ccsdk.sli.plugins.restconfapicall.InstanceIdentifierContext;
import org.opendaylight.yangtools.yang.parser.api.YangParserFactory;
import org.opendaylight.yangtools.yang.parser.impl.DefaultYangParserFactory;
import org.junit.Before;
import org.junit.Test;
import org.onap.ccsdk.sli.core.sli.SvcLogicException;
-import org.opendaylight.restconf.common.context.InstanceIdentifierContext;
-import org.opendaylight.restconf.nb.rfc8040.utils.parser.ParserIdentifier;
+import org.onap.ccsdk.sli.plugins.restconfapicall.InstanceIdentifierContext;
import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
+
+import static org.onap.ccsdk.sli.plugins.restconfapicall.RestconfApiUtils.toInstanceIdentifier;
import org.opendaylight.yangtools.yang.test.util.YangParserTestUtils;
public final class PropertiesSerializerTest {
params.put("test-yang_cont1.cont2.ll3[1]", "abc");
params.put("test-yang_cont1.cont2.ll4[0]", "abc");
params.put("test-yang_cont1.cont2.ll4[1]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
params.put("test-yang_cont1.cont2.ll5[0]", "abc");
params.put("test-yang_cont1.cont2.ll5[1]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_cont8.ll7[0]", "abc");
params.put("test-yang_cont8.ll7[1]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_cont9.ll8[0]", "abc");
params.put("test-yang_cont9.cont11.leaf25", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
Map<String, String> params = new HashMap<>();
params.put("test-yang_cont8.cont6.test-augment_leaf21", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_cont13.leaf28", "abc");
params.put("test-yang_cont13.ll9[0]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_cont9.cont11.cont13.list9[0].leaf27", "abc");
params.put("test-yang_cont9.cont11.cont13.leaf28", "abc");
params.put("test-yang_cont9.cont11.cont13.ll9[0]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-augment_cont13.list9[0].leaf27", "abc");
params.put("test-augment_cont13.leaf28", "abc");
params.put("test-augment_cont13.ll9[0]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_cont1.cont2.cont4.test-augment_cont13.leaf28", "abc");
params.put("test-yang_cont1.cont2.cont4.test-augment_cont13.ll9[0]", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_create-sfc.input.cont13.ll9[0]", "abc");
params.put("test-yang_create-sfc.input.test-augment_leaf36", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_create-sfc.output.cont13.ll9[0]", "abc");
params.put("test-yang_create-sfc.output.test-augment_leaf37", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("test-yang_cont18.cont18.list12[1].list12[0].leaf36", "xyz");
params.put("test-yang_cont18.cont18.list12[1].list12[1].leaf36", "hey!");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("leaf41", "hi");
params.put("test-yang_cont18.leaf41", "abc");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
PropertiesNode node = ser.encode(params);
params.put("identity-test_test.con1.interfaces.int-list[0].available.ll[0]", "identity-types:Loopback");
params.put("identity-test_test.con1.interfaces.int-list[0].available.leaf1", "identity-types-second:Ethernet");
params.put("identity-test_test.con1.interfaces.int-list[0].available.leaf2", "identity-types-second:iden2");
- InstanceIdentifierContext iCtx = ParserIdentifier
- .toInstanceIdentifier(uri, context, null);
+ InstanceIdentifierContext iCtx = toInstanceIdentifier(uri, context, null);
PropertiesNodeSerializer ser = new MdsalPropertiesNodeSerializer(
iCtx.getSchemaNode(), context, uri);
}
return YangParserTestUtils.parseYangFiles(yangFiles);
}
-}
\ No newline at end of file
+}