diff options
author | Martin <marcin.j.chrzanowski@gmail.com> | 2020-01-27 22:25:41 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-27 22:25:41 +0100 |
commit | 1583288396fe8971d830c7bbe49231a127e0c0bb (patch) | |
tree | 0142b81524da3d88a2ccf53178229ff8f195c731 /src/main/java/pl/edu/mimuw/cloudatlas/fetcher | |
parent | 6ed68039f45bf4f1b7dc3031db66aac5cbcb6c04 (diff) | |
parent | 1383166dd80b8cec4d7b20e81725eaa219717d5d (diff) |
Merge pull request #131 from m-chrzan/filter-self
Filter self
Diffstat (limited to 'src/main/java/pl/edu/mimuw/cloudatlas/fetcher')
-rw-r--r-- | src/main/java/pl/edu/mimuw/cloudatlas/fetcher/Fetcher.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/java/pl/edu/mimuw/cloudatlas/fetcher/Fetcher.java b/src/main/java/pl/edu/mimuw/cloudatlas/fetcher/Fetcher.java index 096e4e3..8916b13 100644 --- a/src/main/java/pl/edu/mimuw/cloudatlas/fetcher/Fetcher.java +++ b/src/main/java/pl/edu/mimuw/cloudatlas/fetcher/Fetcher.java @@ -114,9 +114,12 @@ public class Fetcher { api.setFallbackContacts(ClientController.parseContactsString(fallbackContactsString)); ValueContact initialContact = new ValueContact(new PathName(zonePath), InetAddress.getByName(ownAddr)); - api.setAttributeValue(zonePath, "contacts", initialContact); + Set<Value> initialContacts = new HashSet(); + initialContacts.add(initialContact); + ValueSet initialContactsValue = new ValueSet(initialContacts, TypePrimitive.CONTACT); while((jsonAttribs = bufferRead.readLine()) != null) { + api.setAttributeValue(zonePath, "contacts", initialContactsValue); System.out.println(jsonAttribs); System.out.flush(); deserializedAttribs = deserializeAttribs(jsonAttribs); |