First part of onap rename
[appc.git] / appc-sequence-generator / appc-sequence-generator-bundle / src / main / java / org / openecomp / appc / seqgen / objects / RequestInfoBuilder.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP : APP-C
4  * ================================================================================
5  * Copyright (C) 2017 AT&T Intellectual Property.  All rights reserved.
6  * ================================================================================
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  * 
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  * 
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  * ============LICENSE_END=========================================================
19  */
20
21 package org.onap.appc.seqgen.objects;
22
23 public class RequestInfoBuilder {
24
25     private String action;
26
27     private String actionLevel;
28
29     private ActionIdentifier actionIdentifier;
30
31     private String payload;
32
33     public RequestInfoBuilder actionIdentifier(){
34         this.actionIdentifier = new ActionIdentifier();
35         return this;
36     }
37
38     public RequestInfoBuilder vnfId(String vnfId){
39         this.actionIdentifier.setVnfId(vnfId);
40         return this;
41     }
42
43     public RequestInfoBuilder vnfcName(String vnfcName){
44         this.actionIdentifier.setVnfcName(vnfcName);
45         return this;
46     }
47
48     public RequestInfoBuilder vServerId(String vServerId){
49         this.actionIdentifier.setvServerId(vServerId);
50         return this;
51     }
52
53     public RequestInfoBuilder action(String action){
54         this.action = action;
55         return this;
56     }
57
58     public RequestInfoBuilder actionLevel(String actionLevel){
59         this.actionLevel = actionLevel;
60         return this;
61     }
62
63     public RequestInfoBuilder payload(String payload){
64         this.payload = payload;
65         return this;
66     }
67
68     public RequestInfo build(){
69         RequestInfo requestInfo = new RequestInfo();
70         requestInfo.setAction(this.action);
71         requestInfo.setActionIdentifier(this.actionIdentifier);
72         requestInfo.setActionLevel(this.actionLevel);
73         requestInfo.setPayload(this.payload);
74         return requestInfo;
75     }
76 }