1 23 24 package org.apache.slide.common; 25 26 import java.util.Hashtable ; 27 28 import javax.transaction.xa.XAResource ; 29 30 import org.apache.slide.authenticate.CredentialsToken; 31 import org.apache.slide.util.logger.Logger; 32 33 38 public interface Service 39 extends XAResource { 40 41 42 44 45 47 48 49 52 void setScope(Scope scope); 53 54 55 56 57 60 void setNamespace(Namespace namespace); 61 62 63 76 void setParameters(Hashtable parameters) 77 throws ServiceParameterErrorException, 78 ServiceParameterMissingException; 79 80 81 87 void connect(CredentialsToken crdtoken) 88 throws ServiceConnectionFailedException; 89 90 91 92 97 void connect() 98 throws ServiceConnectionFailedException; 99 100 101 106 void disconnect() 107 throws ServiceDisconnectionFailedException; 108 109 110 118 void initialize(NamespaceAccessToken token) 119 throws ServiceInitializationFailedException; 120 121 122 127 void reset() 128 throws ServiceResetFailedException; 129 130 131 137 boolean isConnected() 138 throws ServiceAccessException; 139 140 141 149 boolean connectIfNeeded(CredentialsToken crdtoken) 150 throws ServiceConnectionFailedException, ServiceAccessException; 151 152 153 161 boolean connectIfNeeded() 162 throws ServiceConnectionFailedException, ServiceAccessException; 163 164 165 173 boolean cacheResults(); 174 175 176 182 Logger getLogger(); 183 184 185 } 186 | Popular Tags |