<?xml version="1.0" encoding="ISO-8859-1"?>
<rdf:RDF
  xmlns:service="http://www.daml.org/services/daml-s/0.7/Service.daml#"
  xmlns:process="http://www.daml.org/services/daml-s/0.7/Process.daml#"
  xmlns:profile="http://www.daml.org/services/daml-s/0.7/Profile.daml#"
  xmlns:grounding="http://www.daml.org/services/daml-s/0.7/Grounding.daml#"
  xmlns:daml="http://www.daml.org/2001/03/daml+oil#"
  xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema#"  
  xmlns:co="http://www.flacp.fujitsulabs.com/~mhgrove/services/contactOnt.daml#"
>

<daml:Ontology rdf:about="">
<!--
  <daml:imports rdf:resource="http://www.mindswap.org/2002/services/shop2/concepts.daml#"/>
  <daml:imports rdf:resource="http://www.flacp.fujitsulabs.com/~mhgrove/services/contactOnt.daml#"/>
  <daml:imports rdf:resource="file://C/Mindswap/shop2/web_cache/Process.daml#"/>
  <daml:imports rdf:resource="file://C/Mindswap/shop2/web_cache/contactOnt.daml#"/>
  <daml:imports rdf:resource="file://C/Mindswap/shop2/web_cache/concepts.daml#"/>
  <daml:imports rdf:resource="file://C/Mindswap/shop2/web_cache/Profile.daml#"/>
-->
</daml:Ontology>

<!-- Service description -->

<service:Service rdf:ID="TreatmentService">
  <service:presents rdf:resource="#TreatmentProfile" />  
  <service:describedBy rdf:resource="#TreatmentProcessModel" />  
  <service:supports rdf:resource="#TreatmentGrounding" />
</service:Service>

<!-- Profile description -->

<profile:Profile rdf:ID="TreatmentProfile">       
  <service:isPresentedBy rdf:resource="#TreatmentService"/>
  <profile:textDescription>Makes the necesseary appointment arrangements
  for a given treatment type. The treatment centers are selected based on 
  the location preferences and insurance of the patient.</profile:textDescription>
  <profile:serviceName>Treatment Schedule</profile:serviceName>

  <profile:input> 
    <profile:ParameterDescription rdf:ID="tPreference">
      <profile:parameterName>Time Preference</profile:parameterName>
      <profile:restrictedTo rdf:resource="http://www.flacp.fujitsulabs.com/~mhgrove/services/contactOnt.daml#Address"/>
      <profile:refersTo rdf:resource="#timePreference"/>
    </profile:ParameterDescription>
  </profile:input>
  
  <profile:input> 
    <profile:ParameterDescription rdf:ID="locPreference"> 
      <profile:parameterName>Location Preference</profile:parameterName>
      <profile:restrictedTo rdf:resource="http://www.flacp.fujitsulabs.com/~mhgrove/services/FLACP-ServiceOnt.daml#WebPage"/>
      <profile:refersTo rdf:resource="#locationPreference"/>
    </profile:ParameterDescription>
  </profile:input>

</profile:Profile>

<!-- Process Model description -->

<process:ProcessModel rdf:ID="TreatmentProcessModel">
  <service:describes rdf:resource="#TreatmentService" /> 
  <process:hasProcess rdf:resource="#TreatmentProcess" /> 
</process:ProcessModel>

<daml:Class rdf:ID="TimePreference">
  <rdfs:subClassOf>
    <daml:Restriction>
      <daml:onProperty rdf:resource="#begin"/>
      <daml:toClass rdf:resource="http://www.w3.org/2001/XMLSchema#time"/>
      <daml:cardinality>1</daml:cardinality>      
    </daml:Restriction>
  </rdfs:subClassOf>
  
  <rdfs:subClassOf>
    <daml:Restriction>
      <daml:onProperty rdf:resource="#end"/>
      <daml:toClass rdf:resource="http://www.w3.org/2001/XMLSchema#time"/>
      <daml:cardinality>1</daml:cardinality>      
    </daml:Restriction>
  </rdfs:subClassOf>
</daml:Class>

<daml:DatatypeProperty rdf:ID="begin">
	<rdfs:domain rdf:resource="#TimePreference" />
	<rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#time" />
</daml:DatatypeProperty>

<daml:DatatypeProperty rdf:ID="end">
	<rdfs:domain rdf:resource="#TimePreference" />
	<rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#time" />
</daml:DatatypeProperty>


<daml:Class rdf:ID="TreatmentProcess">
  <rdfs:subClassOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#AtomicProcess" /> 
