Committed by
Gerrit Code Review
Use diamond operator
Change-Id: Ic7637e41b9e6a4ac04cd81caf07cea0e7a30909c
Showing
38 changed files
with
70 additions
and
70 deletions
... | @@ -569,7 +569,7 @@ class PcepChannelHandler extends IdleStateAwareChannelHandler { | ... | @@ -569,7 +569,7 @@ class PcepChannelHandler extends IdleStateAwareChannelHandler { |
569 | * @throws PcepParseException while bulding error message | 569 | * @throws PcepParseException while bulding error message |
570 | */ | 570 | */ |
571 | public PcepErrorMsg getErrorMsg(byte errorType, byte errorValue) throws PcepParseException { | 571 | public PcepErrorMsg getErrorMsg(byte errorType, byte errorValue) throws PcepParseException { |
572 | - LinkedList<PcepErrorObject> llerrObj = new LinkedList<PcepErrorObject>(); | 572 | + LinkedList<PcepErrorObject> llerrObj = new LinkedList<>(); |
573 | PcepErrorMsg errMsg; | 573 | PcepErrorMsg errMsg; |
574 | 574 | ||
575 | PcepErrorObject errObj = factory1.buildPcepErrorObject() | 575 | PcepErrorObject errObj = factory1.buildPcepErrorObject() |
... | @@ -597,7 +597,7 @@ class PcepChannelHandler extends IdleStateAwareChannelHandler { | ... | @@ -597,7 +597,7 @@ class PcepChannelHandler extends IdleStateAwareChannelHandler { |
597 | } else { | 597 | } else { |
598 | 598 | ||
599 | //If Error caught in other than Openmessage | 599 | //If Error caught in other than Openmessage |
600 | - LinkedList<PcepError> llPcepErr = new LinkedList<PcepError>(); | 600 | + LinkedList<PcepError> llPcepErr = new LinkedList<>(); |
601 | 601 | ||
602 | PcepError pcepErr = factory1.buildPcepError() | 602 | PcepError pcepErr = factory1.buildPcepError() |
603 | .setErrorObjList(llerrObj) | 603 | .setErrorObjList(llerrObj) | ... | ... |
... | @@ -47,7 +47,7 @@ public class PcepClientControllerImpl implements PcepClientController { | ... | @@ -47,7 +47,7 @@ public class PcepClientControllerImpl implements PcepClientController { |
47 | private static final Logger log = LoggerFactory.getLogger(PcepClientControllerImpl.class); | 47 | private static final Logger log = LoggerFactory.getLogger(PcepClientControllerImpl.class); |
48 | 48 | ||
49 | protected ConcurrentHashMap<PccId, PcepClient> connectedClients = | 49 | protected ConcurrentHashMap<PccId, PcepClient> connectedClients = |
50 | - new ConcurrentHashMap<PccId, PcepClient>(); | 50 | + new ConcurrentHashMap<>(); |
51 | 51 | ||
52 | protected PcepClientAgent agent = new PcepClientAgent(); | 52 | protected PcepClientAgent agent = new PcepClientAgent(); |
53 | protected Set<PcepClientListener> pcepClientListener = new HashSet<>(); | 53 | protected Set<PcepClientListener> pcepClientListener = new HashSet<>(); | ... | ... |
... | @@ -57,7 +57,7 @@ public class PcepMessageDecoder extends FrameDecoder { | ... | @@ -57,7 +57,7 @@ public class PcepMessageDecoder extends FrameDecoder { |
57 | // a list of the parsed messages to the controller. | 57 | // a list of the parsed messages to the controller. |
58 | // The performance *may or may not* not be as good as before. | 58 | // The performance *may or may not* not be as good as before. |
59 | PcepMessageReader<PcepMessage> reader = PcepFactories.getGenericReader(); | 59 | PcepMessageReader<PcepMessage> reader = PcepFactories.getGenericReader(); |
60 | - List<PcepMessage> msgList = new LinkedList<PcepMessage>(); | 60 | + List<PcepMessage> msgList = new LinkedList<>(); |
61 | 61 | ||
62 | while (buffer.readableBytes() > 0) { | 62 | while (buffer.readableBytes() > 0) { |
63 | PcepMessage message = reader.readFrom(buffer); | 63 | PcepMessage message = reader.readFrom(buffer); | ... | ... |
... | @@ -144,7 +144,7 @@ public class PcepAttributeVer1 implements PcepAttribute { | ... | @@ -144,7 +144,7 @@ public class PcepAttributeVer1 implements PcepAttribute { |
144 | public boolean parseMetricList(ChannelBuffer cb) throws PcepParseException { | 144 | public boolean parseMetricList(ChannelBuffer cb) throws PcepParseException { |
145 | 145 | ||
146 | if (llMetricList == null) { | 146 | if (llMetricList == null) { |
147 | - llMetricList = new LinkedList<PcepMetricObject>(); | 147 | + llMetricList = new LinkedList<>(); |
148 | } | 148 | } |
149 | 149 | ||
150 | PcepMetricObject metriclist; | 150 | PcepMetricObject metriclist; | ... | ... |
... | @@ -131,7 +131,7 @@ class PcepCloseMsgVer1 implements PcepCloseMsg { | ... | @@ -131,7 +131,7 @@ class PcepCloseMsgVer1 implements PcepCloseMsg { |
131 | */ | 131 | */ |
132 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { | 132 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { |
133 | 133 | ||
134 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 134 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
135 | /* | 135 | /* |
136 | rfc 5440: | 136 | rfc 5440: |
137 | Optional TLVs may be included within the CLOSE object body. The | 137 | Optional TLVs may be included within the CLOSE object body. The |
... | @@ -164,7 +164,7 @@ class PcepCloseMsgVer1 implements PcepCloseMsg { | ... | @@ -164,7 +164,7 @@ class PcepCloseMsgVer1 implements PcepCloseMsg { |
164 | private PcepObjectHeader closeObjHeader; | 164 | private PcepObjectHeader closeObjHeader; |
165 | private boolean bIsReasonSet = false; | 165 | private boolean bIsReasonSet = false; |
166 | private byte yReason; | 166 | private byte yReason; |
167 | - private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 167 | + private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
168 | 168 | ||
169 | private boolean bIsPFlagSet = false; | 169 | private boolean bIsPFlagSet = false; |
170 | private boolean bPFlag; | 170 | private boolean bPFlag; | ... | ... |
... | @@ -153,7 +153,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { | ... | @@ -153,7 +153,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { |
153 | PcepObjectHeader.REQ_OBJ_OPTIONAL_PROCESS, PcepObjectHeader.RSP_OBJ_PROCESSED, ERO_OBJ_MINIMUM_LENGTH); | 153 | PcepObjectHeader.REQ_OBJ_OPTIONAL_PROCESS, PcepObjectHeader.RSP_OBJ_PROCESSED, ERO_OBJ_MINIMUM_LENGTH); |
154 | 154 | ||
155 | private PcepObjectHeader eroObjHeader; | 155 | private PcepObjectHeader eroObjHeader; |
156 | - private LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 156 | + private LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
157 | 157 | ||
158 | /** | 158 | /** |
159 | * reset variables. | 159 | * reset variables. |
... | @@ -213,7 +213,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { | ... | @@ -213,7 +213,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { |
213 | public static PcepEroObject read(ChannelBuffer cb) throws PcepParseException { | 213 | public static PcepEroObject read(ChannelBuffer cb) throws PcepParseException { |
214 | 214 | ||
215 | PcepObjectHeader eroObjHeader; | 215 | PcepObjectHeader eroObjHeader; |
216 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 216 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
217 | 217 | ||
218 | eroObjHeader = PcepObjectHeader.read(cb); | 218 | eroObjHeader = PcepObjectHeader.read(cb); |
219 | 219 | ||
... | @@ -239,7 +239,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { | ... | @@ -239,7 +239,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { |
239 | */ | 239 | */ |
240 | protected static LinkedList<PcepValueType> parseSubObjects(ChannelBuffer cb) throws PcepParseException { | 240 | protected static LinkedList<PcepValueType> parseSubObjects(ChannelBuffer cb) throws PcepParseException { |
241 | 241 | ||
242 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 242 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
243 | 243 | ||
244 | while (0 < cb.readableBytes()) { | 244 | while (0 < cb.readableBytes()) { |
245 | 245 | ||
... | @@ -342,7 +342,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { | ... | @@ -342,7 +342,7 @@ public class PcepEroObjectVer1 implements PcepEroObject { |
342 | private boolean bIFlag; | 342 | private boolean bIFlag; |
343 | 343 | ||
344 | private PcepObjectHeader eroObjHeader; | 344 | private PcepObjectHeader eroObjHeader; |
345 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 345 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
346 | 346 | ||
347 | @Override | 347 | @Override |
348 | public PcepEroObject build() { | 348 | public PcepEroObject build() { | ... | ... |
... | @@ -50,7 +50,7 @@ public class PcepErrorInfoVer1 implements PcepErrorInfo { | ... | @@ -50,7 +50,7 @@ public class PcepErrorInfoVer1 implements PcepErrorInfo { |
50 | */ | 50 | */ |
51 | public PcepErrorInfoVer1(LinkedList<PcepRPObject> llRPObjList, LinkedList<PcepTEObject> llTEObjList, | 51 | public PcepErrorInfoVer1(LinkedList<PcepRPObject> llRPObjList, LinkedList<PcepTEObject> llTEObjList, |
52 | LinkedList<PcepErrorObject> llErrObjList) { | 52 | LinkedList<PcepErrorObject> llErrObjList) { |
53 | - this.errList = new LinkedList<PcepError>(); | 53 | + this.errList = new LinkedList<>(); |
54 | if ((llErrObjList != null) && (!llErrObjList.isEmpty())) { | 54 | if ((llErrObjList != null) && (!llErrObjList.isEmpty())) { |
55 | this.errList.add(new PcepErrorVer1(llRPObjList, llTEObjList, llErrObjList)); | 55 | this.errList.add(new PcepErrorVer1(llRPObjList, llTEObjList, llErrObjList)); |
56 | } | 56 | } |
... | @@ -133,7 +133,7 @@ public class PcepErrorInfoVer1 implements PcepErrorInfo { | ... | @@ -133,7 +133,7 @@ public class PcepErrorInfoVer1 implements PcepErrorInfo { |
133 | 133 | ||
134 | @Override | 134 | @Override |
135 | public LinkedList<Integer> getErrorType() { | 135 | public LinkedList<Integer> getErrorType() { |
136 | - LinkedList<Integer> errorType = new LinkedList<Integer>(); | 136 | + LinkedList<Integer> errorType = new LinkedList<>(); |
137 | ListIterator<PcepError> listIterator = errList.listIterator(); | 137 | ListIterator<PcepError> listIterator = errList.listIterator(); |
138 | PcepErrorObject errObj; | 138 | PcepErrorObject errObj; |
139 | int error; | 139 | int error; |
... | @@ -154,7 +154,7 @@ public class PcepErrorInfoVer1 implements PcepErrorInfo { | ... | @@ -154,7 +154,7 @@ public class PcepErrorInfoVer1 implements PcepErrorInfo { |
154 | 154 | ||
155 | @Override | 155 | @Override |
156 | public LinkedList<Integer> getErrorValue() { | 156 | public LinkedList<Integer> getErrorValue() { |
157 | - LinkedList<Integer> errorValue = new LinkedList<Integer>(); | 157 | + LinkedList<Integer> errorValue = new LinkedList<>(); |
158 | ListIterator<PcepError> listIterator = errList.listIterator(); | 158 | ListIterator<PcepError> listIterator = errList.listIterator(); |
159 | PcepErrorObject errObj; | 159 | PcepErrorObject errObj; |
160 | int error; | 160 | int error; | ... | ... |
... | @@ -142,7 +142,7 @@ public class PcepErrorMsgVer1 implements PcepErrorMsg { | ... | @@ -142,7 +142,7 @@ public class PcepErrorMsgVer1 implements PcepErrorMsg { |
142 | } | 142 | } |
143 | 143 | ||
144 | //parse PCEP-ERROR list | 144 | //parse PCEP-ERROR list |
145 | - llErrObjList = new LinkedList<PcepErrorObject>(); | 145 | + llErrObjList = new LinkedList<>(); |
146 | tempObjHeader = parseErrorObjectList(llErrObjList, cb); | 146 | tempObjHeader = parseErrorObjectList(llErrObjList, cb); |
147 | 147 | ||
148 | //check whether OPEN-OBJECT is present. | 148 | //check whether OPEN-OBJECT is present. |
... | @@ -323,7 +323,7 @@ public class PcepErrorMsgVer1 implements PcepErrorMsg { | ... | @@ -323,7 +323,7 @@ public class PcepErrorMsgVer1 implements PcepErrorMsg { |
323 | * @return error types list | 323 | * @return error types list |
324 | */ | 324 | */ |
325 | public LinkedList<Integer> getErrorType() { | 325 | public LinkedList<Integer> getErrorType() { |
326 | - LinkedList<Integer> llErrorType = new LinkedList<Integer>(); | 326 | + LinkedList<Integer> llErrorType = new LinkedList<>(); |
327 | if ((errObjListWithOpen != null) | 327 | if ((errObjListWithOpen != null) |
328 | && (errObjListWithOpen.isErrorObjListWithOpenPresent())) { | 328 | && (errObjListWithOpen.isErrorObjListWithOpenPresent())) { |
329 | llErrorType = errObjListWithOpen.getErrorType(); | 329 | llErrorType = errObjListWithOpen.getErrorType(); |
... | @@ -340,7 +340,7 @@ public class PcepErrorMsgVer1 implements PcepErrorMsg { | ... | @@ -340,7 +340,7 @@ public class PcepErrorMsgVer1 implements PcepErrorMsg { |
340 | * @return error value list | 340 | * @return error value list |
341 | */ | 341 | */ |
342 | public LinkedList<Integer> getErrorValue() { | 342 | public LinkedList<Integer> getErrorValue() { |
343 | - LinkedList<Integer> llErrorValue = new LinkedList<Integer>(); | 343 | + LinkedList<Integer> llErrorValue = new LinkedList<>(); |
344 | if ((errObjListWithOpen != null) | 344 | if ((errObjListWithOpen != null) |
345 | && (errObjListWithOpen.isErrorObjListWithOpenPresent())) { | 345 | && (errObjListWithOpen.isErrorObjListWithOpenPresent())) { |
346 | llErrorValue = errObjListWithOpen.getErrorValue(); | 346 | llErrorValue = errObjListWithOpen.getErrorValue(); | ... | ... |
... | @@ -149,7 +149,7 @@ public class PcepErrorObjectVer1 implements PcepErrorObject { | ... | @@ -149,7 +149,7 @@ public class PcepErrorObjectVer1 implements PcepErrorObject { |
149 | */ | 149 | */ |
150 | protected static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) { | 150 | protected static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) { |
151 | 151 | ||
152 | - LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<PcepValueType>(); | 152 | + LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<>(); |
153 | 153 | ||
154 | byte[] yTemp = new byte[cb.readableBytes()]; | 154 | byte[] yTemp = new byte[cb.readableBytes()]; |
155 | cb.readBytes(yTemp); | 155 | cb.readBytes(yTemp); |
... | @@ -239,7 +239,7 @@ public class PcepErrorObjectVer1 implements PcepErrorObject { | ... | @@ -239,7 +239,7 @@ public class PcepErrorObjectVer1 implements PcepErrorObject { |
239 | private boolean bIsIFlagSet = false; | 239 | private boolean bIsIFlagSet = false; |
240 | private boolean bIFlag; | 240 | private boolean bIFlag; |
241 | 241 | ||
242 | - private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 242 | + private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
243 | 243 | ||
244 | @Override | 244 | @Override |
245 | public PcepErrorObject build() { | 245 | public PcepErrorObject build() { | ... | ... |
... | @@ -117,7 +117,7 @@ public class PcepErrorVer1 implements PcepError { | ... | @@ -117,7 +117,7 @@ public class PcepErrorVer1 implements PcepError { |
117 | byte yObjClass; | 117 | byte yObjClass; |
118 | byte yObjType; | 118 | byte yObjType; |
119 | 119 | ||
120 | - llRPObjList = new LinkedList<PcepRPObject>(); | 120 | + llRPObjList = new LinkedList<>(); |
121 | 121 | ||
122 | // caller should verify for RP object | 122 | // caller should verify for RP object |
123 | if (cb.readableBytes() < OBJECT_HEADER_LENGTH) { | 123 | if (cb.readableBytes() < OBJECT_HEADER_LENGTH) { |
... | @@ -157,7 +157,7 @@ public class PcepErrorVer1 implements PcepError { | ... | @@ -157,7 +157,7 @@ public class PcepErrorVer1 implements PcepError { |
157 | byte yObjClass; | 157 | byte yObjClass; |
158 | byte yObjType; | 158 | byte yObjType; |
159 | 159 | ||
160 | - llTEObjList = new LinkedList<PcepTEObject>(); | 160 | + llTEObjList = new LinkedList<>(); |
161 | 161 | ||
162 | // caller should verify for TE object | 162 | // caller should verify for TE object |
163 | if (cb.readableBytes() < OBJECT_HEADER_LENGTH) { | 163 | if (cb.readableBytes() < OBJECT_HEADER_LENGTH) { |
... | @@ -199,7 +199,7 @@ public class PcepErrorVer1 implements PcepError { | ... | @@ -199,7 +199,7 @@ public class PcepErrorVer1 implements PcepError { |
199 | byte yObjType; | 199 | byte yObjType; |
200 | boolean bIsErrorObjFound = false; | 200 | boolean bIsErrorObjFound = false; |
201 | 201 | ||
202 | - llErrObjList = new LinkedList<PcepErrorObject>(); | 202 | + llErrObjList = new LinkedList<>(); |
203 | 203 | ||
204 | // caller should verify for RP object | 204 | // caller should verify for RP object |
205 | if (cb.readableBytes() < OBJECT_HEADER_LENGTH) { | 205 | if (cb.readableBytes() < OBJECT_HEADER_LENGTH) { | ... | ... |
... | @@ -87,7 +87,7 @@ class PcepInitiateMsgVer1 implements PcepInitiateMsg { | ... | @@ -87,7 +87,7 @@ class PcepInitiateMsgVer1 implements PcepInitiateMsg { |
87 | return null; | 87 | return null; |
88 | } | 88 | } |
89 | 89 | ||
90 | - llPcInitiatedLspRequestList = new LinkedList<PcInitiatedLspRequest>(); | 90 | + llPcInitiatedLspRequestList = new LinkedList<>(); |
91 | 91 | ||
92 | byte version = cb.readByte(); | 92 | byte version = cb.readByte(); |
93 | version = (byte) (version >> PcepMessageVer1.SHIFT_FLAG); | 93 | version = (byte) (version >> PcepMessageVer1.SHIFT_FLAG); | ... | ... |
... | @@ -73,7 +73,7 @@ public class PcepIroObjectVer1 implements PcepIroObject { | ... | @@ -73,7 +73,7 @@ public class PcepIroObjectVer1 implements PcepIroObject { |
73 | private byte yPrefixLength; | 73 | private byte yPrefixLength; |
74 | private byte yResvd; | 74 | private byte yResvd; |
75 | private PcepObjectHeader iroObjHeader; | 75 | private PcepObjectHeader iroObjHeader; |
76 | - private LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 76 | + private LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * Default constructor. | 79 | * Default constructor. |
... | @@ -152,7 +152,7 @@ public class PcepIroObjectVer1 implements PcepIroObject { | ... | @@ -152,7 +152,7 @@ public class PcepIroObjectVer1 implements PcepIroObject { |
152 | */ | 152 | */ |
153 | protected static LinkedList<PcepValueType> parseSubObjects(ChannelBuffer cb) throws PcepParseException { | 153 | protected static LinkedList<PcepValueType> parseSubObjects(ChannelBuffer cb) throws PcepParseException { |
154 | 154 | ||
155 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 155 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
156 | 156 | ||
157 | while (0 < cb.readableBytes()) { | 157 | while (0 < cb.readableBytes()) { |
158 | 158 | ||
... | @@ -228,7 +228,7 @@ public class PcepIroObjectVer1 implements PcepIroObject { | ... | @@ -228,7 +228,7 @@ public class PcepIroObjectVer1 implements PcepIroObject { |
228 | private boolean bIsHeaderSet = false; | 228 | private boolean bIsHeaderSet = false; |
229 | 229 | ||
230 | private PcepObjectHeader iroObjHeader; | 230 | private PcepObjectHeader iroObjHeader; |
231 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 231 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
232 | 232 | ||
233 | private boolean bIsPFlagSet = false; | 233 | private boolean bIsPFlagSet = false; |
234 | private boolean bPFlag; | 234 | private boolean bPFlag; | ... | ... |
... | @@ -138,7 +138,7 @@ public class PcepLabelObjectVer1 implements PcepLabelObject { | ... | @@ -138,7 +138,7 @@ public class PcepLabelObjectVer1 implements PcepLabelObject { |
138 | int label; | 138 | int label; |
139 | 139 | ||
140 | // Optional TLV | 140 | // Optional TLV |
141 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 141 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
142 | labelObjHeader = PcepObjectHeader.read(cb); | 142 | labelObjHeader = PcepObjectHeader.read(cb); |
143 | 143 | ||
144 | //take only LspObject buffer. | 144 | //take only LspObject buffer. |
... | @@ -191,7 +191,7 @@ public class PcepLabelObjectVer1 implements PcepLabelObject { | ... | @@ -191,7 +191,7 @@ public class PcepLabelObjectVer1 implements PcepLabelObject { |
191 | */ | 191 | */ |
192 | protected static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { | 192 | protected static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { |
193 | 193 | ||
194 | - LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<PcepValueType>(); | 194 | + LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<>(); |
195 | 195 | ||
196 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { | 196 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { |
197 | 197 | ||
... | @@ -272,7 +272,7 @@ public class PcepLabelObjectVer1 implements PcepLabelObject { | ... | @@ -272,7 +272,7 @@ public class PcepLabelObjectVer1 implements PcepLabelObject { |
272 | private boolean bOFlag; | 272 | private boolean bOFlag; |
273 | private int label; | 273 | private int label; |
274 | 274 | ||
275 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 275 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
276 | 276 | ||
277 | private boolean bIsPFlagSet = false; | 277 | private boolean bIsPFlagSet = false; |
278 | private boolean bPFlag; | 278 | private boolean bPFlag; | ... | ... |
... | @@ -142,7 +142,7 @@ public class PcepLabelRangeObjectVer1 implements PcepLabelRangeObject { | ... | @@ -142,7 +142,7 @@ public class PcepLabelRangeObjectVer1 implements PcepLabelRangeObject { |
142 | int rangeSize; | 142 | int rangeSize; |
143 | int labelBase; | 143 | int labelBase; |
144 | 144 | ||
145 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 145 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
146 | 146 | ||
147 | labelRangeObjHeader = PcepObjectHeader.read(cb); | 147 | labelRangeObjHeader = PcepObjectHeader.read(cb); |
148 | 148 | ||
... | @@ -189,7 +189,7 @@ public class PcepLabelRangeObjectVer1 implements PcepLabelRangeObject { | ... | @@ -189,7 +189,7 @@ public class PcepLabelRangeObjectVer1 implements PcepLabelRangeObject { |
189 | */ | 189 | */ |
190 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { | 190 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { |
191 | 191 | ||
192 | - LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<PcepValueType>(); | 192 | + LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<>(); |
193 | 193 | ||
194 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { | 194 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { |
195 | 195 | ||
... | @@ -272,7 +272,7 @@ public class PcepLabelRangeObjectVer1 implements PcepLabelRangeObject { | ... | @@ -272,7 +272,7 @@ public class PcepLabelRangeObjectVer1 implements PcepLabelRangeObject { |
272 | private boolean bIFlag; | 272 | private boolean bIFlag; |
273 | private PcepObjectHeader labelRangeObjHeader; | 273 | private PcepObjectHeader labelRangeObjHeader; |
274 | 274 | ||
275 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 275 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
276 | 276 | ||
277 | @Override | 277 | @Override |
278 | public PcepLabelRangeObject build() throws PcepParseException { | 278 | public PcepLabelRangeObject build() throws PcepParseException { | ... | ... |
... | @@ -104,7 +104,7 @@ public class PcepLabelRangeVer1 implements PcepLabelRange { | ... | @@ -104,7 +104,7 @@ public class PcepLabelRangeVer1 implements PcepLabelRange { |
104 | throw new PcepParseException("Exception while parsing srp object"); | 104 | throw new PcepParseException("Exception while parsing srp object"); |
105 | } | 105 | } |
106 | 106 | ||
107 | - LinkedList<PcepLabelRangeObject> llLabelRangeList = new LinkedList<PcepLabelRangeObject>(); | 107 | + LinkedList<PcepLabelRangeObject> llLabelRangeList = new LinkedList<>(); |
108 | boolean bFoundLabelRangeObj = false; | 108 | boolean bFoundLabelRangeObj = false; |
109 | while (0 < cb.readableBytes()) { | 109 | while (0 < cb.readableBytes()) { |
110 | //parse and store <labelrange-list> | 110 | //parse and store <labelrange-list> | ... | ... |
... | @@ -118,7 +118,7 @@ class PcepLabelUpdateMsgVer1 implements PcepLabelUpdateMsg { | ... | @@ -118,7 +118,7 @@ class PcepLabelUpdateMsgVer1 implements PcepLabelUpdateMsg { |
118 | public LinkedList<PcepLabelUpdate> parsePcLabelUpdateList(ChannelBuffer cb) throws PcepParseException { | 118 | public LinkedList<PcepLabelUpdate> parsePcLabelUpdateList(ChannelBuffer cb) throws PcepParseException { |
119 | 119 | ||
120 | LinkedList<PcepLabelUpdate> llPcLabelUpdateList; | 120 | LinkedList<PcepLabelUpdate> llPcLabelUpdateList; |
121 | - llPcLabelUpdateList = new LinkedList<PcepLabelUpdate>(); | 121 | + llPcLabelUpdateList = new LinkedList<>(); |
122 | 122 | ||
123 | while (0 < cb.readableBytes()) { | 123 | while (0 < cb.readableBytes()) { |
124 | llPcLabelUpdateList.add(PcepLabelUpdateVer1.read(cb)); | 124 | llPcLabelUpdateList.add(PcepLabelUpdateVer1.read(cb)); | ... | ... |
... | @@ -185,7 +185,7 @@ public class PcepLabelUpdateVer1 implements PcepLabelUpdate { | ... | @@ -185,7 +185,7 @@ public class PcepLabelUpdateVer1 implements PcepLabelUpdate { |
185 | labelDownload.setLspObject(PcepLspObjectVer1.read(cb)); | 185 | labelDownload.setLspObject(PcepLspObjectVer1.read(cb)); |
186 | 186 | ||
187 | //<label-list> | 187 | //<label-list> |
188 | - LinkedList<PcepLabelObject> llLabelList = new LinkedList<PcepLabelObject>(); | 188 | + LinkedList<PcepLabelObject> llLabelList = new LinkedList<>(); |
189 | PcepLabelObject labelObject; | 189 | PcepLabelObject labelObject; |
190 | 190 | ||
191 | while (0 < cb.readableBytes()) { | 191 | while (0 < cb.readableBytes()) { | ... | ... |
... | @@ -234,7 +234,7 @@ public class PcepLspObjectVer1 implements PcepLspObject { | ... | @@ -234,7 +234,7 @@ public class PcepLspObjectVer1 implements PcepLspObject { |
234 | boolean bDFlag; | 234 | boolean bDFlag; |
235 | 235 | ||
236 | // Optional TLV | 236 | // Optional TLV |
237 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 237 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
238 | 238 | ||
239 | lspObjHeader = PcepObjectHeader.read(cb); | 239 | lspObjHeader = PcepObjectHeader.read(cb); |
240 | 240 | ||
... | @@ -314,7 +314,7 @@ public class PcepLspObjectVer1 implements PcepLspObject { | ... | @@ -314,7 +314,7 @@ public class PcepLspObjectVer1 implements PcepLspObject { |
314 | 314 | ||
315 | LinkedList<PcepValueType> llOutOptionalTlv; | 315 | LinkedList<PcepValueType> llOutOptionalTlv; |
316 | 316 | ||
317 | - llOutOptionalTlv = new LinkedList<PcepValueType>(); | 317 | + llOutOptionalTlv = new LinkedList<>(); |
318 | 318 | ||
319 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { | 319 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { |
320 | 320 | ... | ... |
... | @@ -290,7 +290,7 @@ public class PcepLspaObjectVer1 implements PcepLspaObject { | ... | @@ -290,7 +290,7 @@ public class PcepLspaObjectVer1 implements PcepLspaObject { |
290 | */ | 290 | */ |
291 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { | 291 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { |
292 | 292 | ||
293 | - LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<PcepValueType>(); | 293 | + LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<>(); |
294 | 294 | ||
295 | return llOutOptionalTlv; | 295 | return llOutOptionalTlv; |
296 | } | 296 | } | ... | ... |
... | @@ -213,7 +213,7 @@ public class PcepOpenObjectVer1 implements PcepOpenObject { | ... | @@ -213,7 +213,7 @@ public class PcepOpenObjectVer1 implements PcepOpenObject { |
213 | 213 | ||
214 | LinkedList<PcepValueType> llOptionalTlv; | 214 | LinkedList<PcepValueType> llOptionalTlv; |
215 | 215 | ||
216 | - llOptionalTlv = new LinkedList<PcepValueType>(); | 216 | + llOptionalTlv = new LinkedList<>(); |
217 | 217 | ||
218 | while (4 <= cb.readableBytes()) { | 218 | while (4 <= cb.readableBytes()) { |
219 | PcepValueType tlv; | 219 | PcepValueType tlv; |
... | @@ -360,7 +360,7 @@ public class PcepOpenObjectVer1 implements PcepOpenObject { | ... | @@ -360,7 +360,7 @@ public class PcepOpenObjectVer1 implements PcepOpenObject { |
360 | private boolean bIsSessionIDSet = false; | 360 | private boolean bIsSessionIDSet = false; |
361 | private byte sessionID; | 361 | private byte sessionID; |
362 | private boolean bIsOptionalTlvSet = false; | 362 | private boolean bIsOptionalTlvSet = false; |
363 | - private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 363 | + private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
364 | 364 | ||
365 | private boolean bIsPFlagSet = false; | 365 | private boolean bIsPFlagSet = false; |
366 | private boolean bPFlag; | 366 | private boolean bPFlag; | ... | ... |
... | @@ -189,7 +189,7 @@ public class PcepRPObjectVer1 implements PcepRPObject { | ... | @@ -189,7 +189,7 @@ public class PcepRPObjectVer1 implements PcepRPObject { |
189 | boolean bBFlag; | 189 | boolean bBFlag; |
190 | boolean bRFlag; | 190 | boolean bRFlag; |
191 | byte yPriFlag; // 3bytes | 191 | byte yPriFlag; // 3bytes |
192 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 192 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
193 | 193 | ||
194 | rpObjHeader = PcepObjectHeader.read(cb); | 194 | rpObjHeader = PcepObjectHeader.read(cb); |
195 | 195 | ||
... | @@ -253,7 +253,7 @@ public class PcepRPObjectVer1 implements PcepRPObject { | ... | @@ -253,7 +253,7 @@ public class PcepRPObjectVer1 implements PcepRPObject { |
253 | */ | 253 | */ |
254 | protected static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { | 254 | protected static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { |
255 | 255 | ||
256 | - LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<PcepValueType>(); | 256 | + LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<>(); |
257 | //Currently no optional TLvs, will be added based on requirements. | 257 | //Currently no optional TLvs, will be added based on requirements. |
258 | return llOutOptionalTlv; | 258 | return llOutOptionalTlv; |
259 | } | 259 | } |
... | @@ -292,7 +292,7 @@ public class PcepRPObjectVer1 implements PcepRPObject { | ... | @@ -292,7 +292,7 @@ public class PcepRPObjectVer1 implements PcepRPObject { |
292 | private boolean bBFlag; | 292 | private boolean bBFlag; |
293 | private boolean bRFlag; | 293 | private boolean bRFlag; |
294 | private byte yPriFlag; | 294 | private byte yPriFlag; |
295 | - private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 295 | + private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
296 | 296 | ||
297 | private boolean bIsPFlagSet = false; | 297 | private boolean bIsPFlagSet = false; |
298 | private boolean bPFlag; | 298 | private boolean bPFlag; | ... | ... |
... | @@ -88,7 +88,7 @@ class PcepReportMsgVer1 implements PcepReportMsg { | ... | @@ -88,7 +88,7 @@ class PcepReportMsgVer1 implements PcepReportMsg { |
88 | throw new PcepParseException("Received packet size " + cb.readableBytes() | 88 | throw new PcepParseException("Received packet size " + cb.readableBytes() |
89 | + " is less than the expected size: " + PACKET_MINIMUM_LENGTH); | 89 | + " is less than the expected size: " + PACKET_MINIMUM_LENGTH); |
90 | } | 90 | } |
91 | - llStateReportList = new LinkedList<PcepStateReport>(); | 91 | + llStateReportList = new LinkedList<>(); |
92 | byte version = cb.readByte(); | 92 | byte version = cb.readByte(); |
93 | version = (byte) (version >> PcepMessageVer1.SHIFT_FLAG); | 93 | version = (byte) (version >> PcepMessageVer1.SHIFT_FLAG); |
94 | 94 | ... | ... |
... | @@ -111,7 +111,7 @@ public class PcepRroObjectVer1 implements PcepRroObject { | ... | @@ -111,7 +111,7 @@ public class PcepRroObjectVer1 implements PcepRroObject { |
111 | private byte prefixLength; | 111 | private byte prefixLength; |
112 | private byte resvd; | 112 | private byte resvd; |
113 | PcepObjectHeader rroObjHeader; | 113 | PcepObjectHeader rroObjHeader; |
114 | - private LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 114 | + private LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
115 | 115 | ||
116 | /** | 116 | /** |
117 | * Reset variables. | 117 | * Reset variables. |
... | @@ -190,7 +190,7 @@ public class PcepRroObjectVer1 implements PcepRroObject { | ... | @@ -190,7 +190,7 @@ public class PcepRroObjectVer1 implements PcepRroObject { |
190 | */ | 190 | */ |
191 | protected static LinkedList<PcepValueType> parseSubObjects(ChannelBuffer cb) throws PcepParseException { | 191 | protected static LinkedList<PcepValueType> parseSubObjects(ChannelBuffer cb) throws PcepParseException { |
192 | 192 | ||
193 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 193 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
194 | 194 | ||
195 | while (0 < cb.readableBytes()) { | 195 | while (0 < cb.readableBytes()) { |
196 | 196 | ||
... | @@ -275,7 +275,7 @@ public class PcepRroObjectVer1 implements PcepRroObject { | ... | @@ -275,7 +275,7 @@ public class PcepRroObjectVer1 implements PcepRroObject { |
275 | private boolean bIsHeaderSet = false; | 275 | private boolean bIsHeaderSet = false; |
276 | 276 | ||
277 | private PcepObjectHeader rroObjHeader; | 277 | private PcepObjectHeader rroObjHeader; |
278 | - LinkedList<PcepValueType> llSubObjects = new LinkedList<PcepValueType>(); | 278 | + LinkedList<PcepValueType> llSubObjects = new LinkedList<>(); |
279 | 279 | ||
280 | private boolean bIsPFlagSet = false; | 280 | private boolean bIsPFlagSet = false; |
281 | private boolean bPFlag; | 281 | private boolean bPFlag; | ... | ... |
... | @@ -155,7 +155,7 @@ public class PcepSrpObjectVer1 implements PcepSrpObject { | ... | @@ -155,7 +155,7 @@ public class PcepSrpObjectVer1 implements PcepSrpObject { |
155 | 155 | ||
156 | int srpID; | 156 | int srpID; |
157 | int flags; | 157 | int flags; |
158 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 158 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
159 | 159 | ||
160 | srpObjHeader = PcepObjectHeader.read(cb); | 160 | srpObjHeader = PcepObjectHeader.read(cb); |
161 | 161 | ||
... | @@ -212,7 +212,7 @@ public class PcepSrpObjectVer1 implements PcepSrpObject { | ... | @@ -212,7 +212,7 @@ public class PcepSrpObjectVer1 implements PcepSrpObject { |
212 | */ | 212 | */ |
213 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { | 213 | public static LinkedList<PcepValueType> parseOptionalTlv(ChannelBuffer cb) throws PcepParseException { |
214 | 214 | ||
215 | - LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<PcepValueType>(); | 215 | + LinkedList<PcepValueType> llOutOptionalTlv = new LinkedList<>(); |
216 | 216 | ||
217 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { | 217 | while (MINIMUM_COMMON_HEADER_LENGTH <= cb.readableBytes()) { |
218 | 218 | ||
... | @@ -289,7 +289,7 @@ public class PcepSrpObjectVer1 implements PcepSrpObject { | ... | @@ -289,7 +289,7 @@ public class PcepSrpObjectVer1 implements PcepSrpObject { |
289 | private PcepObjectHeader srpObjHeader; | 289 | private PcepObjectHeader srpObjHeader; |
290 | private int srpId; | 290 | private int srpId; |
291 | private boolean bRFlag; | 291 | private boolean bRFlag; |
292 | - LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 292 | + LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
293 | 293 | ||
294 | private boolean bIsPFlagSet = false; | 294 | private boolean bIsPFlagSet = false; |
295 | private boolean bPFlag; | 295 | private boolean bPFlag; | ... | ... |
... | @@ -277,7 +277,7 @@ public class PcepTEObjectVer1 implements PcepTEObject { | ... | @@ -277,7 +277,7 @@ public class PcepTEObjectVer1 implements PcepTEObject { |
277 | 277 | ||
278 | LinkedList<PcepValueType> llOutOptionalTlv; | 278 | LinkedList<PcepValueType> llOutOptionalTlv; |
279 | 279 | ||
280 | - llOutOptionalTlv = new LinkedList<PcepValueType>(); | 280 | + llOutOptionalTlv = new LinkedList<>(); |
281 | 281 | ||
282 | while (MINIMUM_TLV_HEADER_LENGTH <= cb.readableBytes()) { | 282 | while (MINIMUM_TLV_HEADER_LENGTH <= cb.readableBytes()) { |
283 | 283 | ||
... | @@ -377,7 +377,7 @@ public class PcepTEObjectVer1 implements PcepTEObject { | ... | @@ -377,7 +377,7 @@ public class PcepTEObjectVer1 implements PcepTEObject { |
377 | private boolean bRFlag; | 377 | private boolean bRFlag; |
378 | private boolean bSFlag; | 378 | private boolean bSFlag; |
379 | private int iTEId; | 379 | private int iTEId; |
380 | - private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<PcepValueType>(); | 380 | + private LinkedList<PcepValueType> llOptionalTlv = new LinkedList<>(); |
381 | 381 | ||
382 | private boolean bIsPFlagSet = false; | 382 | private boolean bIsPFlagSet = false; |
383 | private boolean bPFlag; | 383 | private boolean bPFlag; | ... | ... |
... | @@ -69,7 +69,7 @@ class PcepTEReportMsgVer1 implements PcepTEReportMsg { | ... | @@ -69,7 +69,7 @@ class PcepTEReportMsgVer1 implements PcepTEReportMsg { |
69 | return null; | 69 | return null; |
70 | } | 70 | } |
71 | 71 | ||
72 | - teReportList = new LinkedList<PcepTEObject>(); | 72 | + teReportList = new LinkedList<>(); |
73 | 73 | ||
74 | byte version = cb.readByte(); | 74 | byte version = cb.readByte(); |
75 | version = (byte) (version >> PcepMessageVer1.SHIFT_FLAG); | 75 | version = (byte) (version >> PcepMessageVer1.SHIFT_FLAG); | ... | ... |
... | @@ -100,7 +100,7 @@ class PcepUpdateMsgVer1 implements PcepUpdateMsg { | ... | @@ -100,7 +100,7 @@ class PcepUpdateMsgVer1 implements PcepUpdateMsg { |
100 | throw new PcepParseException("Readable bytes is less than update message minimum length"); | 100 | throw new PcepParseException("Readable bytes is less than update message minimum length"); |
101 | } | 101 | } |
102 | 102 | ||
103 | - llUpdateRequestList = new LinkedList<PcepUpdateRequest>(); | 103 | + llUpdateRequestList = new LinkedList<>(); |
104 | 104 | ||
105 | // fixed value property version == 1 | 105 | // fixed value property version == 1 |
106 | byte version = cb.readByte(); | 106 | byte version = cb.readByte(); | ... | ... |
... | @@ -57,7 +57,7 @@ public class ErrorObjListWithOpen { | ... | @@ -57,7 +57,7 @@ public class ErrorObjListWithOpen { |
57 | * @return error types list | 57 | * @return error types list |
58 | */ | 58 | */ |
59 | public LinkedList<Integer> getErrorType() { | 59 | public LinkedList<Integer> getErrorType() { |
60 | - LinkedList<Integer> errorType = new LinkedList<Integer>(); | 60 | + LinkedList<Integer> errorType = new LinkedList<>(); |
61 | if (llerrorObjList != null) { | 61 | if (llerrorObjList != null) { |
62 | ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator(); | 62 | ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator(); |
63 | int error; | 63 | int error; |
... | @@ -77,7 +77,7 @@ public class ErrorObjListWithOpen { | ... | @@ -77,7 +77,7 @@ public class ErrorObjListWithOpen { |
77 | * @return error values list | 77 | * @return error values list |
78 | */ | 78 | */ |
79 | public LinkedList<Integer> getErrorValue() { | 79 | public LinkedList<Integer> getErrorValue() { |
80 | - LinkedList<Integer> errorValue = new LinkedList<Integer>(); | 80 | + LinkedList<Integer> errorValue = new LinkedList<>(); |
81 | if (llerrorObjList != null) { | 81 | if (llerrorObjList != null) { |
82 | ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator(); | 82 | ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator(); |
83 | int error; | 83 | int error; | ... | ... |
... | @@ -184,7 +184,7 @@ public class LocalTENodeDescriptorsTlv implements PcepValueType { | ... | @@ -184,7 +184,7 @@ public class LocalTENodeDescriptorsTlv implements PcepValueType { |
184 | public static PcepValueType read(ChannelBuffer c, short hLength) throws PcepParseException { | 184 | public static PcepValueType read(ChannelBuffer c, short hLength) throws PcepParseException { |
185 | 185 | ||
186 | // Node Descriptor Sub-TLVs (variable) | 186 | // Node Descriptor Sub-TLVs (variable) |
187 | - LinkedList<PcepValueType> llNodeDescriptorSubTLVs = new LinkedList<PcepValueType>(); | 187 | + LinkedList<PcepValueType> llNodeDescriptorSubTLVs = new LinkedList<>(); |
188 | 188 | ||
189 | ChannelBuffer tempCb = c.readBytes(hLength); | 189 | ChannelBuffer tempCb = c.readBytes(hLength); |
190 | 190 | ... | ... |
... | @@ -162,7 +162,7 @@ public class PcepRsvpUserErrorSpec implements PcepRsvpErrorSpec { | ... | @@ -162,7 +162,7 @@ public class PcepRsvpUserErrorSpec implements PcepRsvpErrorSpec { |
162 | } | 162 | } |
163 | 163 | ||
164 | private static LinkedList<PcepValueType> parseErrSpecSubObj(ChannelBuffer cb) throws PcepParseException { | 164 | private static LinkedList<PcepValueType> parseErrSpecSubObj(ChannelBuffer cb) throws PcepParseException { |
165 | - LinkedList<PcepValueType> llRsvpUserSpecSubObj = new LinkedList<PcepValueType>(); | 165 | + LinkedList<PcepValueType> llRsvpUserSpecSubObj = new LinkedList<>(); |
166 | while (0 < cb.readableBytes()) { | 166 | while (0 < cb.readableBytes()) { |
167 | PcepValueType tlv = null; | 167 | PcepValueType tlv = null; |
168 | short hType = cb.readShort(); | 168 | short hType = cb.readShort(); | ... | ... |
... | @@ -187,7 +187,7 @@ public class RemoteTENodeDescriptorsTlv implements PcepValueType { | ... | @@ -187,7 +187,7 @@ public class RemoteTENodeDescriptorsTlv implements PcepValueType { |
187 | public static PcepValueType read(ChannelBuffer c , short length) throws PcepParseException { | 187 | public static PcepValueType read(ChannelBuffer c , short length) throws PcepParseException { |
188 | 188 | ||
189 | // Node Descriptor Sub-TLVs (variable) | 189 | // Node Descriptor Sub-TLVs (variable) |
190 | - LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLVs = new LinkedList<PcepValueType>(); | 190 | + LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLVs = new LinkedList<>(); |
191 | 191 | ||
192 | ChannelBuffer tempCb = c.readBytes(length); | 192 | ChannelBuffer tempCb = c.readBytes(length); |
193 | 193 | ... | ... |
... | @@ -186,7 +186,7 @@ public class TELinkAttributesTlv implements PcepValueType { | ... | @@ -186,7 +186,7 @@ public class TELinkAttributesTlv implements PcepValueType { |
186 | public static PcepValueType read(ChannelBuffer c, short hLength) throws PcepParseException { | 186 | public static PcepValueType read(ChannelBuffer c, short hLength) throws PcepParseException { |
187 | 187 | ||
188 | // Node Descriptor Sub-TLVs (variable) | 188 | // Node Descriptor Sub-TLVs (variable) |
189 | - LinkedList<PcepValueType> llLinkAttributesSubTLVs = new LinkedList<PcepValueType>(); | 189 | + LinkedList<PcepValueType> llLinkAttributesSubTLVs = new LinkedList<>(); |
190 | 190 | ||
191 | ChannelBuffer tempCb = c.readBytes(hLength); | 191 | ChannelBuffer tempCb = c.readBytes(hLength); |
192 | 192 | ... | ... |
... | @@ -183,7 +183,7 @@ public class TELinkDescriptorsTlv implements PcepValueType { | ... | @@ -183,7 +183,7 @@ public class TELinkDescriptorsTlv implements PcepValueType { |
183 | public static PcepValueType read(ChannelBuffer c, short length) throws PcepParseException { | 183 | public static PcepValueType read(ChannelBuffer c, short length) throws PcepParseException { |
184 | 184 | ||
185 | // Node Descriptor Sub-TLVs (variable) | 185 | // Node Descriptor Sub-TLVs (variable) |
186 | - LinkedList<PcepValueType> llLinkDescriptorsSubTLVs = new LinkedList<PcepValueType>(); | 186 | + LinkedList<PcepValueType> llLinkDescriptorsSubTLVs = new LinkedList<>(); |
187 | 187 | ||
188 | ChannelBuffer tempCb = c.readBytes(length); | 188 | ChannelBuffer tempCb = c.readBytes(length); |
189 | 189 | ... | ... |
... | @@ -183,7 +183,7 @@ public class TENodeAttributesTlv implements PcepValueType { | ... | @@ -183,7 +183,7 @@ public class TENodeAttributesTlv implements PcepValueType { |
183 | public static PcepValueType read(ChannelBuffer c, short hLength) throws PcepParseException { | 183 | public static PcepValueType read(ChannelBuffer c, short hLength) throws PcepParseException { |
184 | 184 | ||
185 | // Node Descriptor Sub-TLVs (variable) | 185 | // Node Descriptor Sub-TLVs (variable) |
186 | - LinkedList<PcepValueType> llNodeAttributesSubTLVs = new LinkedList<PcepValueType>(); | 186 | + LinkedList<PcepValueType> llNodeAttributesSubTLVs = new LinkedList<>(); |
187 | 187 | ||
188 | ChannelBuffer tempCb = c.readBytes(hLength); | 188 | ChannelBuffer tempCb = c.readBytes(hLength); |
189 | 189 | ... | ... |
... | @@ -36,11 +36,11 @@ public class RemoteTENodeDescriptorsTlvTest { | ... | @@ -36,11 +36,11 @@ public class RemoteTENodeDescriptorsTlvTest { |
36 | private final AutonomousSystemTlv autonomousSystemTlv2 = new AutonomousSystemTlv(20); | 36 | private final AutonomousSystemTlv autonomousSystemTlv2 = new AutonomousSystemTlv(20); |
37 | private final BGPLSidentifierTlv bGPLSidentifierTlv2 = new BGPLSidentifierTlv(30); | 37 | private final BGPLSidentifierTlv bGPLSidentifierTlv2 = new BGPLSidentifierTlv(30); |
38 | 38 | ||
39 | - private final LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLV1 = new LinkedList<PcepValueType>(); | 39 | + private final LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLV1 = new LinkedList<>(); |
40 | private final boolean a = llRemoteTENodeDescriptorSubTLV1.add(autonomousSystemTlv1); | 40 | private final boolean a = llRemoteTENodeDescriptorSubTLV1.add(autonomousSystemTlv1); |
41 | private final boolean b = llRemoteTENodeDescriptorSubTLV1.add(bGPLSidentifierTlv1); | 41 | private final boolean b = llRemoteTENodeDescriptorSubTLV1.add(bGPLSidentifierTlv1); |
42 | 42 | ||
43 | - private final LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLV2 = new LinkedList<PcepValueType>(); | 43 | + private final LinkedList<PcepValueType> llRemoteTENodeDescriptorSubTLV2 = new LinkedList<>(); |
44 | private final boolean c = llRemoteTENodeDescriptorSubTLV2.add(autonomousSystemTlv2); | 44 | private final boolean c = llRemoteTENodeDescriptorSubTLV2.add(autonomousSystemTlv2); |
45 | private final boolean d = llRemoteTENodeDescriptorSubTLV2.add(bGPLSidentifierTlv2); | 45 | private final boolean d = llRemoteTENodeDescriptorSubTLV2.add(bGPLSidentifierTlv2); |
46 | 46 | ... | ... |
... | @@ -38,11 +38,11 @@ public class TELinkAttributesTlvTest { | ... | @@ -38,11 +38,11 @@ public class TELinkAttributesTlvTest { |
38 | private final MaximumReservableLinkBandwidthTlv maximumReservableLinkBandwidthTlv2 = | 38 | private final MaximumReservableLinkBandwidthTlv maximumReservableLinkBandwidthTlv2 = |
39 | new MaximumReservableLinkBandwidthTlv(30); | 39 | new MaximumReservableLinkBandwidthTlv(30); |
40 | 40 | ||
41 | - private final LinkedList<PcepValueType> llLinkAttributesSubTLV1 = new LinkedList<PcepValueType>(); | 41 | + private final LinkedList<PcepValueType> llLinkAttributesSubTLV1 = new LinkedList<>(); |
42 | private final boolean a = llLinkAttributesSubTLV1.add(administrativeGroupTlv1); | 42 | private final boolean a = llLinkAttributesSubTLV1.add(administrativeGroupTlv1); |
43 | private final boolean b = llLinkAttributesSubTLV1.add(maximumReservableLinkBandwidthTlv1); | 43 | private final boolean b = llLinkAttributesSubTLV1.add(maximumReservableLinkBandwidthTlv1); |
44 | 44 | ||
45 | - private final LinkedList<PcepValueType> llLinkAttributesSubTLV2 = new LinkedList<PcepValueType>(); | 45 | + private final LinkedList<PcepValueType> llLinkAttributesSubTLV2 = new LinkedList<>(); |
46 | 46 | ||
47 | private final boolean c = llLinkAttributesSubTLV2.add(administrativeGroupTlv2); | 47 | private final boolean c = llLinkAttributesSubTLV2.add(administrativeGroupTlv2); |
48 | private final boolean d = llLinkAttributesSubTLV2.add(maximumReservableLinkBandwidthTlv2); | 48 | private final boolean d = llLinkAttributesSubTLV2.add(maximumReservableLinkBandwidthTlv2); | ... | ... |
... | @@ -37,11 +37,11 @@ public class TELinkDescriptorsTlvTest { | ... | @@ -37,11 +37,11 @@ public class TELinkDescriptorsTlvTest { |
37 | LinkLocalRemoteIdentifiersTlv(20, 20); | 37 | LinkLocalRemoteIdentifiersTlv(20, 20); |
38 | private final IPv4InterfaceAddressTlv iPv4InterfaceAddressTlv2 = new IPv4InterfaceAddressTlv(0x02020202); | 38 | private final IPv4InterfaceAddressTlv iPv4InterfaceAddressTlv2 = new IPv4InterfaceAddressTlv(0x02020202); |
39 | 39 | ||
40 | - private final LinkedList<PcepValueType> llLinkDescriptorsSubTLVs1 = new LinkedList<PcepValueType>(); | 40 | + private final LinkedList<PcepValueType> llLinkDescriptorsSubTLVs1 = new LinkedList<>(); |
41 | private final boolean a = llLinkDescriptorsSubTLVs1.add(linkLocalRemoteIdentifiersTlv1); | 41 | private final boolean a = llLinkDescriptorsSubTLVs1.add(linkLocalRemoteIdentifiersTlv1); |
42 | private final boolean b = llLinkDescriptorsSubTLVs1.add(iPv4InterfaceAddressTlv1); | 42 | private final boolean b = llLinkDescriptorsSubTLVs1.add(iPv4InterfaceAddressTlv1); |
43 | 43 | ||
44 | - private final LinkedList<PcepValueType> llLinkDescriptorsSubTLVs2 = new LinkedList<PcepValueType>(); | 44 | + private final LinkedList<PcepValueType> llLinkDescriptorsSubTLVs2 = new LinkedList<>(); |
45 | private final boolean c = llLinkDescriptorsSubTLVs2.add(linkLocalRemoteIdentifiersTlv2); | 45 | private final boolean c = llLinkDescriptorsSubTLVs2.add(linkLocalRemoteIdentifiersTlv2); |
46 | private final boolean d = llLinkDescriptorsSubTLVs2.add(iPv4InterfaceAddressTlv2); | 46 | private final boolean d = llLinkDescriptorsSubTLVs2.add(iPv4InterfaceAddressTlv2); |
47 | 47 | ... | ... |
... | @@ -38,11 +38,11 @@ public class TENodeAttributesTlvTest { | ... | @@ -38,11 +38,11 @@ public class TENodeAttributesTlvTest { |
38 | private final IPv4TERouterIdOfLocalNodeTlv iPv4TERouterIdOfLocalNodeTlv2 = new | 38 | private final IPv4TERouterIdOfLocalNodeTlv iPv4TERouterIdOfLocalNodeTlv2 = new |
39 | IPv4TERouterIdOfLocalNodeTlv(0x02020202); | 39 | IPv4TERouterIdOfLocalNodeTlv(0x02020202); |
40 | 40 | ||
41 | - private final LinkedList<PcepValueType> llNodeAttributesSubTLV1 = new LinkedList<PcepValueType>(); | 41 | + private final LinkedList<PcepValueType> llNodeAttributesSubTLV1 = new LinkedList<>(); |
42 | private final boolean a = llNodeAttributesSubTLV1.add(nodeFlagBitsTlv1); | 42 | private final boolean a = llNodeAttributesSubTLV1.add(nodeFlagBitsTlv1); |
43 | private final boolean b = llNodeAttributesSubTLV1.add(iPv4TERouterIdOfLocalNodeTlv1); | 43 | private final boolean b = llNodeAttributesSubTLV1.add(iPv4TERouterIdOfLocalNodeTlv1); |
44 | 44 | ||
45 | - private final LinkedList<PcepValueType> llNodeAttributesSubTLV2 = new LinkedList<PcepValueType>(); | 45 | + private final LinkedList<PcepValueType> llNodeAttributesSubTLV2 = new LinkedList<>(); |
46 | 46 | ||
47 | private final boolean c = llNodeAttributesSubTLV2.add(nodeFlagBitsTlv2); | 47 | private final boolean c = llNodeAttributesSubTLV2.add(nodeFlagBitsTlv2); |
48 | private final boolean d = llNodeAttributesSubTLV2.add(iPv4TERouterIdOfLocalNodeTlv2); | 48 | private final boolean d = llNodeAttributesSubTLV2.add(iPv4TERouterIdOfLocalNodeTlv2); | ... | ... |
-
Please register or login to post a comment