Advertisement
Guest User

Untitled

a guest
Oct 27th, 2016
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. final AtomicLong ts1 = new AtomicLong(1466503200L);
  2. final AtomicLong ts2 = new AtomicLong(1466593200L);
  3. final AtomicInteger count = new AtomicInteger(1);
  4.  
  5. final Supplier<HashMap<String, Object>> data2 = () -> new HashMap<String, Object>() {{
  6. put("DATETIME", count.get() % 10 == 0 ? ts2.get() : ts1.get());
  7. put("COL1", "abc-" + count.get());
  8. put("COL2", "abd-" + count.get());
  9. put("ZCOL0", "zero-" + count.get());
  10. put("COL3", "bbb-" + count.getAndAdd(1));
  11. }};
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement