<?xml version="1.0" encoding="utf-8"?>

<!--
    Copyright 2009 the original author or authors. Licensed under the Apache
    License, Version 2.0 (the "License"); you may not use this file except
    in compliance with the License. You may obtain a copy of the License at
    http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable
    law or agreed to in writing, software distributed under the License is
    distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    KIND, either express or implied. See the License for the specific
    language governing permissions and limitations under the License.
-->

<definitions
        xmlns="http://schemas.xmlsoap.org/wsdl/"
        xmlns:xsd="http://www.w3.org/2001/XMLSchema"
        xmlns:ihe="urn:ihe:iti:xds-b:2007"
        xmlns:lcm="urn:oasis:names:tc:ebxml-regrep:xsd:lcm:3.0"
        xmlns:rs="urn:oasis:names:tc:ebxml-regrep:xsd:rs:3.0"
        xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
        xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata"
        xmlns:medcom="http://www.medcom.dk/dgws/2006/04/dgws-1.0.xsd"
        xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
        xmlns:tns="urn:ihe:iti:xds-b:2007"
        targetNamespace="urn:ihe:iti:xds-b:2007"
        name="DocumentRegistry">

    <documentation>IHE XDS.b Document Registry = ITI-42 adaptor = Register Document Set.b</documentation>

    <types>
        <xsd:schema elementFormDefault="qualified">
            <xsd:import namespace="urn:oasis:names:tc:ebxml-regrep:xsd:rs:3.0" schemaLocation="https://test2-cnsp.ekstern-test.nspop.dk:8443/dros_aftaler/dgws-wsdl/schema/ebRS30/rs.xsd"/>
            <xsd:import namespace="urn:oasis:names:tc:ebxml-regrep:xsd:lcm:3.0" schemaLocation="https://test2-cnsp.ekstern-test.nspop.dk:8443/dros_aftaler/dgws-wsdl/schema/ebRS30/lcm.xsd"/>
            <xsd:import namespace="http://www.medcom.dk/dgws/2006/04/dgws-1.0.xsd" schemaLocation="https://test2-cnsp.ekstern-test.nspop.dk:8443/dros_aftaler/dgws-wsdl/schema/medcom.xsd"/>
            <xsd:import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" schemaLocation="https://test2-cnsp.ekstern-test.nspop.dk:8443/dros_aftaler/dgws-wsdl/schema/wsse.xsd"/>
        </xsd:schema>
    </types>

    <message name="MedcomHeader">
        <part name="MedcomHeader" element="medcom:Header"/>
    </message>
    <message name="SecurityHeader">
        <part name="SecurityHeader" element="wsse:Security"/>
    </message>
    <message name="DGWSFault">
        <part name="DGWSFault" element="medcom:FaultCode"/>
    </message>

    <message name="RegisterDocumentSet-b_Message">
        <documentation>Register Document Set - b</documentation>
        <part name="body" element="lcm:SubmitObjectsRequest"/>
    </message>

    <message name="RegisterDocumentSet-bResponse_Message">
        <documentation>Register Document Set - b Response</documentation>
        <part name="body" element="rs:RegistryResponse"/>
    </message>

    <portType name="DocumentRegistry_PortType">
        <operation name="DocumentRegistry_RegisterDocumentSet-b">
            <input message="ihe:RegisterDocumentSet-b_Message"
                   wsam:Action="urn:ihe:iti:2007:RegisterDocumentSet-b"/>
            <output message="ihe:RegisterDocumentSet-bResponse_Message"
                    wsam:Action="urn:ihe:iti:2007:RegisterDocumentSet-bResponse"/>
            <fault message="tns:DGWSFault" name="DGWSFault"/>
        </operation>
    </portType>

    <binding name="DocumentRegistry_Binding_Soap" type="ihe:DocumentRegistry_PortType">
        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
        <operation name="DocumentRegistry_RegisterDocumentSet-b">
            <input>
                <soap:body use="literal"/>
            </input>
            <output>
                <soap:body use="literal"/>
            </output>
            <fault name="DGWSFault">
                <soap:fault name="DGWSFault" use="literal"/>
            </fault>
        </operation>
    </binding>

    <service name="DocumentRegistry_Service">
        <port name="DocumentRegistry_Port_Soap" binding="ihe:DocumentRegistry_Binding_Soap">
            <soap:address location="http://servicelocation/DocumentRegistry_Service"/>
        </port>
    </service>
</definitions>
