2 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.protocol.pcep.spi;
10 import java.util.List;
12 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev131005.Message;
15 * Class representing raw message.
17 public class RawMessage implements Message {
18 private final PCEPMessageType msgType;
19 private final List<Object> objects;
21 public RawMessage(final List<Object> objects, final PCEPMessageType msgType) {
22 this.msgType = msgType;
23 if (objects.contains(null)) {
24 throw new IllegalArgumentException("Object list contains null element at offset " + objects.indexOf(null));
26 this.objects = objects;
29 public PCEPMessageType getMsgType() {
33 public List<Object> getAllObjects() {
38 public Class<Message> getImplementedInterface() {