trevorflanagan commented on this pull request.


> +import static com.google.inject.internal.util.$Preconditions.checkNotNull;
+
+@Singleton
+public class DatacenterToLocation implements Function<Datacenter, Location> {
+
+   private final JustProvider justProvider;
+
+   @Inject
+   public DatacenterToLocation(JustProvider justProvider) {
+      this.justProvider = checkNotNull(justProvider, "justProvider");
+   }
+
+   @Override
+   public Location apply(final Datacenter datacenter) {
+      return new 
LocationBuilder().id(datacenter.id()).description(datacenter.displayName())
+            
.parent(getOnlyElement(justProvider.get())).scope(LocationScope.ZONE)

We have no requirement now for the `DatacenterToLocation` function, so this 
class and it's test will be removed. We are storing the region/zone 
configuration in `DimensionDataCloudControlProviderMetadata` - 
https://github.com/jclouds/jclouds-labs/commit/5c97ea450e870f6bd185ebd99a5e8d3b4f6ea771#diff-c1e71c3b842249c9f480319e0aab4e29

-- 
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/423#discussion_r182977940

Reply via email to