Providers { public static Iterable<ProviderMetadata> viewableAs(TypeToken<? extends View> viewableAs) { return filter(all(), ProviderPredicates.viewableAs(viewableAs)); }  static Function<ProviderMetadata, String> idFunction(); static Function<ProviderMetadata, ApiMetadata> apiMetadataFunction(); static Iterable<ProviderMetadata> fromServiceLoader(); static Iterable<ProviderMetadata> all(); static ProviderMetadata withId(String id); static Iterable<ProviderMetadata> viewableAs(TypeToken<? extends View> viewableAs); static Iterable<ProviderMetadata> viewableAs(Class<? extends View> viewableAs); static Iterable<ProviderMetadata> apiMetadataAssignableFrom(TypeToken<? extends ApiMetadata> api); static Iterable<ProviderMetadata> contextAssignableFrom(
            TypeToken<? extends Context> context); static Iterable<ProviderMetadata> boundedByIso3166Code(String iso3166Code); static Iterable<ProviderMetadata> boundedByIso3166Code(String iso3166Code,
            TypeToken<? extends View> viewableAs); static Iterable<ProviderMetadata> boundedByIso3166Code(String iso3166Code,
            Class<? extends View> viewableAs); static Iterable<ProviderMetadata> collocatedWith(ProviderMetadata providerMetadata); static Iterable<ProviderMetadata> collocatedWith(ProviderMetadata providerMetadata,
            TypeToken<? extends View> viewableAs); static Iterable<ProviderMetadata> collocatedWith(ProviderMetadata providerMetadata,
            Class<? extends View> viewableAs);  }
@Test public void testTransformableTo() { Iterable<ProviderMetadata> providersMetadata = Providers.viewableAs(Storage.class); for (ProviderMetadata providerMetadata : providersMetadata) { assertEquals(testBlobstoreProvider, providerMetadata); } providersMetadata = Providers.viewableAs(Compute.class); for (ProviderMetadata providerMetadata : providersMetadata) { if (providerMetadata.getName().equals(testComputeProvider.getName())) { assertEquals(testComputeProvider, providerMetadata); } else { assertEquals(testYetAnotherComputeProvider, providerMetadata); } } providersMetadata = Providers.viewableAs(Balancer.class); assertEquals(false, providersMetadata.iterator().hasNext()); }