<?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:fla="http://www.flacp.fujitsulabs.com/~mhgrove/services/FLACP-ServiceOnt.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#"
  
>

<!-- Service description -->

<service:Service rdf:ID="translatorFla2TeknowledgeAddressService">
  <service:presents rdf:resource="#translatorFla2TeknowledgeAddressProfile" />  
  <service:describedBy rdf:resource="#translatorFla2TeknowledgeAddressProcessModel" />  
  <service:supports rdf:resource="#translatorFla2TeknowledgeAddressGrounding" />
</service:Service>

<!-- Profile description -->

<fla:TranslatorProfile rdf:ID="translatorFla2TeknowledgeAddressProfile">       
  <service:isPresentedBy rdf:resource="#translatorFla2TeknowledgeAddressService"/>
  <profile:textDescription>translates adress</profile:textDescription>
  <profile:serviceName>translatorFla2TeknowledgeAddress</profile:serviceName>

  <profile:input> 
    <profile:ParameterDescription rdf:ID="InputParameter"> 
      <profile:parameterName>XMLInput</profile:parameterName>
      <profile:restrictedTo rdf:resource="http://www.mindswap.org/services/Teknowledge.daml#Address"/>
      <profile:refersTo rdf:resource="#processInput"/>
    </profile:ParameterDescription>
  </profile:input>
  
  <profile:output> 
    <profile:ParameterDescription rdf:ID="OutputParameter"> 
      <profile:parameterName>XMLOutput</profile:parameterName>
      <profile:restrictedTo rdf:resource="http://www.mindswap.org/services/Teknowledge.daml#Address"/>
      <profile:refersTo rdf:resource="#processOutput"/>
    </profile:ParameterDescription>
  </profile:output>

</fla:TranslatorProfile>

<!-- Process Model description -->

<process:ProcessModel rdf:ID="translatorFla2TeknowledgeAddressProcessModel">
  <service:describes rdf:resource="#translatorFla2TeknowledgeAddressService" /> 
  <process:hasProcess rdf:resource="#translatorFla2TeknowledgeAddress" /> 
</process:ProcessModel>

<daml:Class rdf:ID="translatorFla2TeknowledgeAddress">
  <rdfs:subClassOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#AtomicProcess" /> 
  <rdfs:subClassOf>
    <daml:Restriction daml:cardinality="1">
      <daml:onProperty rdf:resource="#addressOutput" /> 
    </daml:Restriction>
  </rdfs:subClassOf> 
  <rdfs:subClassOf>
    <daml:Restriction daml:cardinality="1">
      <daml:onProperty rdf:resource="#transformationFunction" /> 
      <daml:hasValue parseType="Literal">
			<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:contactOnt="http://www.flacp.fujitsulabs.com/~mhgrove/services/contactOnt.daml#"
xmlns:Teknowledge="http://www.mindswap.org/services/Teknowledge.daml#">

<xsl:template match="/">

<xsl:for-each select="//contactOnt:Address">
<Teknowledge:Address>
<xsl:variable name="X1" select="//contactOnt:State"/>
<Teknowledge:stateOfAddress>
	<xsl:value-of select="$X1"/>
</Teknowledge:stateOfAddress>
<xsl:variable name="X2" select="//contactOnt:StreetAddress"/>
<Teknowledge:numberOfAddress>
	<xsl:value-of select="substring-before($X2,' ')"/>
</Teknowledge:numberOfAddress>
<Teknowledge:streetOfAddress>
	<xsl:value-of select="substring-after($X2,' ')"/>
</Teknowledge:streetOfAddress>
</Teknowledge:Address>
</xsl:for-each>


</xsl:template>
</xsl:stylesheet>
      </daml:hasValue>
    </daml:Restriction>
  </rdfs:subClassOf>   
</daml:Class>

<rdf:Property rdf:ID="processInput">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:domain rdf:resource="#translatorFla2TeknowledgeAddress" /> 
  <rdfs:range rdf:resource="http://www.mindswap.org/services/Teknowledge.daml#Address"/>
</rdf:Property>

<rdf:Property rdf:ID="transformationFunction">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#input" /> 
  <rdfs:domain rdf:resource="#translatorFla2TeknowledgeAddress" /> 
  <rdfs:range rdf:resource="http://www.w3.org/2000/01/rdf-schema#Literal"/>
</rdf:Property>

<rdf:Property rdf:ID="processOutput">
  <rdfs:subPropertyOf rdf:resource="http://www.daml.org/services/daml-s/0.7/Process.daml#output" /> 
  <rdfs:domain rdf:resource="#translatorFla2TeknowledgeAddress" /> 
  <rdfs:range rdf:resource="http://www.mindswap.org/services/Teknowledge.daml#Address"/>
</rdf:Property>

<!-- Grounding description -->

<grounding:WsdlGrounding rdf:ID="translatorFla2TeknowledgeAddressGrounding">
  <service:supportedBy rdf:resource="#translatorFla2TeknowledgeAddressService" />
  <grounding:hasAtomicProcessGrounding rdf:resource="#translatorFla2TeknowledgeAddressProcessGrounding" /> 
</grounding:WsdlGrounding> 

<grounding:WsdlAtomicProcessGrounding rdf:ID="translatorFla2TeknowledgeAddressProcessGrounding"> 
  <grounding:damlsProcess rdf:resource="#translatorFla2TeknowledgeAddress"/>
  <grounding:wsdlOperation rdf:resource="http://www.mindswap.org/2002/services/OntologyTranslator.wsdl#transform"/>

  <grounding:wsdlInputMessage rdf:resource="http://www.mindswap.org/2002/services/OntologyTranslator.wsdl#transformRequest"/>
  <grounding:wsdlInputMessageParts rdf:parseType="daml:collection">
	<grounding:wsdlMessageMap>
      <grounding:damlsParameter rdf:resource="#processInput"/>
      <grounding:wsdlMessagePart
           rdf:resource="http://www.mindswap.org/2002/services/OntologyTranslator.wsdl#in"/>
    </grounding:wsdlMessageMap>
	<grounding:wsdlMessageMap>
      <grounding:damlsParameter rdf:resource="#transformationFunction"/>
      <grounding:wsdlMessagePart
           rdf:resource="http://www.mindswap.org/2002/services/OntologyTranslator.wsdl#xsltFunction"/>    
	</grounding:wsdlMessageMap>    
  </grounding:wsdlInputMessageParts>

  <grounding:wsdlOutputMessage rdf:resource="http://www.mindswap.org/2002/services/OntologyTranslator.wsdl#transformResponse"/>
  <grounding:wsdlOutputMessageParts rdf:parseType="daml:collection">
	<grounding:wsdlMessageMap>
      <grounding:damlsParameter rdf:resource="#processOutput"/>
      <grounding:wsdlMessagePart
           rdf:resource="http://www.mindswap.org/2002/services/OntologyTranslator.wsdl#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>http://www.mindswap.org/2002/services/OntologyTranslator.wsdl</grounding:wsdlDocument>
</grounding:WsdlAtomicProcessGrounding>

</rdf:RDF>

