Revert "BUG-47 : unfinished PCEP migration to generated DTOs."
[bgpcep.git] / pcep / api / src / main / java / org / opendaylight / protocol / pcep / concepts / CumulativeTECostMetric.java
1 /*
2  * Copyright (c) 2013 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 package org.opendaylight.protocol.pcep.concepts;
9
10 import org.opendaylight.protocol.concepts.AbstractMetric;
11
12 /**
13  * Cumulative TE cost metric class
14  */
15 public class CumulativeTECostMetric extends AbstractMetric<CumulativeTECostMetric> {
16
17         private static final long serialVersionUID = 3935025327997428991L;
18
19         /**
20          * Construct a new Cumulative TE cost metric object.
21          * 
22          * @param value
23          *            Metric value
24          * @throws IllegalArgumentException
25          *             ex when value is outside of allowed range (0-4294967295)
26          */
27         public CumulativeTECostMetric(final long value) {
28                 super(value);
29                 if (value < 0 || value > 4294967295L)
30                         throw new IllegalArgumentException("Invalid cumulative TE cost metric value");
31         }
32 }