brought back the body of the validate() methods. This is still useful if no setter has been invoked.
This commit is contained in:
parent
b0c7096e2f
commit
faf9ca2122
|
@ -46,7 +46,11 @@ public class GetPipelineRequest extends MasterNodeReadRequest<GetPipelineRequest
|
|||
|
||||
@Override
|
||||
public ActionRequestValidationException validate() {
|
||||
return null;
|
||||
ActionRequestValidationException validationException = null;
|
||||
if (ids == null) {
|
||||
validationException = addValidationError("ids is missing", validationException);
|
||||
}
|
||||
return validationException;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -37,7 +37,14 @@ public class PutPipelineRequest extends AcknowledgedRequest<PutPipelineRequest>
|
|||
|
||||
@Override
|
||||
public ActionRequestValidationException validate() {
|
||||
return null;
|
||||
ActionRequestValidationException validationException = null;
|
||||
if (id == null) {
|
||||
validationException = addValidationError("id is missing", validationException);
|
||||
}
|
||||
if (source == null) {
|
||||
validationException = addValidationError("source is missing", validationException);
|
||||
}
|
||||
return validationException;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
|
|
Loading…
Reference in New Issue