public class ApplicationResource extends Object
Modifier and Type | Field and Description |
---|---|
static String |
APPLICATION_NAME_QUERY_PARAM |
protected javax.servlet.http.HttpServletRequest |
request |
protected javax.ws.rs.core.UriInfo |
uriInfo |
Constructor and Description |
---|
ApplicationResource(ApplicationController applicationController) |
Modifier and Type | Method and Description |
---|---|
javax.ws.rs.core.Response |
addApplication(boolean includeRequestAddress,
ApplicationEntity applicationEntity)
Adds a new application.
|
javax.ws.rs.core.Response |
addRemoteAddress(long applicationId,
RemoteAddressEntity remoteAddressEntity)
Adds the remote address to the specified application.
|
javax.ws.rs.core.Response |
getApplicationById(long applicationId)
Returns the specified application.
|
javax.ws.rs.core.Response |
getApplications(String applicationName)
Returns all the applications or a specific application by name
|
javax.ws.rs.core.Response |
getRemoteAddresses(long applicationId)
Returns the remote addresses of the specified application.
|
javax.ws.rs.core.Response |
removeApplication(long applicationId)
Removes the specified application.
|
javax.ws.rs.core.Response |
removeRemoteAddress(long applicationId,
String remoteAddress)
Removes the remote address of the specified application.
|
javax.ws.rs.core.Response |
updateApplication(long applicationId,
ApplicationEntity applicationEntity)
Updates the specified application.
|
public static final String APPLICATION_NAME_QUERY_PARAM
@Context protected javax.ws.rs.core.UriInfo uriInfo
@Context protected javax.servlet.http.HttpServletRequest request
public ApplicationResource(ApplicationController applicationController)
public javax.ws.rs.core.Response getApplications(String applicationName) throws ApplicationNotFoundException
ApplicationNotFoundException
public javax.ws.rs.core.Response getApplicationById(long applicationId) throws ApplicationNotFoundException
applicationId
- ID of the applicationApplicationNotFoundException
public javax.ws.rs.core.Response addApplication(boolean includeRequestAddress, ApplicationEntity applicationEntity) throws DirectoryNotFoundException, InvalidCredentialException, ApplicationAlreadyExistsException
applicationEntity
- new application entityDirectoryNotFoundException
InvalidCredentialException
ApplicationAlreadyExistsException
public javax.ws.rs.core.Response removeApplication(long applicationId) throws ApplicationManagerException
applicationId
- ID of the applicationApplicationManagerException
public javax.ws.rs.core.Response updateApplication(long applicationId, ApplicationEntity applicationEntity) throws ApplicationNotFoundException, DirectoryNotFoundException, ApplicationManagerException
applicationId
- ID of the applicationApplicationNotFoundException
DirectoryNotFoundException
ApplicationManagerException
public javax.ws.rs.core.Response getRemoteAddresses(long applicationId) throws ApplicationNotFoundException
applicationId
- ID of the applicationApplicationNotFoundException
public javax.ws.rs.core.Response addRemoteAddress(long applicationId, RemoteAddressEntity remoteAddressEntity) throws ApplicationNotFoundException, DirectoryNotFoundException, ApplicationManagerException
applicationId
- ID of the applicationremoteAddressEntity
- remote address entityApplicationNotFoundException
DirectoryNotFoundException
ApplicationManagerException
public javax.ws.rs.core.Response removeRemoteAddress(long applicationId, String remoteAddress) throws ApplicationNotFoundException, DirectoryNotFoundException, ApplicationManagerException
applicationId
- ID of the applicationremoteAddress
- remote address to removeApplicationNotFoundException
DirectoryNotFoundException
ApplicationManagerException
Copyright © 2020 Atlassian. All rights reserved.