<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">

	<bean id="ontologyModelService" class="org.dataone.cn.indexer.annotation.OntologyModelService">
		<property name="fieldList">
			<list>
				<ref bean="eml.annotation.property.expansion" />
				<ref bean="eml.annotation.value.expansion" />
			</list>
		</property>

		<property name="ontologyList">
			<list>
				<value>http://purl.dataone.org/ontologies/observation/d1-ECSO.owl</value>
				<value>http://purl.dataone.org/ontologies/provenance/ProvONE/v1/owl/provone.owl</value>
				<value>http://purl.obolibrary.org/obo/envo.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-owl.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-core.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-characteristics.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-standards.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-spatial.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-temporal.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-taxa.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-biology.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-ecology.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-environment.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-chemistry.owl</value>
				<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-anatomy.owl</value>
				<value>http://ecoinformatics.org/oboe-ext/sbclter.1.0/oboe-sbclter.owl</value>
				<value>https://purl.dataone.org/odo/MOSAIC_</value>
				<value>http://purl.dataone.org/odo/ARCRC</value>
				<value>https://purl.dataone.org/odo/ADCAD_</value>
				<value>http://purl.dataone.org/odo/SENSO_</value>
				<value>http://purl.dataone.org/odo/SALMON_</value>
				<value>http://purl.dataone.org/odo/SALMON_alignment_</value>
				<value>http://purl.dataone.org/odo/SASAP_</value>
			</list>
		</property>

		<property name="altEntryList" ref="alt.entries" />
	</bean>

	<bean id="alt.entries" class="java.util.HashMap">
		<constructor-arg>
			<map key-type="java.lang.String" value-type="java.lang.String">
				<entry key="http://purl.dataone.org/ontologies/observation/d1-ECSO.owl" value="ontologies/ECSO.owl" />
				<entry key="http://purl.dataone.org/ontologies/provenance/ProvONE/v1/owl/provone.owl" value="ontologies/provone.owl" />
				<entry key="http://purl.obolibrary.org/obo/envo.owl" value="ontologies/envo.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-owl.owl" value="ontologies/oboe.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-core.owl" value="ontologies/oboe-core.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-characteristics.owl" value="ontologies/oboe-characteristics.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-standards.owl" value="ontologies/oboe-standards.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-spatial.owl" value="ontologies/oboe-spatial.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-temporal.owl" value="ontologies/oboe-temporal.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-taxa.owl" value="ontologies/oboe-taxa.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-biology.owl" value="ontologies/oboe-biology.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-ecology.owl" value="ontologies/oboe-ecology.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-environment.owl" value="ontologies/oboe-environment.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-chemistry.owl" value="ontologies/oboe-chemistry.owl" />
				<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-anatomy.owl" value="ontologies/oboe-anatomy.owl" />
				<entry key="http://ecoinformatics.org/oboe-ext/sbclter.1.0/oboe-sbclter.owl" value="ontologies/oboe-sbclter.owl" />
				<entry key="https://purl.dataone.org/odo/MOSAIC_" value="ontologies/MOSAiC.owl" />
				<entry key="http://purl.dataone.org/odo/ARCRC" value="ontologies/ARCRC.owl" />
				<entry key="https://purl.dataone.org/odo/ADCAD_" value="ontologies/ADCAD.owl" />
				<entry key="http://purl.dataone.org/odo/SENSO_" value="ontologies/SENSO.owl" />
				<entry key="http://purl.dataone.org/odo/SALMON_" value="ontologies/SALMON.owl" />
				<entry key="http://purl.dataone.org/odo/SALMON_alignment_" value="ontologies/SALMON_alignment.owl" />
				<entry key="http://purl.dataone.org/odo/SASAP_" value="ontologies/SASAP.owl" />
			</map>
		</constructor-arg>
	</bean>

	<bean id="eml.annotation.property.expansion" class="org.dataone.cn.indexer.annotation.SparqlField">
		<constructor-arg name="name" value="annotation_property_uri" />
		<constructor-arg name="query">
			<value>
				<![CDATA[
				PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
				PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
				PREFIX owl: <http://www.w3.org/2002/07/owl#>

				SELECT ?annotation_property_uri
				WHERE {
						<$CONCEPT_URI> (owl:equivalentProperty|^owl:equivalentProperty)*/rdfs:subPropertyOf* ?annotation_property_uri .
				 	}
				 ]]>
			</value>
		</constructor-arg>
	</bean>

	<bean id="eml.annotation.value.expansion" class="org.dataone.cn.indexer.annotation.SparqlField">
		<constructor-arg name="name" value="annotation_value_uri" />
		<constructor-arg name="query">
			<value>
				<![CDATA[
				PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
				PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
				PREFIX owl: <http://www.w3.org/2002/07/owl#>
				PREFIX skos: <http://www.w3.org/2004/02/skos/core#>

				SELECT ?annotation_value_uri
				WHERE
				{
					<$CONCEPT_URI> (rdf:type|(owl:equivalentClass|^owl:equivalentClass)*|(owl:sameAs|^owl:sameAs)*|(skos:exactMatch|^skos:exactMatch)*)/rdfs:subClassOf* ?annotation_value_uri  .
				}
				]]>
			</value>
		</constructor-arg>
	</bean>
</beans>
