本文整理匯總了Java中org.openstack4j.api.OSClient.OSClientV3類的典型用法代碼示例。如果您正苦於以下問題:Java OSClientV3類的具體用法?Java OSClientV3怎麽用?Java OSClientV3使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
OSClientV3類屬於org.openstack4j.api.OSClient包,在下文中一共展示了OSClientV3類的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: authenticateAndGetObjectStorageService
import org.openstack4j.api.OSClient.OSClientV3; //導入依賴的package包/類
private ObjectStorageService authenticateAndGetObjectStorageService() {
String OBJECT_STORAGE_AUTH_URL = "https://identity.open.softlayer.com/v3";
Identifier domainIdentifier = Identifier.byName(DOMAIN_ID);
System.out.println("Authenticating...");
OSClientV3 os = OSFactory.builderV3()
.endpoint(OBJECT_STORAGE_AUTH_URL)
.credentials(USERNAME,PASSWORD, domainIdentifier)
.scopeToProject(Identifier.byId(PROJECT_ID))
.authenticate();
System.out.println("Authenticated successfully!");
ObjectStorageService objectStorage = os.objectStorage();
return objectStorage;
}
開發者ID:ibm-bluemix-mobile-services,項目名稱:bluemix-objectstorage-sample-liberty,代碼行數:20,代碼來源:SimpleServlet.java
示例2: getOsClient
import org.openstack4j.api.OSClient.OSClientV3; //導入依賴的package包/類
public OSClientV3 getOsClient() {
this.reauth();
return this.os;
}
示例3: createAuthenticated
import org.openstack4j.api.OSClient.OSClientV3; //導入依賴的package包/類
@Override
public OSClientV3 createAuthenticated() {
return this.factory.authenticate();
}