</daml:Class>

<daml:Class rdf:ID="LocationPreference">
  <rdfs:subClassOf>
    <daml:Restriction>
      <daml:onProperty rdf:resource="#address"/>
      <daml:cardinality>1</daml:cardinality>      
    </daml:Restriction>
  </rdfs:subClassOf>
  
  <rdfs:subClassOf>
    <daml:Restriction>
      <daml:onProperty rdf:resource="#distance"/>
      <daml:cardinality>1</daml:cardinality>      
    </daml:Restriction>
  </rdfs:subClassOf>
</daml:Class>

<daml:ObjectProperty rdf:ID="address">
	<rdfs:domain rdf:resource="#LocationPreference" />
	<rdfs:range rdf:resource="http://www.flacp.fujitsulabs.com/~mhgrove/services/contactOnt.daml#Address" />
</daml:ObjectProperty>

<daml:DatatypeProperty rdf:ID="distance">
	<rdfs:domain rdf:resource="#LocationPreference" />
	<rdfs:range rdf:resource="http://www.w3.org/2000/10/XMLSchema#int" />
</daml:DatatypeProperty>


<rdf:Property rdf:ID="locationPreference">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:domain rdf:resource="#TreatmentProcess" /> 
  <rdfs:range rdf:resource="#LocationPreference"/>
</rdf:Property>

<rdf:Property rdf:ID="timePreference">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:domain rdf:resource="#TreatmentProcess" /> 
  <rdfs:range rdf:resource="#TimePreference"/>
</rdf:Property>

<rdf:Property rdf:ID="treatmentID">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string" /> 
  <rdfs:domain rdf:resource="#TreatmentProcess"/>
</rdf:Property>

<daml:Class rdf:ID="Rating">
  <daml:oneOf rdf:parseType="daml:collection">
    <daml:Thing rdf:ID="Excellent" /> 
    <daml:Thing rdf:ID="Good" /> 
    <daml:Thing rdf:ID="Average" /> 
    <daml:Thing rdf:ID="Poor" /> 
  </daml:oneOf>
</daml:Class>


<rdf:Property rdf:ID="rating">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:domain rdf:resource="#TreatmentProcess" /> 
  <rdfs:range rdf:resource="#Rating"/>
</rdf:Property>

<daml:ObjectProperty rdf:ID="involvedPeople">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:domain rdf:resource="#TreatmentProcess" /> 
  <rdfs:range rdf:resource="http://www.daml.org/2001/03/daml+oil#List"/>
</daml:ObjectProperty>

<!-- Grounding description -->

<grounding:WsdlGrounding rdf:ID="TreatmentGrounding">
  <service:supportedBy rdf:resource="#TreatmentService" />
  <grounding:hasAtomicProcessGrounding rdf:resource="#TreatmentProcessGrounding" /> 
</grounding:WsdlGrounding> 

<grounding:WsdlAtomicProcessGrounding rdf:ID="TreatmentProcessGrounding"> 
  <grounding:damlsProcess rdf:resource="#TreatmentProcess"/>
  <grounding:wsdlOperation rdf:resource="Treatment"/>

  <grounding:wsdlInputMessage rdf:resource="TreatmentRequest"/>
  <grounding:wsdlInputMessageParts rdf:parseType="daml:collection">
	<grounding:wsdlMessageMap>
      <grounding:damlsParameter rdf:resource="#processInput"/>
      <grounding:wsdlMessagePart rdf:resource="in0"/>
    </grounding:wsdlMessageMap>
  </grounding:wsdlInputMessageParts>

  <grounding:wsdlOutputMessage rdf:resource="TreatmentResponse"/>
  <grounding:wsdlOutputMessageParts rdf:parseType="daml:collection">
	<grounding:wsdlMessageMap>
      <grounding:damlsParameter rdf:resource="#processOutput"/>
      <grounding:wsdlMessagePart rdf:resource="return"/> 
	</grounding:wsdlMessageMap>  
  </grounding:wsdlOutputMessageParts>

  <grounding:wsdlReference>http://www.w3.org/TR/2001/NOTE-wsdl-20010315</grounding:wsdlReference>
  <grounding:otherReference>http://www.w3.org/TR/2001/NOTE-wsdl-20010315 http://schemas.xmlsoap.org/wsdl/soap/ http://schemas.xmlsoap.org/soap/http/</grounding:otherReference>
  <grounding:wsdlDocument>file://C/Mindswap/shop2/daml/AllServices.wsdl</grounding:wsdlDocument>
</grounding:WsdlAtomicProcessGrounding>

</rdf:RDF>

