@@ -31,11 +31,13 @@ func (gc GetCapabilitiesResponse) ToXML() []byte {
3131
3232// GetCapabilitiesResponse base struct
3333type GetCapabilitiesResponse struct {
34- XMLName xml.Name `xml:"wcs:Capabilities"`
35- Namespaces `yaml:"namespaces"`
36- ServiceIdentification ServiceIdentification `xml:"ows:ServiceIdentification" yaml:"serviceidentification"`
37- ServiceProvider ServiceProvider `xml:"ows:ServiceProvider" yaml:"serviceprovider"`
38- Capabilities
34+ XMLName xml.Name `xml:"wcs:Capabilities" yaml:"wcsCapabilities"`
35+ Namespaces
36+ ServiceIdentification ServiceIdentification `xml:"ows:ServiceIdentification" yaml:"serviceIdentification"`
37+ ServiceProvider ServiceProvider `xml:"ows:ServiceProvider" yaml:"serviceProvider"`
38+ OperationsMetadata OperationsMetadata `xml:"ows:OperationsMetadata" yaml:"operationsMetadata"`
39+ ServiceMetadata ServiceMetadata `xml:"wcs:ServiceMetadata" yaml:"serviceMetadata"`
40+ Contents Contents `xml:"wcs:Contents" yaml:"contents"`
3941}
4042
4143// Namespaces struct containing the namespaces needed for the XML document
@@ -48,59 +50,80 @@ type Namespaces struct {
4850 XmlnsGML string `xml:"xmlns:gml,attr" yaml:"gml"` //http://www.opengis.net/gml/3.2
4951 XmlnsGMLcov string `xml:"xmlns:gmlcov,attr" yaml:"gmlcov"` //http://www.opengis.net/gmlcov/1.0
5052 XmlnsSWE string `xml:"xmlns:swe,attr" yaml:"swe"` //http://www.opengis.net/swe/2.0
51- XmlnsInspireCommon string `xml:"xmlns:inspire_common,attr,omitempty" yaml:"inspirecommon "` //http://inspire.ec.europa.eu/schemas/common/1.0
52- XmlnsInspireDls string `xml:"xmlns:inspire_dls,attr,omitempty" yaml:"inspiredls "` //http://inspire.ec.europa.eu/schemas/inspire_dls/1.0
53+ XmlnsInspireCommon string `xml:"xmlns:inspire_common,attr,omitempty" yaml:"inspireCommon "` //http://inspire.ec.europa.eu/schemas/common/1.0
54+ XmlnsInspireDls string `xml:"xmlns:inspire_dls,attr,omitempty" yaml:"inspireDls "` //http://inspire.ec.europa.eu/schemas/inspire_dls/1.0
5355 XmlnsCrs string `xml:"xmlns:crs,attr" yaml:"crs"` //http://www.opengis.net/wcs/crs/1.0
5456 XmlnsInt string `xml:"xmlns:int,attr" yaml:"int"` //http://www.opengis.net/wcs/interpolation/1.0
5557 Version string `xml:"version,attr" yaml:"version"`
56- SchemaLocation string `xml:"xsi:schemaLocation,attr" yaml:"schemalocation "`
58+ SchemaLocation string `xml:"xsi:schemaLocation,attr" yaml:"schemaLocation "`
5759}
5860
5961// ServiceIdentification struct should only be fill by the "template" configuration wcs201.yaml
6062type ServiceIdentification struct {
61- Title string `xml:"ows:Title" yaml:"title"`
62- Abstract string `xml:"ows:Abstract" yaml:"abstract"`
63- Keywords * wsc200.Keywords `xml:"ows:Keywords" yaml:"keywords"`
64- ServiceType struct {
65- Text string `xml:",chardata" yaml:"text"`
66- CodeSpace string `xml:"codeSpace,attr" yaml:"codespace"`
67- } `xml:"ows:ServiceType" yaml:"servicetype"`
68- ServiceTypeVersion []string `xml:"ows:ServiceTypeVersion" yaml:"servicetypeversion"`
69- Profile []string `xml:"ows:Profile" yaml:"profile"`
70- Fees string `xml:"ows:Fees" yaml:"fees"`
71- AccessConstraints string `xml:"ows:AccessConstraints" yaml:"accessconstraints"`
63+ Title string `xml:"ows:Title" yaml:"title"`
64+ Abstract string `xml:"ows:Abstract" yaml:"abstract"`
65+ Keywords * wsc200.Keywords `xml:"ows:Keywords" yaml:"keywords"`
66+ ServiceType ServiceType `xml:"ows:ServiceType" yaml:"serviceType"`
67+ ServiceTypeVersion []string `xml:"ows:ServiceTypeVersion" yaml:"serviceTypeVersion"`
68+ Profile []string `xml:"ows:Profile" yaml:"profile"`
69+ Fees string `xml:"ows:Fees" yaml:"fees"`
70+ AccessConstraints string `xml:"ows:AccessConstraints" yaml:"accessConstraints"`
71+ }
72+
73+ // ServiceType struct containing the service type
74+ type ServiceType struct {
75+ Text string `xml:",chardata" yaml:"text"`
76+ CodeSpace string `xml:"codeSpace,attr" yaml:"codeSpace"`
7277}
7378
7479// ServiceProvider struct containing the provider/organization information should only be fill by the "template" configuration wcs201.yaml
7580type ServiceProvider struct {
76- ProviderName string `xml:"ows:ProviderName" yaml:"providername"`
77- ProviderSite struct {
78- Type string `xml:"xlink:type,attr" yaml:"type"`
79- Href string `xml:"xlink:href,attr" yaml:"href"`
80- } `xml:"ows:ProviderSite" yaml:"providersite"`
81- ServiceContact struct {
82- IndividualName string `xml:"ows:IndividualName" yaml:"individualname"`
83- PositionName string `xml:"ows:PositionName" yaml:"positionname"`
84- ContactInfo struct {
85- Phone struct {
86- Voice string `xml:"ows:Voice" yaml:"voice"`
87- Facsimile string `xml:"ows:Facsimile" yaml:"facsimile"`
88- } `xml:"ows:Phone" yaml:"phone"`
89- Address struct {
90- DeliveryPoint string `xml:"ows:DeliveryPoint" yaml:"deliverypoint"`
91- City string `xml:"ows:City" yaml:"city"`
92- AdministrativeArea string `xml:"ows:AdministrativeArea" yaml:"administrativearea"`
93- PostalCode string `xml:"ows:PostalCode" yaml:"postalcode"`
94- Country string `xml:"ows:Country" yaml:"country"`
95- ElectronicMailAddress string `xml:"ows:ElectronicMailAddress" yaml:"electronicmailaddress"`
96- } `xml:"ows:Address" yaml:"address"`
97- OnlineResource * struct {
98- Type string `xml:"xlink:type,attr,omitempty" yaml:"type"`
99- Href string `xml:"xlink:href,attr,omitempty" yaml:"href"`
100- } `xml:"ows:OnlineResource,omitempty" yaml:"onlineresource"`
101- HoursOfService string `xml:"ows:HoursOfService,omitempty" yaml:"hoursofservice"`
102- ContactInstructions string `xml:"ows:ContactInstructions,omitempty" yaml:"contactinstructions"`
103- } `xml:"ows:ContactInfo" yaml:"contactinfo"`
104- Role string `xml:"ows:Role,omitempty" yaml:"role"`
105- } `xml:"ows:ServiceContact" yaml:"servicecontact"`
81+ ProviderName string `xml:"ows:ProviderName" yaml:"providerName"`
82+ ProviderSite `xml:"ows:ProviderSite" yaml:"providerSite"`
83+ ServiceContact ServiceContact `xml:"ows:ServiceContact" yaml:"serviceContact"`
84+ }
85+
86+ // ProviderSite struct containing the website of the provider/organization
87+ type ProviderSite struct {
88+ Type string `xml:"xlink:type,attr" yaml:"type"`
89+ Href string `xml:"xlink:href,attr" yaml:"href"`
90+ }
91+
92+ // ServiceContact struct containing information for the person to contact
93+ type ServiceContact struct {
94+ IndividualName string `xml:"ows:IndividualName" yaml:"individualName"`
95+ PositionName string `xml:"ows:PositionName" yaml:"positionName"`
96+ ContactInfo ContactInfo `xml:"ows:ContactInfo" yaml:"contactInfo"`
97+ Role string `xml:"ows:Role,omitempty" yaml:"role"`
98+ }
99+
100+ // ContactInfo struct containing the contact information for the service
101+ type ContactInfo struct {
102+ Phone Phone `xml:"ows:Phone" yaml:"phone"`
103+ Address Address `xml:"ows:Address" yaml:"address"`
104+ OnlineResource * OnlineResource `xml:"ows:OnlineResource,omitempty" yaml:"onlineResource"`
105+ HoursOfService string `xml:"ows:HoursOfService,omitempty" yaml:"hoursOfService"`
106+ ContactInstructions string `xml:"ows:ContactInstructions,omitempty" yaml:"contactInstructions"`
107+ }
108+
109+ // Phone struct containing the contact telephone or fax number
110+ type Phone struct {
111+ Voice string `xml:"ows:Voice" yaml:"voice"`
112+ Facsimile string `xml:"ows:Facsimile" yaml:"facsimile"`
113+ }
114+
115+ // Address struct containing the address for the contact supplying the service
116+ type Address struct {
117+ DeliveryPoint string `xml:"ows:DeliveryPoint" yaml:"deliveryPoint"`
118+ City string `xml:"ows:City" yaml:"city"`
119+ AdministrativeArea string `xml:"ows:AdministrativeArea" yaml:"administrativeArea"`
120+ PostalCode string `xml:"ows:PostalCode" yaml:"postalCode"`
121+ Country string `xml:"ows:Country" yaml:"country"`
122+ ElectronicMailAddress string `xml:"ows:ElectronicMailAddress" yaml:"electronicMailAddress"`
123+ }
124+
125+ // OnlineResource struct containing the top-level web address of a service or service provider
126+ type OnlineResource * struct {
127+ Type string `xml:"xlink:type,attr,omitempty" yaml:"type"`
128+ Href string `xml:"xlink:href,attr,omitempty" yaml:"href"`
106129}
0 commit comments