public class Abandon extends java.lang.Object implements RestModifyView<ChangeResource,AbandonInput>, UiAction<ChangeResource>
UiAction.Description
Modifier and Type | Method and Description |
---|---|
Change |
abandon(ChangeControl control) |
Change |
abandon(ChangeControl control,
java.lang.String msgTxt) |
Change |
abandon(ChangeControl control,
java.lang.String msgTxt,
NotifyHandling notifyHandling,
com.google.common.collect.ListMultimap<RecipientType,Account.Id> accountsToNotify) |
ChangeInfo |
apply(ChangeResource req,
AbandonInput input)
Process the view operation by altering the resource.
|
void |
batchAbandon(Project.NameKey project,
CurrentUser user,
java.util.Collection<ChangeControl> controls) |
void |
batchAbandon(Project.NameKey project,
CurrentUser user,
java.util.Collection<ChangeControl> controls,
java.lang.String msgTxt) |
void |
batchAbandon(Project.NameKey project,
CurrentUser user,
java.util.Collection<ChangeControl> controls,
java.lang.String msgTxt,
NotifyHandling notifyHandling,
com.google.common.collect.ListMultimap<RecipientType,Account.Id> accountsToNotify)
If an extension has more than one changes to abandon that belong to the same project, they
should use the batch instead of abandoning one by one.
|
UiAction.Description |
getDescription(ChangeResource resource)
Get the description of the action customized for the resource.
|
public ChangeInfo apply(ChangeResource req, AbandonInput input) throws RestApiException, UpdateException, com.google.gwtorm.server.OrmException
RestModifyView
apply
in interface RestModifyView<ChangeResource,AbandonInput>
req
- resource to modify.input
- input after parsing from request.BinaryResult
to avoid automatic conversion
to JSON.AuthException
- the client is not permitted to access this view.BadRequestException
- the request was incorrectly specified and cannot be handled by this
view.ResourceConflictException
- the resource state does not permit this view to make the
changes at this time.RestApiException
UpdateException
com.google.gwtorm.server.OrmException
public Change abandon(ChangeControl control) throws RestApiException, UpdateException
RestApiException
UpdateException
public Change abandon(ChangeControl control, java.lang.String msgTxt) throws RestApiException, UpdateException
RestApiException
UpdateException
public Change abandon(ChangeControl control, java.lang.String msgTxt, NotifyHandling notifyHandling, com.google.common.collect.ListMultimap<RecipientType,Account.Id> accountsToNotify) throws RestApiException, UpdateException
RestApiException
UpdateException
public void batchAbandon(Project.NameKey project, CurrentUser user, java.util.Collection<ChangeControl> controls, java.lang.String msgTxt, NotifyHandling notifyHandling, com.google.common.collect.ListMultimap<RecipientType,Account.Id> accountsToNotify) throws RestApiException, UpdateException
It's the caller's responsibility to ensure that all jobs inside the same batch have the matching project from its ChangeControl. Violations will result in a ResourceConflictException.
RestApiException
UpdateException
public void batchAbandon(Project.NameKey project, CurrentUser user, java.util.Collection<ChangeControl> controls, java.lang.String msgTxt) throws RestApiException, UpdateException
RestApiException
UpdateException
public void batchAbandon(Project.NameKey project, CurrentUser user, java.util.Collection<ChangeControl> controls) throws RestApiException, UpdateException
RestApiException
UpdateException
public UiAction.Description getDescription(ChangeResource resource)
UiAction
getDescription
in interface UiAction<ChangeResource>
resource
- the resource the view would act upon if the action is invoked by the client.
Information from the resource can be used to customize the description.id
and method
properties. If null the action will assumed unavailable and not presented. This is usually
the same as setVisible(false)
.