b30455156c44a54c516e9550fc99d80454f46446
[sdc.git] /
1 /*
2  * Copyright © 2016-2017 European Support Limited
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 package org.openecomp.sdc.vendorsoftwareproduct.errors;
18
19 import org.openecomp.sdc.common.errors.ErrorCategory;
20 import org.openecomp.sdc.common.errors.ErrorCode;
21
22 import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes.VSP_INVALID_ONBOARDING_METHOD;
23
24 /**
25  * The type Onboarding method error builder.
26  */
27 public class OnboardingMethodErrorBuilder {
28
29   private static final String VSP_INVALID_ONBOARDING_METHOD_MSG =
30       "The onboardingMethod value doesn't meet the expected attribute value.";
31
32   private OnboardingMethodErrorBuilder() {
33     
34   }
35
36   /**
37    * Get invalid onboarding method error builder error code.
38    *
39    * @return the error code
40    */
41   public static ErrorCode getInvalidOnboardingMethodErrorBuilder() {
42     ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder();
43     builder.withId(VSP_INVALID_ONBOARDING_METHOD);
44     builder.withCategory(ErrorCategory.APPLICATION);
45     builder.withMessage(VSP_INVALID_ONBOARDING_METHOD_MSG);
46     return builder.build();
47   }
48 }