Format ONAP-XACML and add JUnit
[policy/engine.git] / ONAP-XACML / src / main / java / org / onap / policy / xacml / api / pap / OnapPAPPolicy.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP-XACML
4  * ================================================================================
5  * Copyright (C) 2017, 2019 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.xacml.api.pap;
22
23 import com.fasterxml.jackson.annotation.JsonSubTypes;
24 import com.fasterxml.jackson.annotation.JsonSubTypes.Type;
25 import com.fasterxml.jackson.annotation.JsonTypeInfo;
26
27 import java.net.URI;
28 import java.util.List;
29 import java.util.Map;
30
31 import org.onap.policy.xacml.std.pap.StdPAPPolicy;
32
33 /*
34  * The following allows us to use Jackson to convert sub-types of this type into JSON and back to objects.
35  */
36 @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "PAPPolicyType")
37 @JsonSubTypes({@Type(value = StdPAPPolicy.class, name = "StdPAPPolicy")})
38 public interface OnapPAPPolicy {
39
40     public String getPolicyName();
41
42     public String getOldPolicyFileName();
43
44     public String getPolicyDescription();
45
46     public String getOnapName();
47
48     public String getConfigName();
49
50     public Map<String, String> getDynamicFieldConfigAttributes();
51
52     public Map<String, String> getTreatments();
53
54     public Map<String, String> getDynamicSettingsMap();
55
56     public List<String> getDynamicRuleAlgorithmLabels();
57
58     public List<String> getDynamicRuleAlgorithmCombo();
59
60     public List<String> getDynamicRuleAlgorithmField1();
61
62     public List<String> getDynamicRuleAlgorithmField2();
63
64     public List<Object> getDynamicVariableList();
65
66     public List<String> getDataTypeList();
67
68     public String getConfigBodyData();
69
70     public String getPolicyID();
71
72     public String getRuleID();
73
74     public String getConfigType();
75
76     public Boolean isEditPolicy();
77
78     public Boolean isDraft();
79
80     public String getVersion();
81
82     public String getDomainDir();
83
84     public String getConfigPolicyType();
85
86     public String getJsonBody();
87
88     public Integer getHighestVersion();
89
90     public URI getLocation();
91
92     public String getActionPerformer();
93
94     public String getActionAttribute();
95
96     public String getActionBody();
97
98     public Map<String, String> getDropDownMap();
99
100     public String getActionDictHeader();
101
102     public String getActionDictType();
103
104     public String getActionDictUrl();
105
106     public String getActionDictMethod();
107
108     public String getServiceType();
109
110     public String getUuid();
111
112     public String getMsLocation();
113
114     public String getPriority();
115
116     public String getDeleteCondition();
117
118     public String getDictionaryType();
119
120     public String getDictionary();
121
122     public String getDictionaryFields();
123
124     public String getRiskLevel();
125
126     public String getGuard();
127
128     public String getRiskType();
129
130     public String getTTLDate();
131 }