Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
VOSpace INAF
vospace-datamodel
Commits
71e8d1d3
Commit
71e8d1d3
authored
Dec 14, 2020
by
Sonia Zorba
Browse files
Simplified JAXB classes structure (removed wrapper list classes)
parent
5c1a2fc1
Pipeline
#731
failed with stages
in 27 seconds
Changes
12
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/net/ivoa/xml/vospace/v2/CapabilityList.java
deleted
100644 → 0
View file @
5c1a2fc1
//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2020.10.24 at 09:39:16 AM CEST
//
package
net.ivoa.xml.vospace.v2
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlElement
;
import
javax.xml.bind.annotation.XmlType
;
/**
*
* A container element for a list of capabilities.
*
*
* <p>Java class for CapabilityList complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType name="CapabilityList">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="capability" type="{http://www.ivoa.net/xml/VOSpace/v2.0}Capability" maxOccurs="unbounded" minOccurs="0"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType
(
XmlAccessType
.
FIELD
)
@XmlType
(
name
=
"CapabilityList"
,
propOrder
=
{
"capability"
})
public
class
CapabilityList
{
@XmlElement
(
nillable
=
true
)
protected
List
<
Capability
>
capability
;
/**
* Gets the value of the capability property.
*
* <p>
* This accessor method returns a reference to the live list,
* not a snapshot. Therefore any modification you make to the
* returned list will be present inside the JAXB object.
* This is why there is not a <CODE>set</CODE> method for the capability property.
*
* <p>
* For example, to add a new item, do as follows:
* <pre>
* getCapability().add(newItem);
* </pre>
*
*
* <p>
* Objects of the following type(s) are allowed in the list
* {@link Capability }
*
*
*/
public
List
<
Capability
>
getCapability
()
{
if
(
capability
==
null
)
{
capability
=
new
ArrayList
<
Capability
>();
}
return
this
.
capability
;
}
}
src/main/java/net/ivoa/xml/vospace/v2/DataNode.java
View file @
71e8d1d3
...
...
@@ -8,9 +8,13 @@
package
net.ivoa.xml.vospace.v2
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlAttribute
;
import
javax.xml.bind.annotation.XmlElement
;
import
javax.xml.bind.annotation.XmlElementWrapper
;
import
javax.xml.bind.annotation.XmlRootElement
;
import
javax.xml.bind.annotation.XmlSeeAlso
;
import
javax.xml.bind.annotation.XmlType
;
...
...
@@ -60,83 +64,58 @@ public class DataNode
extends
Node
{
protected
ViewList
accepts
;
protected
ViewList
provides
;
protected
CapabilityList
capabilities
;
// <edit>: ViewList replaced with List<View>
@XmlElement
(
name
=
"view"
)
@XmlElementWrapper
(
name
=
"accepts"
)
protected
List
<
View
>
accepts
;
@XmlElement
(
name
=
"view"
)
@XmlElementWrapper
(
name
=
"provides"
)
protected
List
<
View
>
provides
;
// CapabilityList replaced with List<Capability>
@XmlElement
(
name
=
"capability"
)
@XmlElementWrapper
(
name
=
"capabilities"
)
protected
List
<
Capability
>
capabilities
;
// </edit>
@XmlAttribute
(
name
=
"busy"
)
protected
Boolean
busy
;
/**
* Gets the value of the accepts property.
*
* @return
* possible object is
* {@link ViewList }
*
*/
public
ViewList
getAccepts
()
{
// <edit>
public
List
<
View
>
getAccepts
()
{
if
(
accepts
==
null
)
{
accepts
=
new
ArrayList
<>();
}
return
accepts
;
}
/**
* Sets the value of the accepts property.
*
* @param value
* allowed object is
* {@link ViewList }
*
*/
public
void
setAccepts
(
ViewList
value
)
{
public
void
setAccepts
(
List
<
View
>
value
)
{
this
.
accepts
=
value
;
}
/**
* Gets the value of the provides property.
*
* @return
* possible object is
* {@link ViewList }
*
*/
public
ViewList
getProvides
()
{
public
List
<
View
>
getProvides
()
{
if
(
provides
==
null
)
{
provides
=
new
ArrayList
<>();
}
return
provides
;
}
/**
* Sets the value of the provides property.
*
* @param value
* allowed object is
* {@link ViewList }
*
*/
public
void
setProvides
(
ViewList
value
)
{
public
void
setProvides
(
List
<
View
>
value
)
{
this
.
provides
=
value
;
}
/**
* Gets the value of the capabilities property.
*
* @return
* possible object is
* {@link CapabilityList }
*
*/
public
CapabilityList
getCapabilities
()
{
public
List
<
Capability
>
getCapabilities
()
{
if
(
capabilities
==
null
)
{
capabilities
=
new
ArrayList
<>();
}
return
capabilities
;
}
/**
* Sets the value of the capabilities property.
*
* @param value
* allowed object is
* {@link CapabilityList }
*
*/
public
void
setCapabilities
(
CapabilityList
value
)
{
public
void
setCapabilities
(
List
<
Capability
>
value
)
{
this
.
capabilities
=
value
;
}
// </edit>
/**
* Gets the value of the busy property.
...
...
src/main/java/net/ivoa/xml/vospace/v2/GetPropertiesResponse.java
View file @
71e8d1d3
...
...
@@ -8,9 +8,12 @@
package
net.ivoa.xml.vospace.v2
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlElement
;
import
javax.xml.bind.annotation.XmlElementWrapper
;
import
javax.xml.bind.annotation.XmlType
;
...
...
@@ -43,83 +46,50 @@ import javax.xml.bind.annotation.XmlType;
})
public
class
GetPropertiesResponse
{
@XmlElement
(
required
=
true
)
protected
PropertyReferenceList
accepts
;
@XmlElement
(
required
=
true
)
protected
PropertyReferenceList
provides
;
@XmlElement
(
required
=
true
)
protected
PropertyReferenceList
contains
;
// <edit>: PropertyReferenceList replaced with List<PropertyReference>
@XmlElement
(
name
=
"property"
)
@XmlElementWrapper
(
name
=
"accepts"
,
required
=
true
)
protected
List
<
PropertyReference
>
accepts
;
@XmlElement
(
name
=
"property"
)
@XmlElementWrapper
(
name
=
"provides"
,
required
=
true
)
protected
List
<
PropertyReference
>
provides
;
/**
* Gets the value of the accepts property.
*
* @return
* possible object is
* {@link PropertyReferenceList }
*
*/
public
PropertyReferenceList
getAccepts
()
{
@XmlElement
(
name
=
"property"
)
@XmlElementWrapper
(
name
=
"contains"
,
required
=
true
)
protected
List
<
PropertyReference
>
contains
;
public
List
<
PropertyReference
>
getAccepts
()
{
if
(
accepts
==
null
)
{
accepts
=
new
ArrayList
<>();
}
return
accepts
;
}
/**
* Sets the value of the accepts property.
*
* @param value
* allowed object is
* {@link PropertyReferenceList }
*
*/
public
void
setAccepts
(
PropertyReferenceList
value
)
{
public
void
setAccepts
(
List
<
PropertyReference
>
value
)
{
this
.
accepts
=
value
;
}
/**
* Gets the value of the provides property.
*
* @return
* possible object is
* {@link PropertyReferenceList }
*
*/
public
PropertyReferenceList
getProvides
()
{
public
List
<
PropertyReference
>
getProvides
()
{
if
(
provides
==
null
)
{
provides
=
new
ArrayList
<>();
}
return
provides
;
}
/**
* Sets the value of the provides property.
*
* @param value
* allowed object is
* {@link PropertyReferenceList }
*
*/
public
void
setProvides
(
PropertyReferenceList
value
)
{
public
void
setProvides
(
List
<
PropertyReference
>
value
)
{
this
.
provides
=
value
;
}
/**
* Gets the value of the contains property.
*
* @return
* possible object is
* {@link PropertyReferenceList }
*
*/
public
PropertyReferenceList
getContains
()
{
public
List
<
PropertyReference
>
getContains
()
{
if
(
contains
==
null
)
{
contains
=
new
ArrayList
<>();
}
return
contains
;
}
/**
* Sets the value of the contains property.
*
* @param value
* allowed object is
* {@link PropertyReferenceList }
*
*/
public
void
setContains
(
PropertyReferenceList
value
)
{
public
void
setContains
(
List
<
PropertyReference
>
value
)
{
this
.
contains
=
value
;
}
// </edit>
}
src/main/java/net/ivoa/xml/vospace/v2/GetProtocolsResponse.java
View file @
71e8d1d3
...
...
@@ -8,9 +8,11 @@
package
net.ivoa.xml.vospace.v2
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlElement
;
import
javax.xml.bind.annotation.XmlElementWrapper
;
import
javax.xml.bind.annotation.XmlType
;
...
...
@@ -41,57 +43,29 @@ import javax.xml.bind.annotation.XmlType;
})
public
class
GetProtocolsResponse
{
@XmlElement
(
required
=
true
)
protected
ProtocolList
accepts
;
@XmlElement
(
required
=
true
)
protected
ProtocolList
provides
;
// <edit>: ProtocolList replaced with List<Protocol>
@XmlElement
(
name
=
"protocol"
)
@XmlElementWrapper
(
name
=
"accepts"
,
required
=
true
)
protected
List
<
Protocol
>
accepts
;
@XmlElement
(
name
=
"protocol"
)
@XmlElementWrapper
(
name
=
"provides"
,
required
=
true
)
protected
List
<
Protocol
>
provides
;
/**
* Gets the value of the accepts property.
*
* @return
* possible object is
* {@link ProtocolList }
*
*/
public
ProtocolList
getAccepts
()
{
public
List
<
Protocol
>
getAccepts
()
{
return
accepts
;
}
/**
* Sets the value of the accepts property.
*
* @param value
* allowed object is
* {@link ProtocolList }
*
*/
public
void
setAccepts
(
ProtocolList
value
)
{
public
void
setAccepts
(
List
<
Protocol
>
value
)
{
this
.
accepts
=
value
;
}
/**
* Gets the value of the provides property.
*
* @return
* possible object is
* {@link ProtocolList }
*
*/
public
ProtocolList
getProvides
()
{
public
List
<
Protocol
>
getProvides
()
{
return
provides
;
}
/**
* Sets the value of the provides property.
*
* @param value
* allowed object is
* {@link ProtocolList }
*
*/
public
void
setProvides
(
ProtocolList
value
)
{
public
void
setProvides
(
List
<
Protocol
>
value
)
{
this
.
provides
=
value
;
}
// </edit>
}
src/main/java/net/ivoa/xml/vospace/v2/GetViewsResponse.java
View file @
71e8d1d3
...
...
@@ -8,9 +8,12 @@
package
net.ivoa.xml.vospace.v2
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlElement
;
import
javax.xml.bind.annotation.XmlElementWrapper
;
import
javax.xml.bind.annotation.XmlType
;
...
...
@@ -41,57 +44,35 @@ import javax.xml.bind.annotation.XmlType;
})
public
class
GetViewsResponse
{
@XmlElement
(
required
=
true
)
protected
ViewList
accepts
;
@XmlElement
(
required
=
true
)
protected
ViewList
provide
s
;
// <edit>: ViewList replaced with List<View>
@XmlElement
(
name
=
"view"
)
@XmlElement
Wrapper
(
name
=
"accepts"
,
required
=
true
)
protected
List
<
View
>
accept
s
;
/**
* Gets the value of the accepts property.
*
* @return
* possible object is
* {@link ViewList }
*
*/
public
ViewList
getAccepts
()
{
@XmlElement
(
name
=
"view"
)
@XmlElementWrapper
(
name
=
"provides"
,
required
=
true
)
protected
List
<
View
>
provides
;
public
List
<
View
>
getAccepts
()
{
if
(
accepts
==
null
)
{
accepts
=
new
ArrayList
<>();
}
return
accepts
;
}
/**
* Sets the value of the accepts property.
*
* @param value
* allowed object is
* {@link ViewList }
*
*/
public
void
setAccepts
(
ViewList
value
)
{
public
void
setAccepts
(
List
<
View
>
value
)
{
this
.
accepts
=
value
;
}
/**
* Gets the value of the provides property.
*
* @return
* possible object is
* {@link ViewList }
*
*/
public
ViewList
getProvides
()
{
public
List
<
View
>
getProvides
()
{
return
provides
;
}
/**
* Sets the value of the provides property.
*
* @param value
* allowed object is
* {@link ViewList }
*
*/
public
void
setProvides
(
ViewList
value
)
{
public
void
setProvides
(
List
<
View
>
value
)
{
if
(
provides
==
null
)
{
provides
=
new
ArrayList
<>();
}
this
.
provides
=
value
;
}
// </edit>
}
src/main/java/net/ivoa/xml/vospace/v2/Node.java
View file @
71e8d1d3
...
...
@@ -10,9 +10,13 @@ import com.fasterxml.jackson.annotation.JsonProperty;
import
com.fasterxml.jackson.annotation.JsonTypeInfo
;
import
com.fasterxml.jackson.databind.annotation.JsonTypeIdResolver
;
import
it.inaf.oats.vospace.datamodel.NodeTypeJsonResolver
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlAttribute
;
import
javax.xml.bind.annotation.XmlElement
;
import
javax.xml.bind.annotation.XmlElementWrapper
;
import
javax.xml.bind.annotation.XmlSchemaType
;
import
javax.xml.bind.annotation.XmlSeeAlso
;
import
javax.xml.bind.annotation.XmlTransient
;
...
...
@@ -56,9 +60,10 @@ import javax.xml.bind.annotation.XmlType;
// </edit>
public
class
Node
{
protected
PropertyList
properties
;
// <edit>
// Auto-generated class defined a PropertyList wrapper class.
protected
List
<
Property
>
properties
;
// Used for generating missing type attribute for root node. For child nodes it is filled automatically.
@XmlAttribute
(
name
=
"type"
,
namespace
=
"http://www.w3.org/2001/XMLSchema-instance"
,
required
=
false
)
private
String
type
;
...
...
@@ -84,25 +89,20 @@ public class Node {
@XmlSchemaType
(
name
=
"anyURI"
)
protected
String
uri
;
/
**
* Gets the value of the properties
property
.
*
* @return possible object is {@link PropertyList }
*
*/
public
PropertyList
getProperties
()
{
/
/ <edit>
@XmlElement
(
name
=
"
property
"
)
@XmlElementWrapper
(
name
=
"properties"
,
required
=
false
)
public
List
<
Property
>
getProperties
()
{
if
(
properties
==
null
)
{
properties
=
new
ArrayList
<>();
}
return
properties
;
}
/**
* Sets the value of the properties property.
*
* @param value allowed object is {@link PropertyList }
*
*/
public
void
setProperties
(
PropertyList
value
)
{
public
void
setProperties
(
List
<
Property
>
value
)
{
this
.
properties
=
value
;
}
// </edit>
/**
* Gets the value of the uri property.
...
...
src/main/java/net/ivoa/xml/vospace/v2/NodeList.java
deleted
100644 → 0
View file @
5c1a2fc1
//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2020.10.24 at 09:39:16 AM CEST
//
package
net.ivoa.xml.vospace.v2
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
javax.xml.bind.annotation.XmlType
;
/**
*
* A container element for search responses.
*
*
* <p>Java class for NodeList complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.