com.openshift.internal.client
Class UserResource
java.lang.Object
com.openshift.internal.client.AbstractOpenShiftResource
com.openshift.internal.client.UserResource
- All Implemented Interfaces:
- IOpenShiftResource, IUser
public class UserResource
- extends AbstractOpenShiftResource
- implements IUser
- Author:
- André Dietisheim
Fields inherited from interface com.openshift.client.IUser |
ID |
UserResource
public UserResource(APIResource api,
UserResourceDTO dto,
String password)
getConnection
public IOpenShiftConnection getConnection()
- Specified by:
getConnection
in interface IUser
getRhlogin
public String getRhlogin()
- Specified by:
getRhlogin
in interface IUser
getPassword
public String getPassword()
- Specified by:
getPassword
in interface IUser
getServer
public String getServer()
- Specified by:
getServer
in interface IUser
getMaxGears
public int getMaxGears()
- Specified by:
getMaxGears
in interface IUser
getConsumedGears
public int getConsumedGears()
- Specified by:
getConsumedGears
in interface IUser
createDomain
public IDomain createDomain(String id)
throws OpenShiftException
- Specified by:
createDomain
in interface IUser
- Throws:
OpenShiftException
getDomains
public List<IDomain> getDomains()
throws OpenShiftException
- Specified by:
getDomains
in interface IUser
- Throws:
OpenShiftException
getDefaultDomain
public IDomain getDefaultDomain()
throws OpenShiftException
- Specified by:
getDefaultDomain
in interface IUser
- Throws:
OpenShiftException
getDomain
public IDomain getDomain(String id)
throws OpenShiftException
- Specified by:
getDomain
in interface IUser
- Throws:
OpenShiftException
hasDomain
public boolean hasDomain()
throws OpenShiftException
- Specified by:
hasDomain
in interface IUser
- Throws:
OpenShiftException
hasDomain
public boolean hasDomain(String id)
throws OpenShiftException
- Specified by:
hasDomain
in interface IUser
- Throws:
OpenShiftException
refresh
public void refresh()
throws OpenShiftException
- Description copied from interface:
IOpenShiftResource
- Refresh the resource and its list of children resources that were
previously loaded
- Specified by:
refresh
in interface IOpenShiftResource
- Throws:
OpenShiftException
getSSHKeys
public List<IOpenShiftSSHKey> getSSHKeys()
throws OpenShiftUnknonwSSHKeyTypeException,
OpenShiftException
- Specified by:
getSSHKeys
in interface IUser
- Throws:
OpenShiftUnknonwSSHKeyTypeException
OpenShiftException
deleteKey
public void deleteKey(String name)
- Specified by:
deleteKey
in interface IUser
getSSHKeyByName
public IOpenShiftSSHKey getSSHKeyByName(String name)
throws OpenShiftUnknonwSSHKeyTypeException,
OpenShiftException
- Specified by:
getSSHKeyByName
in interface IUser
- Throws:
OpenShiftUnknonwSSHKeyTypeException
OpenShiftException
getSSHKeyByPublicKey
public IOpenShiftSSHKey getSSHKeyByPublicKey(String publicKey)
throws OpenShiftUnknonwSSHKeyTypeException,
OpenShiftException
- Specified by:
getSSHKeyByPublicKey
in interface IUser
- Throws:
OpenShiftUnknonwSSHKeyTypeException
OpenShiftException
hasSSHKeyName
public boolean hasSSHKeyName(String name)
throws OpenShiftUnknonwSSHKeyTypeException,
OpenShiftException
- Specified by:
hasSSHKeyName
in interface IUser
- Throws:
OpenShiftUnknonwSSHKeyTypeException
OpenShiftException
hasSSHPublicKey
public boolean hasSSHPublicKey(String publicKey)
throws OpenShiftUnknonwSSHKeyTypeException,
OpenShiftException
- Specified by:
hasSSHPublicKey
in interface IUser
- Throws:
OpenShiftUnknonwSSHKeyTypeException
OpenShiftException
putSSHKey
public IOpenShiftSSHKey putSSHKey(String name,
ISSHPublicKey key)
throws OpenShiftException
- Adds the given ssh key with the given name. Key names and public keys have to be unique. Throws
OpenShiftSSHKeyException if either the key name or the public key are already used.
- Specified by:
putSSHKey
in interface IUser
- Parameters:
name
- the name to identify the keykey
- the key to add
- Returns:
-
- Throws:
OpenShiftException
removeSSHKey
protected void removeSSHKey(SSHKeyResource key)
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2014 JBoss, a division of Red Hat, Inc.. All Rights Reserved.