Code Review
/
aaf
/
authz.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Refine Props, Batch Extend
[aaf/authz.git]
/
auth
/
auth-batch
/
src
/
main
/
java
/
org
/
onap
/
aaf
/
auth
/
batch
/
helpers
/
Cred.java
diff --git
a/auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
b/auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
index
979cdf0
..
c4a9b0d
100644
(file)
--- a/
auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
+++ b/
auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
@@
-138,13
+138,14
@@
public class Cred {
row = iter.next();
int type = row.getInt(1);
if (types.length>0) { // filter by types, if requested
row = iter.next();
int type = row.getInt(1);
if (types.length>0) { // filter by types, if requested
- boolean
quit = tru
e;
+ boolean
hastype = fals
e;
for (int t : types) {
if (t==type) {
for (int t : types) {
if (t==type) {
+ hastype=true;
break;
}
}
break;
}
}
- if (
quit
) {
+ if (
!hastype
) {
continue;
}
}
continue;
}
}
@@
-280,7
+281,7
@@
public class Cred {
}
}
- public static void
row
(StringBuilder sb, List<String> row) {
+ public static void
batchDelete
(StringBuilder sb, List<String> row) {
sb.append("DELETE from authz.cred WHERE id='");
sb.append(row.get(1));
sb.append("' AND type=");
sb.append("DELETE from authz.cred WHERE id='");
sb.append(row.get(1));
sb.append("' AND type=");
@@
-291,7
+292,6
@@
public class Cred {
sb.append("));\n");
}
sb.append("));\n");
}
-
public String toString() {
StringBuilder sb = new StringBuilder(id);
sb.append('[');
public String toString() {
StringBuilder sb = new StringBuilder(id);
sb.append('[');
@@
-322,4
+322,14
@@
public class Cred {
return id.equals(obj);
}
return id.equals(obj);
}
+
+ public static String histSubject(List<String> row) {
+ return row.get(1);
+ }
+
+
+ public static String histMemo(String fmt, String orgName, List<String> row) {
+ return String.format(fmt, row.get(1),orgName,row.get(4));
+ }
+
}
\ No newline at end of file
}
\ No newline at end of file