Blue Mind
Release 1.0

net.bluemind.core.client.impl
Class AbstractClientImpl

java.lang.Object
  extended by net.bluemind.core.client.impl.AbstractClientImpl
All Implemented Interfaces:
ISyncClient
Direct Known Subclasses:
AbstractEventSyncClient, AclClient, BackupClient, BackupFullClient, BookClient, DeviceClient, DirectoryClient, DistributionListClient, DocClient, GroupClient, InfoClient, JobClient, MailClient, MailshareClient, PrintClient, ResourceClient, RoleBasedAccessControlClient, SettingClient, SieveFilterClient, SolrClient, SystemClient, UiClient, UserClient

public abstract class AbstractClientImpl
extends java.lang.Object
implements ISyncClient

Utility methods for client implementations


Field Summary
protected  Logger logger
           
 
Constructor Summary
protected AbstractClientImpl(java.lang.String backendUrl)
           
 
Method Summary
protected  void checkServerError(org.w3c.dom.Document doc)
           
protected  org.w3c.dom.Document execute(java.lang.String action, java.util.Map<java.lang.String,java.lang.String> parameters)
           
protected  java.io.InputStream executeStream(java.lang.String action, java.util.Map<java.lang.String,java.lang.String> parameters)
           
protected  void executeVoid(java.lang.String action, java.util.Map<java.lang.String,java.lang.String> parameters)
           
protected  java.util.Map<java.lang.String,java.lang.String> initParams(AccessToken at)
           
 AccessToken login(java.lang.String loginAtDomain, java.lang.String password, java.lang.String origin)
           
 void logout(AccessToken at)
           
protected  void setToken(java.util.Map<java.lang.String,java.lang.String> parameters, AccessToken token)
           
 AccessToken sudo(AccessToken token, java.lang.String loginAtDomain)
          Returns an AccessToken for the given loginAtDomain.
 ValidationKind validate(java.lang.String loginAtDomain, java.lang.String password, java.lang.String origin)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected Logger logger
Constructor Detail

AbstractClientImpl

protected AbstractClientImpl(java.lang.String backendUrl)
Method Detail

execute

protected org.w3c.dom.Document execute(java.lang.String action,
                                       java.util.Map<java.lang.String,java.lang.String> parameters)

executeStream

protected java.io.InputStream executeStream(java.lang.String action,
                                            java.util.Map<java.lang.String,java.lang.String> parameters)

setToken

protected void setToken(java.util.Map<java.lang.String,java.lang.String> parameters,
                        AccessToken token)

initParams

protected java.util.Map<java.lang.String,java.lang.String> initParams(AccessToken at)

executeVoid

protected void executeVoid(java.lang.String action,
                           java.util.Map<java.lang.String,java.lang.String> parameters)
                    throws ServerFault
Throws:
ServerFault

login

public AccessToken login(java.lang.String loginAtDomain,
                         java.lang.String password,
                         java.lang.String origin)
Specified by:
login in interface ISyncClient

validate

public ValidationKind validate(java.lang.String loginAtDomain,
                               java.lang.String password,
                               java.lang.String origin)
Specified by:
validate in interface ISyncClient

sudo

public AccessToken sudo(AccessToken token,
                        java.lang.String loginAtDomain)
                 throws AuthFault,
                        ServerFault
Description copied from interface: ISyncClient
Returns an AccessToken for the given loginAtDomain. The provided AccessToken must be an admin0@global.virt token.

Specified by:
sudo in interface ISyncClient
Returns:
Throws:
AuthFault
ServerFault

logout

public void logout(AccessToken at)
Specified by:
logout in interface ISyncClient

checkServerError

protected void checkServerError(org.w3c.dom.Document doc)
                         throws ServerFault
Throws:
ServerFault

Blue Mind
Release 1.0