Package org.jclouds.openstack.keystone.v2_0.domain

Examples of org.jclouds.openstack.keystone.v2_0.domain.PasswordCredentials$Builder


      Optional<? extends TenantAdminApi> tenantAdminApiExtension = keystoneApi.getTenantAdminApi();

      if (tenantAdminApiExtension.isPresent()) {
         System.out.format("    TenantAdminApi is present%n");

         TenantAdminApi tenantAdminApi = tenantAdminApiExtension.get();
         CreateTenantOptions tenantOptions = CreateTenantOptions.Builder
               .description("My New Tenant");
         Tenant tenant = tenantAdminApi.create("newTenant", tenantOptions);

         System.out.format("    %s%n", tenant);

         return tenant;
      } else {
View Full Code Here


      Optional<? extends UserAdminApi> userAdminApiExtension = keystoneApi.getUserAdminApi();

      if (userAdminApiExtension.isPresent()) {
         System.out.format("    UserAdminApi is present%n");

         UserAdminApi userAdminApi = userAdminApiExtension.get();
         CreateUserOptions userOptions = CreateUserOptions.Builder
               .tenant(tenant.getId())
               .email("new.email@example.com");
         User user = userAdminApi.create("newUser", "newPassword", userOptions);

         System.out.format("    %s%n", user);
      } else {
         System.out.format("    UserAdminApi is *not* present%n");
         System.exit(1);
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<Tenant>> markerToNextForCallingArg0(final String ignored) {
         final TenantApi tenantApi = api.getTenantApi().get();
         return new Function<Object, IterableWithMarker<Tenant>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<Tenant> apply(Object input) {
               return IterableWithMarker.class.cast(tenantApi.list(marker(input.toString())));
            }

            @Override
            public String toString() {
               return "listTenants()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<Tenant>> markerToNextForArg0(Optional<Object> ignored) {
         final TenantApi tenantApi = api.getTenantApi().get();
         return new Function<Object, IterableWithMarker<Tenant>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<Tenant> apply(Object input) {
               PaginationOptions paginationOptions = PaginationOptions.class.cast(input);
               return IterableWithMarker.class.cast(tenantApi.list(paginationOptions));
            }

            @Override
            public String toString() {
               return "listTenants()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<Tenant>> markerToNextForArg0(Optional<Object> ignored) {
         final TenantApi tenantApi = api.getTenantApi().get();
         return new Function<Object, IterableWithMarker<Tenant>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<Tenant> apply(Object input) {
               PaginationOptions paginationOptions = PaginationOptions.class.cast(input);
               return IterableWithMarker.class.cast(tenantApi.list(paginationOptions));
            }

            @Override
            public String toString() {
               return "listTenants()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<Tenant>> markerToNextForCallingArg0(final String ignored) {
         final TenantApi tenantApi = api.getTenantApi().get();
         return new Function<Object, IterableWithMarker<Tenant>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<Tenant> apply(Object input) {
               return IterableWithMarker.class.cast(tenantApi.list(marker(input.toString())));
            }

            @Override
            public String toString() {
               return "listTenants()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<User>> markerToNextForCallingArg0(final String ignored) {
         final UserApi userApi = api.getUserApi().get();
         return new Function<Object, IterableWithMarker<User>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<User> apply(Object input) {
               return IterableWithMarker.class.cast(userApi.list(marker(input.toString())));
            }

            @Override
            public String toString() {
               return "listUsers()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<User>> markerToNextForArg0(Optional<Object> ignored) {
         final UserApi userApi = api.getUserApi().get();
         return new Function<Object, IterableWithMarker<User>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<User> apply(Object input) {
               PaginationOptions paginationOptions = PaginationOptions.class.cast(input);
               return IterableWithMarker.class.cast(userApi.list(paginationOptions));
            }

            @Override
            public String toString() {
               return "listUsers()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<User>> markerToNextForArg0(Optional<Object> ignored) {
         final UserApi userApi = api.getUserApi().get();
         return new Function<Object, IterableWithMarker<User>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<User> apply(Object input) {
               PaginationOptions paginationOptions = PaginationOptions.class.cast(input);
               return IterableWithMarker.class.cast(userApi.list(paginationOptions));
            }

            @Override
            public String toString() {
               return "listUsers()";
View Full Code Here

         this.api = checkNotNull(api, "api");
      }

      @Override
      protected Function<Object, IterableWithMarker<User>> markerToNextForCallingArg0(final String ignored) {
         final UserApi userApi = api.getUserApi().get();
         return new Function<Object, IterableWithMarker<User>>() {

            @SuppressWarnings("unchecked")
            @Override
            public IterableWithMarker<User> apply(Object input) {
               return IterableWithMarker.class.cast(userApi.list(marker(input.toString())));
            }

            @Override
            public String toString() {
               return "listUsers()";
View Full Code Here

TOP

Related Classes of org.jclouds.openstack.keystone.v2_0.domain.PasswordCredentials$Builder

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.