From f509e7029a184e676ca5604e544389d431b96e9f Mon Sep 17 00:00:00 2001 From: Martin Sunal Date: Fri, 11 Apr 2014 12:54:51 +0200 Subject: [PATCH] BUG 718: changed codec for URI parsing Change-Id: Ida06cb8d662ada99d67b994049228c7844d9d41e Signed-off-by: Martin Sunal --- .../controller/sal/restconf/impl/ControllerContext.xtend | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.xtend b/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.xtend index 837d7ae5b7..cb02fc89bf 100644 --- a/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.xtend +++ b/opendaylight/md-sal/sal-rest-connector/src/main/java/org/opendaylight/controller/sal/restconf/impl/ControllerContext.xtend @@ -483,7 +483,7 @@ class ControllerContext implements SchemaContextListener { + "\" cannot contain \"null\" value as a key." ) } - keyValues.addKeyValue(listNode.getDataChildByName(key), uriKeyValue); + keyValues.addKeyValue(listNode.getDataChildByName(key), uriKeyValue, mountPoint); i = i + 1; } consumed = consumed + i; @@ -541,13 +541,13 @@ class ControllerContext implements SchemaContextListener { } } - private def void addKeyValue(HashMap map, DataSchemaNode node, String uriValue) { + private def void addKeyValue(HashMap map, DataSchemaNode node, String uriValue, MountInstance mountPoint) { checkNotNull(uriValue); checkArgument(node instanceof LeafSchemaNode); val urlDecoded = URLDecoder.decode(uriValue); val typedef = (node as LeafSchemaNode).type; - var decoded = TypeDefinitionAwareCodec.from(typedef)?.deserialize(urlDecoded) + var decoded = RestCodec.from(typedef, mountPoint)?.deserialize(urlDecoded) var additionalInfo = "" if(decoded === null) { var baseType = RestUtil.resolveBaseTypeFrom(typedef) -- 2.36.6