public class ESServerImpl extends AbstractAPIImpl<ESServerImpl,ServerInfo> implements ESServer
ESServer and ServerInfo.| Constructor and Description |
|---|
ESServerImpl(ServerInfo serverInfo)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
ESRemoteProject |
createRemoteProject(ESUsersession usersession,
String projectName,
org.eclipse.core.runtime.IProgressMonitor progressMonitor)
Creates an empty project on the server.
|
ESRemoteProject |
createRemoteProject(String projectName,
org.eclipse.core.runtime.IProgressMonitor monitor)
Creates an empty project on the server.
|
String |
getCertificateAlias()
Returns the alias for the certificate used by this server.
|
ESUsersession |
getLastUsersession()
Returns the
ESUsersession which was used on the last call to this server. |
String |
getName()
Returns the local name of the server.
|
int |
getPort()
Returns the port of the server where EMFStore is listening on.
|
ESRemoteProject |
getRemoteProject(ESGlobalProjectId projectId)
Returns the remote project with the given ID.
|
ESRemoteProject |
getRemoteProject(ESUsersession usersession,
ESGlobalProjectId projectId)
Returns the remote project with the given ID.
|
List<ESRemoteProject> |
getRemoteProjects()
Returns a list with all remote projects hosted on this server.
|
List<ESRemoteProject> |
getRemoteProjects(ESUsersession usersession)
Returns a list with all remote projects hosted on this server.
|
String |
getURL()
Returns the URL of the server.
|
ESUsersession |
login(String name,
String password)
Logs into this server, returning a
ESUsersession. |
void |
setCertificateAlias(String alias)
Sets a new certificate alias.
|
void |
setName(String serverName)
Sets the local name of the server.
|
void |
setPort(int port)
Sets the port of the server where EMFStore is listening on.
|
void |
setURL(String url)
Sets the URL of the server.
|
equals, hashCode, toInternalAPIpublic ESServerImpl(ServerInfo serverInfo)
serverInfo - the delegatepublic String getName()
getName in interface ESServerESServer.getName()public void setName(String serverName)
setName in interface ESServerserverName - the new local name of th serverESServer.setName(java.lang.String)public int getPort()
getPort in interface ESServerESServer.getPort()public void setPort(int port)
setPort in interface ESServerport - the port of the server EMFStore is listing onESServer.setPort(int)public String getURL()
getURL in interface ESServerESServer.getURL()public void setURL(String url)
setURL in interface ESServerurl - the URL of the server as a stringESServer.setURL(java.lang.String)public String getCertificateAlias()
KeyStoreManagergetCertificateAlias in interface ESServerESServer.getCertificateAlias()public void setCertificateAlias(String alias)
setCertificateAlias in interface ESServeralias - the alias of the the certificate to be setESServer.setCertificateAlias(java.lang.String)public ESUsersession getLastUsersession()
ESUsersession which was used on the last call to this server.getLastUsersession in interface ESServerESServer.getLastUsersession()public ESRemoteProject createRemoteProject(String projectName, org.eclipse.core.runtime.IProgressMonitor monitor) throws ESException
createRemoteProject in interface ESServerprojectName - The name of the project to be createdmonitor - a IProgressMonitor instance that is used to indicate progress
about creating the remote projectESRemoteProject object containing information about the
created projectESException - If an error occurs while creating the remote projectESServer.createRemoteProject(java.lang.String,
org.eclipse.core.runtime.IProgressMonitor)public ESRemoteProject createRemoteProject(ESUsersession usersession, String projectName, org.eclipse.core.runtime.IProgressMonitor progressMonitor) throws ESException
createRemoteProject in interface ESServerusersession - the ESUsersession that should be used to create the
remote project.null, the session manager will search for a
session.projectName - the name of the projectprogressMonitor - a monitor to show the progressESRemoteProject object containing information about the
created projectESException - If an error occurs while creating the remote projectESServer.createRemoteProject(org.eclipse.emf.emfstore.client.ESUsersession,
java.lang.String, org.eclipse.core.runtime.IProgressMonitor)public ESUsersession login(String name, String password) throws ESException
ESUsersession.login in interface ESServername - the name of the userpassword - the cleartext password of the userESUsersessionESException - in case an error occurs while creating and logging in the session for the given userESServer.login(java.lang.String, java.lang.String)public List<ESRemoteProject> getRemoteProjects() throws ESException
getRemoteProjects in interface ESServerESException - in case an error occurs while retrieving the list of remote projectsESServer.getRemoteProjects()public List<ESRemoteProject> getRemoteProjects(ESUsersession usersession) throws ESException
getRemoteProjects in interface ESServerusersession - the ESUsersession that should be used to fetch the remote projects.null, the session manager will try to inject a session.ESException - in case an error occurs while retrieving the list of remote projectsESServer.getRemoteProjects(org.eclipse.emf.emfstore.client.ESUsersession)public ESRemoteProject getRemoteProject(ESGlobalProjectId projectId) throws ESException
projectId - the ID of the projectnull, if no project with the given ID has been foundESException - in case an error occurs while retrieving the remote projectpublic ESRemoteProject getRemoteProject(ESUsersession usersession, ESGlobalProjectId projectId) throws ESException
usersession - the ESUsersession that should be used to fetch the remote project.null, the session manager will try to inject a session.projectId - the ID of the projectnull, if no project with the given ID has been foundESException - in case an error occurs while retrieving the remote projectCopyright © 2017. All rights reserved.