2 * Copyright © 2017-2018 AT&T Intellectual Property.
\r
4 * Licensed under the Apache License, Version 2.0 (the "License");
\r
5 * you may not use this file except in compliance with the License.
\r
6 * You may obtain a copy of the License at
\r
8 * http://www.apache.org/licenses/LICENSE-2.0
\r
10 * Unless required by applicable law or agreed to in writing, software
\r
11 * distributed under the License is distributed on an "AS IS" BASIS,
\r
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
13 * See the License for the specific language governing permissions and
\r
14 * limitations under the License.
\r
17 package org.onap.ccsdk.apps.blueprintsprocessor.core.api.data
\r
19 import com.fasterxml.jackson.annotation.JsonFormat
\r
20 import com.fasterxml.jackson.databind.node.ObjectNode
\r
21 import io.swagger.annotations.ApiModelProperty
\r
22 import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceAssignment
\r
25 * Copyright © 2017-2018 AT&T Intellectual Property.
\r
27 * Licensed under the Apache License, Version 2.0 (the "License");
\r
28 * you may not use this file except in compliance with the License.
\r
29 * You may obtain a copy of the License at
\r
31 * http://www.apache.org/licenses/LICENSE-2.0
\r
33 * Unless required by applicable law or agreed to in writing, software
\r
34 * distributed under the License is distributed on an "AS IS" BASIS,
\r
35 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
36 * See the License for the specific language governing permissions and
\r
37 * limitations under the License.
\r
41 * BlueprintProcessorData
\r
42 * @author Brinda Santh
\r
46 open class ResourceResolutionInput {
\r
47 @get:ApiModelProperty(required=true)
\r
48 lateinit var commonHeader: CommonHeader
\r
49 @get:ApiModelProperty(required=true)
\r
50 lateinit var actionIdentifiers: ActionIdentifiers
\r
51 @get:ApiModelProperty(required=true)
\r
52 lateinit var resourceAssignments: List<ResourceAssignment>
\r
53 @get:ApiModelProperty(required=true )
\r
54 lateinit var payload: ObjectNode
\r
57 open class ResourceResolutionOutput {
\r
58 @get:ApiModelProperty(required=true)
\r
59 lateinit var commonHeader: CommonHeader
\r
60 @get:ApiModelProperty(required=true)
\r
61 lateinit var actionIdentifiers: ActionIdentifiers
\r
62 @get:ApiModelProperty(required=true)
\r
63 lateinit var status: Status
\r
64 @get:ApiModelProperty(required=true)
\r
65 lateinit var resourceAssignments: List<ResourceAssignment>
\r
68 open class ExecutionServiceInput {
\r
69 @get:ApiModelProperty(required=true)
\r
70 lateinit var commonHeader: CommonHeader
\r
71 @get:ApiModelProperty(required=true)
\r
72 lateinit var actionIdentifiers: ActionIdentifiers
\r
73 @get:ApiModelProperty(required=true)
\r
74 lateinit var payload: ObjectNode
\r
77 open class ExecutionServiceOutput {
\r
78 @get:ApiModelProperty(required=true)
\r
79 lateinit var commonHeader: CommonHeader
\r
80 @get:ApiModelProperty(required=true)
\r
81 lateinit var actionIdentifiers: ActionIdentifiers
\r
82 @get:ApiModelProperty(required=true)
\r
83 lateinit var status: Status
\r
84 @get:ApiModelProperty(required=true)
\r
85 lateinit var payload: ObjectNode
\r
88 open class ActionIdentifiers {
\r
89 @get:ApiModelProperty(required=false)
\r
90 lateinit var blueprintName: String
\r
91 @get:ApiModelProperty(required=false)
\r
92 lateinit var blueprintVersion: String
\r
93 @get:ApiModelProperty(required=true)
\r
94 lateinit var actionName: String
\r
95 @get:ApiModelProperty(required=true, allowableValues = "sync, async")
\r
96 lateinit var mode: String
\r
99 open class CommonHeader {
\r
100 @get:ApiModelProperty(required=true, example = "2012-04-23T18:25:43.511Z")
\r
101 @get:JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd'T'HH:mm:ss.SSS'Z'")
\r
102 lateinit var timestamp: String
\r
103 @get:ApiModelProperty(required=true)
\r
104 lateinit var originatorId: String
\r
105 @get:ApiModelProperty(required=true)
\r
106 lateinit var requestId: String
\r
107 @get:ApiModelProperty(required=true)
\r
108 lateinit var subRequestId: String
\r
109 @get:ApiModelProperty(required=false)
\r
110 var flags: Flags? = null
\r
114 var isForce: Boolean = false
\r
115 @get:ApiModelProperty(value = "3600")
\r
116 var ttl: Int = 3600
\r
119 open class Status {
\r
120 @get:ApiModelProperty(required=true)
\r
121 var code: Int = 200
\r
122 @get:ApiModelProperty(required=false)
\r
123 var errorMessage: String? = null
\r
124 @get:ApiModelProperty(required=true)
\r
125 lateinit var message: String
\r