2 * ============LICENSE_START=======================================================
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
11 * http://www.apache.org/licenses/LICENSE-2.0
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=========================================================
21 package org.onap.so.bpmn.common.adapter.sdnc;
23 import java.io.StringWriter;
24 import javax.xml.bind.JAXBContext;
25 import javax.xml.bind.JAXBException;
26 import javax.xml.bind.Marshaller;
27 import javax.xml.bind.annotation.XmlAccessType;
28 import javax.xml.bind.annotation.XmlAccessorType;
29 import javax.xml.bind.annotation.XmlElement;
30 import javax.xml.bind.annotation.XmlRootElement;
31 import javax.xml.bind.annotation.XmlType;
36 * Java class for anonymous complex type.
39 * The following schema fragment specifies the expected content contained within this class.
44 * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
46 * <element ref="{http://org.onap/workflow/sdnc/adapter/schema/v1}CallbackHeader"/>
47 * <element name="RequestData" type="{http://www.w3.org/2001/XMLSchema}anyType" minOccurs="0"/>
50 * </complexContent>
56 @XmlAccessorType(XmlAccessType.FIELD)
57 @XmlType(name = "", namespace = "http://org.onap/workflow/sdnc/adapter/schema/v1",
58 propOrder = {"callbackHeader", "requestData"})
59 @XmlRootElement(name = "SDNCAdapterCallbackRequest", namespace = "http://org.onap/workflow/sdnc/adapter/schema/v1")
60 public class SDNCAdapterCallbackRequest {
62 @XmlElement(name = "CallbackHeader", required = true, namespace = "http://org.onap/workflow/sdnc/adapter/schema/v1")
63 protected CallbackHeader callbackHeader;
64 @XmlElement(name = "RequestData", required = false, namespace = "http://org.onap/workflow/sdnc/adapter/schema/v1")
65 protected Object requestData;
68 * Gets the value of the callbackHeader property.
70 * @return possible object is {@link CallbackHeader }
73 public CallbackHeader getCallbackHeader() {
74 return callbackHeader;
78 * Sets the value of the callbackHeader property.
80 * @param value allowed object is {@link CallbackHeader }
83 public void setCallbackHeader(CallbackHeader value) {
84 this.callbackHeader = value;
88 * Gets the value of the requestData property.
90 * @return possible object is {@link Object }
93 public Object getRequestData() {
98 * Sets the value of the requestData property.
100 * @param value allowed object is {@link Object }
103 public void setRequestData(Object value) {
104 this.requestData = value;
108 public String toString() {
109 StringWriter writer = new StringWriter();
111 JAXBContext context = JAXBContext.newInstance(SDNCAdapterCallbackRequest.class);
112 Marshaller m = context.createMarshaller();
113 m.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE);
114 m.marshal(this, writer);
115 return writer.getBuffer().toString();
116 } catch (JAXBException e) {