Bug-2230: Revision of module RSVP
[bgpcep.git] / pcep / spi / src / main / java / org / opendaylight / protocol / pcep / spi / VendorInformationUtil.java
1 /*
2  * Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8
9 package org.opendaylight.protocol.pcep.spi;
10
11 public final class VendorInformationUtil {
12
13     public static final int VENDOR_INFORMATION_TLV_TYPE = 7;
14
15     public static final int VENDOR_INFORMATION_OBJECT_CLASS = 34;
16
17     public static final int VENDOR_INFORMATION_OBJECT_TYPE = 1;
18
19     private VendorInformationUtil() {
20         throw new UnsupportedOperationException();
21     }
22
23     public static boolean isVendorInformationTlv(final int type) {
24         return type == VENDOR_INFORMATION_TLV_TYPE;
25     }
26
27     public static boolean isVendorInformationObject(final int objectClass, final int objectType) {
28         return objectType == VENDOR_INFORMATION_OBJECT_TYPE && objectClass == VENDOR_INFORMATION_OBJECT_CLASS;
29     }
30 }