public interface RedmineServiceImplementor
RedmineRestClient.
A default implementation is offered in DefaultRedmineServiceImplementor.
Any concrete implentation of a redmine service should implements this..DefaultRedmineServiceImplementor| Modifier and Type | Method and Description |
|---|---|
void |
checkLoggued()
Checks if the current session is not a anonymous one.
|
void |
checkNotLoggued(org.nuiton.io.rest.RestClient session)
Checks if the current session is anonymous.
|
void |
destroy()
Close the service and destroy any connexion to the redmine service.
|
<T> T |
getData(String requestName,
Class<T> type,
Object... args)
Generic method to obtain a single data from a redmine server.
|
<T> T[] |
getDatas(String requestName,
Class<T> type,
Object... args)
Generic method to obtain a array of data from a redmine server.
|
org.nuiton.io.rest.RestClient |
getSession()
Gets the transport layer based on
RestClient. |
RedmineServiceImplementor |
init(RedmineServiceConfiguration configuration)
Initialize the service given a client configuration.
|
boolean |
isInit()
Tests if the service is loogued to the redmine service.
|
<T> T |
sendData(String requestName,
Class<T> klazz,
Object... args)
Generic method to send a data to a redmine server and return the single
data updated from the redmine server.
|
<T> T[] |
sendDatas(String requestName,
Class<T> klazz,
Object... args)
Generic method to send a data (or more ) to a redmine server and
return the array of data from the redmine server.
|
boolean isInit()
true is service is init and loggued to Redmine service,
false otherwise.RedmineServiceImplementor init(RedmineServiceConfiguration configuration) throws RedmineServiceException
configuration - the configuration to be used to init the internal redmine clientRedmineServiceException - if any pbvoid destroy()
throws RedmineServiceException
RedmineServiceException - if any pborg.nuiton.io.rest.RestClient getSession()
RestClient.<T> T getData(String requestName, Class<T> type, Object... args) throws RedmineServiceException
T - the type of data to obtainrequestName - the name of the request to usetype - the type of data to obtainargs - the parameters to obtain the dataRedmineServiceException - if any pb<T> T[] getDatas(String requestName, Class<T> type, Object... args) throws RedmineServiceException
T - the type of data to obtainrequestName - the name of the request to usetype - the type of data to obtainargs - the parameters to obtain the datasRedmineServiceException - if any pb<T> T sendData(String requestName, Class<T> klazz, Object... args) throws RedmineServiceException
T - the type of data to treaterequestName - the name of the request usedklazz - the type of data to treateargs - the parameters of the requestRedmineServiceException - if any pb<T> T[] sendDatas(String requestName, Class<T> klazz, Object... args) throws RedmineServiceException
T - the type of data to treaterequestName - the name of the request usedklazz - the type of data to treateargs - the parameters of the requestRedmineServiceException - if any pbvoid checkLoggued()
throws IllegalStateException,
RedmineServiceLoginException,
NullPointerException
IllegalStateException - if service not initRedmineServiceLoginException - if not logguedNullPointerException - if something is nullvoid checkNotLoggued(org.nuiton.io.rest.RestClient session)
throws RedmineServiceLoginException,
NullPointerException
session - the session to testRedmineServiceLoginException - if not anonymousNullPointerException - if something is nullCopyright © 2009-2012 CodeLutin. All Rights Reserved.