Messaging: Language cleanup
No unnecessary boxing, enhanced for loops, redundant checks and throws, imports (removal, reordering), possible void returns Change-Id: I7a8e1b2007e3b0906e01b41785c518d02c2f3fab
This commit is contained in:
@@ -153,9 +153,9 @@ public class Base64 {
|
||||
byte[] groomedData = new byte[data.length];
|
||||
int bytesCopied = 0;
|
||||
|
||||
for (int i = 0; i < data.length; i++) {
|
||||
if (isBase64(data[i])) {
|
||||
groomedData[bytesCopied++] = data[i];
|
||||
for (byte datum : data) {
|
||||
if (isBase64(datum)) {
|
||||
groomedData[bytesCopied++] = datum;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -628,8 +628,8 @@ public class PduHeaders {
|
||||
}
|
||||
|
||||
ArrayList<EncodedStringValue> list = new ArrayList<>();
|
||||
for (int i = 0; i < value.length; i++) {
|
||||
list.add(value[i]);
|
||||
for (EncodedStringValue encodedStringValue : value) {
|
||||
list.add(encodedStringValue);
|
||||
}
|
||||
mHeaderMap.put(field, list);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user