X-Git-Url: https://git.pterodactylus.net/?p=WoTNS.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fwotns%2Ffreenet%2Fwot%2FWebOfTrustConnector.java;h=4274caf22cf4287898c3776c85d7a2e4260998b4;hp=9b11309e30529e18bf1d93f54bd1362c4e7db962;hb=9251a40d3196f48d8c72b604ee8944bf391d26b0;hpb=0ee2ee385ee5c3591039c23baf57ce1a0871a0f5 diff --git a/src/main/java/net/pterodactylus/wotns/freenet/wot/WebOfTrustConnector.java b/src/main/java/net/pterodactylus/wotns/freenet/wot/WebOfTrustConnector.java index 9b11309..4274caf 100644 --- a/src/main/java/net/pterodactylus/wotns/freenet/wot/WebOfTrustConnector.java +++ b/src/main/java/net/pterodactylus/wotns/freenet/wot/WebOfTrustConnector.java @@ -86,7 +86,6 @@ public class WebOfTrustConnector implements ConnectorListener { * if the own identities can not be loaded */ public Set loadAllOwnIdentities() throws WebOfTrustException { - @SuppressWarnings("hiding") Reply reply = performRequest(SimpleFieldSetConstructor.create().put("Message", "GetOwnIdentities").get()); SimpleFieldSet fields = reply.getFields(); int ownIdentityCounter = -1; @@ -114,10 +113,10 @@ public class WebOfTrustConnector implements ConnectorListener { * @param ownIdentity * The own identity * @return All trusted identities - * @throws PluginException + * @throws WebOfTrustException * if an error occured talking to the Web of Trust plugin */ - public Set loadTrustedIdentities(OwnIdentity ownIdentity) throws PluginException { + public Set loadTrustedIdentities(OwnIdentity ownIdentity) throws WebOfTrustException { return loadTrustedIdentities(ownIdentity, null); } @@ -130,11 +129,10 @@ public class WebOfTrustConnector implements ConnectorListener { * @param context * The context to filter, or {@code null} * @return All trusted identities - * @throws PluginException + * @throws WebOfTrustException * if an error occured talking to the Web of Trust plugin */ - public Set loadTrustedIdentities(OwnIdentity ownIdentity, String context) throws PluginException { - @SuppressWarnings("hiding") + public Set loadTrustedIdentities(OwnIdentity ownIdentity, String context) throws WebOfTrustException { Reply reply = performRequest(SimpleFieldSetConstructor.create().put("Message", "GetIdentitiesByScore").put("TreeOwner", ownIdentity.getId()).put("Selection", "+").put("Context", (context == null) ? "" : context).get()); SimpleFieldSet fields = reply.getFields(); Set identities = new HashSet(); @@ -195,7 +193,6 @@ public class WebOfTrustConnector implements ConnectorListener { * if an error occured talking to the Web of Trust plugin */ public String getProperty(Identity identity, String name) throws PluginException { - @SuppressWarnings("hiding") Reply reply = performRequest(SimpleFieldSetConstructor.create().put("Message", "GetProperty").put("Identity", identity.getId()).put("Property", name).get()); return reply.getFields().get("Property"); } @@ -409,7 +406,7 @@ public class WebOfTrustConnector implements ConnectorListener { * {@inheritDoc} */ @Override - public void receivedReply(@SuppressWarnings("hiding") PluginConnector pluginConnector, SimpleFieldSet fields, Bucket data) { + public void receivedReply(PluginConnector pluginConnector, SimpleFieldSet fields, Bucket data) { String messageName = fields.get("Message"); logger.log(Level.FINEST, "Received Reply from Plugin: " + messageName); synchronized (reply) {