Package org.openstack4j.openstack.client
Class OSClientBuilder.ClientV3
- java.lang.Object
-
- org.openstack4j.openstack.client.OSClientBuilder<OSClient.OSClientV3,IOSClientBuilder.V3>
-
- org.openstack4j.openstack.client.OSClientBuilder.ClientV3
-
- All Implemented Interfaces:
IOSClientBuilder<OSClient.OSClientV3,IOSClientBuilder.V3>,IOSClientBuilder.V3
- Enclosing class:
- OSClientBuilder<R,T extends IOSClientBuilder<R,T>>
public static class OSClientBuilder.ClientV3 extends OSClientBuilder<OSClient.OSClientV3,IOSClientBuilder.V3> implements IOSClientBuilder.V3
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.openstack4j.openstack.client.OSClientBuilder
OSClientBuilder.ClientV2, OSClientBuilder.ClientV3
-
Nested classes/interfaces inherited from interface org.openstack4j.api.client.IOSClientBuilder
IOSClientBuilder.V2, IOSClientBuilder.V3
-
-
Constructor Summary
Constructors Constructor Description ClientV3()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OSClient.OSClientV3authenticate()Attempts to connect, authenticated and obtain an authorization access entity which contains a token, service catalog and endpoints from the controller.OSClientBuilder.ClientV3credentials(String user, String password, Identifier domain)The authentication credentials and default scoped domainOSClientBuilder.ClientV3domainId(String domainId)DEPRECATED: Please useIOSClientBuilder.V3.credentials(String, String, Identifier)OSClientBuilder.ClientV3domainName(String domainName)DEPRECATED: Please useAuthenticates against the specified domain name
OSClientBuilder.ClientV3scopeToDomain(Identifier domain)Scopes the token to a domain levelOSClientBuilder.ClientV3scopeToProject(Identifier project)scopes the token to a project levelOSClientBuilder.ClientV3scopeToProject(Identifier project, Identifier domain)Scopes the token to a project levelOSClientBuilder.ClientV3token(String tokenId)A token object.-
Methods inherited from class org.openstack4j.openstack.client.OSClientBuilder
credentials, endpoint, perspective, provider, useNonStrictSSLClient, withConfig
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.openstack4j.api.client.IOSClientBuilder
credentials, endpoint, perspective, provider, useNonStrictSSLClient, withConfig
-
-
-
-
Method Detail
-
domainName
public OSClientBuilder.ClientV3 domainName(String domainName)
Description copied from interface:IOSClientBuilder.V3DEPRECATED: Please useAuthenticates against the specified domain name
- Specified by:
domainNamein interfaceIOSClientBuilder.V3- Parameters:
domainName- the domain name to authenticate against- Returns:
- self for method chaining
-
domainId
public OSClientBuilder.ClientV3 domainId(String domainId)
Description copied from interface:IOSClientBuilder.V3DEPRECATED: Please useIOSClientBuilder.V3.credentials(String, String, Identifier)Authenticates against the specified domain identifier
- Specified by:
domainIdin interfaceIOSClientBuilder.V3- Parameters:
domainId- the domain identifier to authenticate against- Returns:
- self for method chaining
-
credentials
public OSClientBuilder.ClientV3 credentials(String user, String password, Identifier domain)
Description copied from interface:IOSClientBuilder.V3The authentication credentials and default scoped domain- Specified by:
credentialsin interfaceIOSClientBuilder.V3- Parameters:
user- the user name to authenticate withpassword- the password to authenticate withdomain- the domain if using "default scoped"- Returns:
- self for method chaining
-
token
public OSClientBuilder.ClientV3 token(String tokenId)
Description copied from interface:IOSClientBuilder.V3A token object. With token authentication, the id uniquely identifies the token. This method is typically used in combination with a request to change authorization scope- Specified by:
tokenin interfaceIOSClientBuilder.V3- Parameters:
tokenId- the token identifier- Returns:
- self for method chaining
-
authenticate
public OSClient.OSClientV3 authenticate() throws AuthenticationException
Description copied from interface:IOSClientBuilderAttempts to connect, authenticated and obtain an authorization access entity which contains a token, service catalog and endpoints from the controller. As a result a client will be returned encapsulating the authorized access and corresponding API access- Specified by:
authenticatein interfaceIOSClientBuilder<OSClient.OSClientV3,IOSClientBuilder.V3>- Returns:
- the authenticated client
- Throws:
AuthenticationException- if the credentials or default tenant is invalid
-
scopeToProject
public OSClientBuilder.ClientV3 scopeToProject(Identifier project, Identifier domain)
Description copied from interface:IOSClientBuilder.V3Scopes the token to a project level- Specified by:
scopeToProjectin interfaceIOSClientBuilder.V3- Parameters:
project- the project ID or Name valuedomain- the domain ID or Name value- Returns:
- self for method chaining
-
scopeToProject
public OSClientBuilder.ClientV3 scopeToProject(Identifier project)
Description copied from interface:IOSClientBuilder.V3scopes the token to a project level- Specified by:
scopeToProjectin interfaceIOSClientBuilder.V3- Parameters:
project- the project id- Returns:
- self for method chaining
-
scopeToDomain
public OSClientBuilder.ClientV3 scopeToDomain(Identifier domain)
Description copied from interface:IOSClientBuilder.V3Scopes the token to a domain level- Specified by:
scopeToDomainin interfaceIOSClientBuilder.V3- Parameters:
domain- the domain ID or Name value- Returns:
- self for method chaining
-
-