fixing NullPointException incase of db exception
[policy/engine.git] / PolicyEngineAPI / src / main / java / org / onap / policy / api / DeletePolicyParameters.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * PolicyEngineAPI
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.policy.api;
22
23 import java.util.UUID;
24
25 /**
26  * <code>PushPolicyParameters</code> defines the Policy Parameters which are required to Push a
27  * Policy to PDPGroup.
28  * 
29  * @version 0.1
30  */
31 public class DeletePolicyParameters {
32
33     private String policyName;
34     private String policyType;
35     private String policyComponent;
36     private DeletePolicyCondition deleteCondition;
37     private String pdpGroup;
38     private UUID requestID;
39
40     /**
41      * @return the policyName
42      */
43     public String getPolicyName() {
44         return policyName;
45     }
46
47     /**
48      * @param policyName the policyName to set
49      */
50     public void setPolicyName(final String policyName) {
51         this.policyName = policyName;
52     }
53
54     /**
55      * @return the policyComponent
56      */
57     public String getPolicyComponent() {
58         return policyComponent;
59     }
60
61     /**
62      * @return the policyType
63      */
64     public String getPolicyType() {
65         return policyType;
66     }
67
68     /**
69      * @param policyType the policyType to set
70      */
71     public void setPolicyType(final String policyType) {
72         this.policyType = policyType;
73     }
74
75     /**
76      * @param policyComponent the policyComponent to set
77      */
78     public void setPolicyComponent(final String policyComponent) {
79         this.policyComponent = policyComponent;
80     }
81
82     /**
83      * @return the deleteCondition
84      */
85     public DeletePolicyCondition getDeleteCondition() {
86         return deleteCondition;
87     }
88
89     /**
90      * @param deleteCondition the deleteCondition to set
91      */
92     public void setDeleteCondition(final DeletePolicyCondition deleteCondition) {
93         this.deleteCondition = deleteCondition;
94     }
95
96     /**
97      * @return the requestID
98      */
99     public UUID getRequestID() {
100         return requestID;
101     }
102
103     /**
104      * @param requestID the requestID to set
105      */
106     public void setRequestID(final UUID requestID) {
107         this.requestID = requestID;
108     }
109
110     /**
111      * @return the pdpGroup
112      */
113     public String getPdpGroup() {
114         return pdpGroup;
115     }
116
117     /**
118      * @param pdpGroup the pdpGroup to set
119      */
120     public void setPdpGroup(final String pdpGroup) {
121         this.pdpGroup = pdpGroup;
122     }
123
124     @Override
125     public String toString() {
126         return "DeletePolicyParameters [policyName=" + policyName + ", policyType=" + policyType + ", policyComponent="
127                 + policyComponent + ", deleteCondition=" + deleteCondition + ", pdpGroup=" + pdpGroup + ", requestID="
128                 + requestID + "]";
129     }
130 }