Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
rhbz865632 - Add a target document async push service.
Browse files Browse the repository at this point in the history
  • Loading branch information
Carlos Munoz committed Oct 16, 2012
1 parent ebdf490 commit d360c7e
Showing 1 changed file with 15 additions and 4 deletions.
Expand Up @@ -31,8 +31,10 @@
import javax.ws.rs.QueryParam;
import javax.ws.rs.core.MediaType;

import org.zanata.common.LocaleId;
import org.zanata.rest.dto.ProcessStatus;
import org.zanata.rest.dto.resource.Resource;
import org.zanata.rest.dto.resource.TranslationsResource;

/**
* Represents a resource for an asynchronous process. Only certain processes are exposed
Expand All @@ -47,8 +49,7 @@ public interface AsynchronousProcessResource

@POST
@Path("/projects/p/{projectSlug}/iterations/i/{iterationSlug}/r")
/* Same as SourceDocResourceService.SERVICE_PATH
*/
/* Same as SourceDocResourceService.SERVICE_PATH */
public ProcessStatus startSourceDocCreation(@PathParam("id") String idNoSlash,
@PathParam("projectSlug") String projectSlug,
@PathParam("iterationSlug") String iterationSlug,
Expand All @@ -58,15 +59,25 @@ public ProcessStatus startSourceDocCreation(@PathParam("id") String idNoSlash,

@PUT
@Path("/projects/p/{projectSlug}/iterations/i/{iterationSlug}/r" + SourceDocResource.RESOURCE_SLUG_TEMPLATE)
/* Same as SourceDocResourceService.SERVICE_PATH
*/
/* Same as SourceDocResourceService.SERVICE_PATH */
public ProcessStatus startSourceDocCreationOrUpdate(@PathParam("id") String idNoSlash,
@PathParam("projectSlug") String projectSlug,
@PathParam("iterationSlug") String iterationSlug,
Resource resource,
@QueryParam("ext") Set<String> extensions,
@QueryParam("copyTrans") @DefaultValue("true") boolean copytrans);

@PUT
@Path("/projects/p/{projectSlug}/iterations/i/{iterationSlug}/r/{id}/translations/{locale}")
/* Same as TranslatedDocResource.putTranslations */
public ProcessStatus startTranslatedDocCreationOrUpdate(@PathParam("id") String idNoSlash,
@PathParam("projectSlug") String projectSlug,
@PathParam("iterationSlug") String iterationSlug,
@PathParam("locale") LocaleId locale,
TranslationsResource translatedDoc,
@QueryParam("ext") Set<String> extensions,
@QueryParam("merge") String merge);

@GET
@Path("/{processId}")
public ProcessStatus getProcessStatus( @PathParam("processId") String processId );
Expand Down

0 comments on commit d360c7e

Please sign in to comment.