Make MergeConflictException a ResourceConflictException

This means we don't have to unwrap this exception type when used from
a BatchUpdate, since BatchUpdate propagates RestApiExceptions.

Change-Id: I3b655308ec22913bee0b9114074d192360466893
This commit is contained in:
Dave Borowitz
2015-10-28 15:48:07 -04:00
parent a7e5f122fa
commit f0112b9a74
7 changed files with 18 additions and 20 deletions

View File

@@ -0,0 +1,28 @@
// Copyright (C) 2014 The Android Open Source Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package com.google.gerrit.extensions.restapi;
/**
* Indicates that a commit cannot be merged without conflicts.
* <p>
* Messages should be viewable by end users.
*/
public class MergeConflictException extends ResourceConflictException {
private static final long serialVersionUID = 1L;
public MergeConflictException(String msg) {
super(msg, null);
}
}