Class TestkitDirectoryResource
java.lang.Object
com.atlassian.crowd.plugins.testkit.rest.TestkitDirectoryResource
@Named
@Path("/directory")
@Produces("application/json")
@Consumes("application/json")
public class TestkitDirectoryResource
extends Object
-
Constructor Summary
ConstructorsConstructorDescriptionTestkitDirectoryResource(DirectoryManager directoryManager, SynchronisationStatusManager synchronisationStatusManager, EncryptionSettings encryptionSettings) -
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.ResponsecreateDirectory(DirectoryImpl directory) javax.ws.rs.core.ResponsedeleteDirectory(long directoryId) javax.ws.rs.core.ResponsegetAttributes(long directoryId) javax.ws.rs.core.ResponsegetDirectory(long directoryId) javax.ws.rs.core.ResponsegetDirectorySynchronisationStatus(long directoryId) javax.ws.rs.core.ResponsemarkSynchronizationFinished(long directoryId, String syncToken) javax.ws.rs.core.ResponsesetPollDelay(String value) javax.ws.rs.core.ResponsesyncDirectory(long directoryId, SynchronisationMode mode) javax.ws.rs.core.ResponseupdateDirectory(long directoryId, DirectoryImpl directory) javax.ws.rs.core.ResponseupdateDirectoryAttributes(long directoryId, Map<String, String> attributes) javax.ws.rs.core.ResponseupdateDirectoryPermissions(long directoryId, Set<OperationType> operationTypes)
-
Constructor Details
-
TestkitDirectoryResource
@Inject public TestkitDirectoryResource(DirectoryManager directoryManager, SynchronisationStatusManager synchronisationStatusManager, EncryptionSettings encryptionSettings)
-
-
Method Details
-
listDirectories
- Throws:
IOException
-
getDirectory
@GET @Path("/{id}") public javax.ws.rs.core.Response getDirectory(@PathParam("id") long directoryId) throws DirectoryCurrentlySynchronisingException, DirectoryNotFoundException, IOException -
deleteDirectory
@DELETE @Path("/{id}") public javax.ws.rs.core.Response deleteDirectory(@PathParam("id") long directoryId) throws DirectoryCurrentlySynchronisingException, DirectoryNotFoundException -
updateDirectory
@PUT @Path("/{id}") public javax.ws.rs.core.Response updateDirectory(@PathParam("id") long directoryId, DirectoryImpl directory) throws DirectoryNotFoundException - Throws:
DirectoryNotFoundException
-
updateDirectoryAttributes
@PUT @Path("/{id}/attributes") public javax.ws.rs.core.Response updateDirectoryAttributes(@PathParam("id") long directoryId, Map<String, String> attributes) throws DirectoryNotFoundException- Throws:
DirectoryNotFoundException
-
updateDirectoryPermissions
@PUT @Path("/{id}/permissions") public javax.ws.rs.core.Response updateDirectoryPermissions(@PathParam("id") long directoryId, Set<OperationType> operationTypes) throws DirectoryNotFoundException - Throws:
DirectoryNotFoundException
-
createDirectory
@POST public javax.ws.rs.core.Response createDirectory(DirectoryImpl directory) throws IOException, DirectoryInstantiationException -
syncDirectory
@Path("/{id}/sync") @POST public javax.ws.rs.core.Response syncDirectory(@PathParam("id") long directoryId, @QueryParam("mode") @DefaultValue("INCREMENTAL") SynchronisationMode mode) throws OperationFailedException, DirectoryNotFoundException -
getDirectorySynchronisationStatus
@Path("/{id}/sync") @GET public javax.ws.rs.core.Response getDirectorySynchronisationStatus(@PathParam("id") long directoryId) throws DirectoryInstantiationException, DirectoryNotFoundException, IOException -
markSynchronizationFinished
@Path("/{id}/sync/token") @PUT public Map<String,String> markSynchronizationFinished(@PathParam("id") long directoryId, @QueryParam("token") String syncToken) throws DirectoryNotFoundException, IOException, DirectoryInstantiationException -
setPollDelay
@Path("/polldelay/{value}") @POST public javax.ws.rs.core.Response setPollDelay(@PathParam("value") String value) -
getAttributes
@Path("{id}/attributes") @GET public javax.ws.rs.core.Response getAttributes(@PathParam("id") long directoryId) throws DirectoryNotFoundException - Throws:
DirectoryNotFoundException
-