BUG-47 : removed PCEPMessage interface, switched to generated Message.
[bgpcep.git] / pcep / impl / src / main / java / org / opendaylight / protocol / pcep / impl / message / PCEPOpenMessageValidator.java
index 47105eaa8e15b98810705e0d3379b0f99561dbeb..6ef9841bfdf4dd3a46a1bdf82ccebad02da29b30 100644 (file)
@@ -11,11 +11,11 @@ import java.util.ArrayList;
 import java.util.List;
 
 import org.opendaylight.protocol.pcep.PCEPDeserializerException;
-import org.opendaylight.protocol.pcep.PCEPMessage;
 import org.opendaylight.protocol.pcep.PCEPObject;
 import org.opendaylight.protocol.pcep.impl.PCEPMessageValidator;
 import org.opendaylight.protocol.pcep.message.PCEPOpenMessage;
 import org.opendaylight.protocol.pcep.object.PCEPOpenObject;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev131005.Message;
 
 /**
  * PCEPOpenMessage validator. Validates message integrity.
@@ -23,7 +23,7 @@ import org.opendaylight.protocol.pcep.object.PCEPOpenObject;
 public class PCEPOpenMessageValidator extends PCEPMessageValidator {
 
        @Override
-       public List<PCEPMessage> validate(List<PCEPObject> objects) throws PCEPDeserializerException {
+       public List<Message> validate(final List<PCEPObject> objects) throws PCEPDeserializerException {
                if (objects == null)
                        throw new IllegalArgumentException("Passed list can't be null.");
 
@@ -36,7 +36,7 @@ public class PCEPOpenMessageValidator extends PCEPMessageValidator {
                if (!objects.isEmpty())
                        throw new PCEPDeserializerException("Unprocessed Objects: " + objects);
 
-               return new ArrayList<PCEPMessage>() {
+               return new ArrayList<Message>() {
                        private static final long serialVersionUID = 1L;
                        {
                                this.add(msg);