trevorflanagan commented on this pull request.


> +      private final NetworkApi networkApi;
+
+      private NetworkDomainState(final NetworkApi networkApi, final State 
state) {
+         this.networkApi = networkApi;
+         this.state = state;
+      }
+
+      @Override
+      public boolean apply(final String networkDomainId) {
+         checkNotNull(networkDomainId, "networkDomainId");
+         logger.trace("looking for state on network domain %s", 
networkDomainId);
+         final NetworkDomain networkDomain = 
networkApi.getNetworkDomain(networkDomainId);
+         final boolean isDeleted = networkDomain == null && state == 
State.DELETED;
+         return isDeleted || (networkDomain != null && networkDomain.state() 
== state);
+      }
+   }

Makes sense, for now we should not require more of these Predicates. But I 
might take this on during my next set of refactoring. 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs/pull/427#discussion_r157273679

Reply via email to