summaryrefslogtreecommitdiffstats
path: root/misc/env/src/main/java/org
diff options
context:
space:
mode:
Diffstat (limited to 'misc/env/src/main/java/org')
-rw-r--r--misc/env/src/main/java/org/onap/aaf/misc/env/LogTarget.java30
-rw-r--r--misc/env/src/main/java/org/onap/aaf/misc/env/TimeTaken.java2
-rw-r--r--misc/env/src/main/java/org/onap/aaf/misc/env/impl/AbsTrans.java12
3 files changed, 22 insertions, 22 deletions
diff --git a/misc/env/src/main/java/org/onap/aaf/misc/env/LogTarget.java b/misc/env/src/main/java/org/onap/aaf/misc/env/LogTarget.java
index 84eb5ee6..a98d7100 100644
--- a/misc/env/src/main/java/org/onap/aaf/misc/env/LogTarget.java
+++ b/misc/env/src/main/java/org/onap/aaf/misc/env/LogTarget.java
@@ -69,18 +69,18 @@ public interface LogTarget {
public static final LogTarget SYSERR = new StreamLogTarget(System.err,false);
public static class StreamLogTarget implements LogTarget {
- private final PrintStream out;
- private final boolean closeMe;
-
- public StreamLogTarget(PrintStream ps) {
- this(ps,true);
- }
-
- /* Do NOT close SYSTEM ERR or OUT*/
- protected StreamLogTarget(PrintStream ps, boolean shouldClose) {
- out = ps;
- closeMe = shouldClose;
- }
+ private final PrintStream out;
+ private final boolean closeMe;
+
+ public StreamLogTarget(PrintStream ps) {
+ this(ps,true);
+ }
+
+ /* Do NOT close SYSTEM ERR or OUT*/
+ protected StreamLogTarget(PrintStream ps, boolean shouldClose) {
+ out = ps;
+ closeMe = shouldClose;
+ }
public void log(Object ... msgs) {
out.print(Chrono.dateFmt.format(new Date()));
out.print(": ");
@@ -117,9 +117,9 @@ public interface LogTarget {
}
public void close() {
- if(closeMe) {
- out.close();
- }
+ if(closeMe) {
+ out.close();
+ }
}
}
diff --git a/misc/env/src/main/java/org/onap/aaf/misc/env/TimeTaken.java b/misc/env/src/main/java/org/onap/aaf/misc/env/TimeTaken.java
index 58c588f6..2491e16c 100644
--- a/misc/env/src/main/java/org/onap/aaf/misc/env/TimeTaken.java
+++ b/misc/env/src/main/java/org/onap/aaf/misc/env/TimeTaken.java
@@ -78,7 +78,7 @@ public abstract class TimeTaken {
}
- /**
+ /**
* For sizable contents, set the size. Implementations can simply write a no-op if they don't wish to
* store the size.
*
diff --git a/misc/env/src/main/java/org/onap/aaf/misc/env/impl/AbsTrans.java b/misc/env/src/main/java/org/onap/aaf/misc/env/impl/AbsTrans.java
index 5ba74369..9edd3bf4 100644
--- a/misc/env/src/main/java/org/onap/aaf/misc/env/impl/AbsTrans.java
+++ b/misc/env/src/main/java/org/onap/aaf/misc/env/impl/AbsTrans.java
@@ -131,11 +131,11 @@ public abstract class AbsTrans<ENV extends Env> implements TransStore {
//long end = (first.flag&SUB)==SUB?first.end():trail.get(last).end();
long end = 0L;
for(int i=last;end==0L && i>=0;--i) {
- end= trail.get(i).end();
+ end= trail.get(i).end();
}
metric.total = (end - first.start) / 1000000f;
} else {
- metric.total=0L;
+ metric.total=0L;
}
if (sb==null) {
@@ -170,14 +170,14 @@ public abstract class AbsTrans<ENV extends Env> implements TransStore {
sb.append(" ");
}
if((tt.flag & CHECKPOINT)==CHECKPOINT) {
- // Checkpoint
- sb.append(" ");
+ // Checkpoint
+ sb.append(" ");
} else {
- float ms=tt.millis();
+ float ms=tt.millis();
// Add time values to Metric
for (int i=0;i<flags.length;++i) {
if ((tt.flag & flags[i]) == flags[i]) {
- metric.buckets[i]+=ms;
+ metric.buckets[i]+=ms;
}
}
}