Bug #60 : JSON list responses from the NB-APIs returns native object (instead of...
[controller.git] / opendaylight / northbound / staticrouting / src / main / java / org / opendaylight / controller / forwarding / staticrouting / northbound / StaticRoutingNorthbound.java
index 8462ef804ad0cce4c81819bd6b0369a675673566..65e68aab7d9be627154aebf61856b1b07fe5d68d 100644 (file)
@@ -233,7 +233,7 @@ public class StaticRoutingNorthbound {
             @Context UriInfo uriInfo,
             @PathParam(value = "containerName") String containerName,
             @PathParam(value = "route") String route,
-            @TypeHint(StaticRoute.class) JAXBElement<StaticRoute> staticRouteData) {
+            @TypeHint(StaticRoute.class) StaticRoute staticRouteData) {
 
 
         if(!NorthboundUtils.isAuthorized(getUserName(), containerName,
@@ -253,7 +253,7 @@ public class StaticRoutingNorthbound {
                     .toString());
         }
 
-        StaticRoute sRoute = staticRouteData.getValue();
+        StaticRoute sRoute = staticRouteData;
         StaticRouteConfig cfgObject = new StaticRouteConfig(sRoute.getName(),
                 sRoute.getPrefix(), sRoute.getNextHop());
         Status response = staticRouting.addStaticRoute(cfgObject);