Committed by
Gerrit Code Review
Remove unnecessary boxing
Change-Id: I78bfbcaf061348172b53bc2ce5c27ff19c1202d2
Showing
3 changed files
with
4 additions
and
6 deletions
... | @@ -188,9 +188,7 @@ public class TunnelCreateCommand extends AbstractShellCommand { | ... | @@ -188,9 +188,7 @@ public class TunnelCreateCommand extends AbstractShellCommand { |
188 | srcPoint, | 188 | srcPoint, |
189 | dstPoint, | 189 | dstPoint, |
190 | trueType, | 190 | trueType, |
191 | - new DefaultGroupId( | 191 | + new DefaultGroupId(Integer.parseInt(groupId)), |
192 | - Integer.valueOf(groupId) | ||
193 | - .intValue()), | ||
194 | producerName, | 192 | producerName, |
195 | TunnelName | 193 | TunnelName |
196 | .tunnelName(tunnelName), | 194 | .tunnelName(tunnelName), | ... | ... |
... | @@ -64,14 +64,14 @@ public final class OpticalPortOperator implements ConfigOperator { | ... | @@ -64,14 +64,14 @@ public final class OpticalPortOperator implements ConfigOperator { |
64 | if (port == null) { | 64 | if (port == null) { |
65 | // try to get the portNumber from the numName. | 65 | // try to get the portNumber from the numName. |
66 | if (!numName.isEmpty()) { | 66 | if (!numName.isEmpty()) { |
67 | - final long pn = Long.valueOf(numName); | 67 | + final long pn = Long.parseLong(numName); |
68 | newPort = (!name.isEmpty()) ? PortNumber.portNumber(pn, name) : PortNumber.portNumber(pn); | 68 | newPort = (!name.isEmpty()) ? PortNumber.portNumber(pn, name) : PortNumber.portNumber(pn); |
69 | } else { | 69 | } else { |
70 | // we don't have defining info (a port number value) | 70 | // we don't have defining info (a port number value) |
71 | throw new RuntimeException("Possible misconfig, bailing on handling for: \n\t" + descr); | 71 | throw new RuntimeException("Possible misconfig, bailing on handling for: \n\t" + descr); |
72 | } | 72 | } |
73 | } else if ((!name.isEmpty()) && !name.equals(port.name())) { | 73 | } else if ((!name.isEmpty()) && !name.equals(port.name())) { |
74 | - final long pn = (numName.isEmpty()) ? port.toLong() : Long.valueOf(numName); | 74 | + final long pn = (numName.isEmpty()) ? port.toLong() : Long.parseLong(numName); |
75 | newPort = PortNumber.portNumber(pn, name); | 75 | newPort = PortNumber.portNumber(pn, name); |
76 | } | 76 | } |
77 | 77 | ... | ... |
... | @@ -127,7 +127,7 @@ public class OpticalConnectivityIntentCompiler implements IntentCompiler<Optical | ... | @@ -127,7 +127,7 @@ public class OpticalConnectivityIntentCompiler implements IntentCompiler<Optical |
127 | 127 | ||
128 | // FIXME: need to actually reserve the lambda for static lambda's | 128 | // FIXME: need to actually reserve the lambda for static lambda's |
129 | if (staticLambda != null) { | 129 | if (staticLambda != null) { |
130 | - ochSignal = new OchSignal(Frequency.ofHz(Long.valueOf(staticLambda)), | 130 | + ochSignal = new OchSignal(Frequency.ofHz(Long.parseLong(staticLambda)), |
131 | srcOchPort.lambda().channelSpacing(), | 131 | srcOchPort.lambda().channelSpacing(), |
132 | srcOchPort.lambda().slotGranularity()); | 132 | srcOchPort.lambda().slotGranularity()); |
133 | } else if (!srcOchPort.isTunable() || !dstOchPort.isTunable()) { | 133 | } else if (!srcOchPort.isTunable() || !dstOchPort.isTunable()) { | ... | ... |
-
Please register or login to post a comment