Remove RestconfError.ErrorType
[netconf.git] / restconf / restconf-nb-bierman02 / src / main / java / org / opendaylight / netconf / sal / restconf / impl / QueryParametersParser.java
index 8dabbf7cde5c3b24d15b4f453e6cf58e7e951a00..aea1864d414adda34e9ff45d6359fb3d3becad71 100644 (file)
@@ -12,6 +12,7 @@ import javax.ws.rs.core.UriInfo;
 import org.opendaylight.restconf.common.context.WriterParameters;
 import org.opendaylight.restconf.common.errors.RestconfDocumentedException;
 import org.opendaylight.restconf.common.errors.RestconfError;
+import org.opendaylight.yangtools.yang.common.ErrorType;
 
 public final class QueryParametersParser {
 
@@ -56,14 +57,14 @@ public final class QueryParametersParser {
                 final int depth = Integer.parseInt(param);
                 if (depth < 1) {
                     throw new RestconfDocumentedException(
-                            new RestconfError(RestconfError.ErrorType.PROTOCOL, RestconfError.ErrorTag.INVALID_VALUE,
+                            new RestconfError(ErrorType.PROTOCOL, RestconfError.ErrorTag.INVALID_VALUE,
                             "Invalid depth parameter: " + depth, null,
                             "The depth parameter must be an integer > 1 or \"unbounded\""));
                 }
                 wpBuilder.setDepth(depth);
             } catch (final NumberFormatException e) {
                 throw new RestconfDocumentedException(e, new RestconfError(
-                        RestconfError.ErrorType.PROTOCOL, RestconfError.ErrorTag.INVALID_VALUE,
+                        ErrorType.PROTOCOL, RestconfError.ErrorTag.INVALID_VALUE,
                         "Invalid depth parameter: " + e.getMessage(), null,
                         "The depth parameter must be an integer > 1 or \"unbounded\""));
             }