Difference between revisions of "FishFinderTMPlugin"

From Gcube Wiki
Jump to: navigation, search
(Created page with '{| align="right" ||__TOC__ |} Species TM Plugin is a plugin of the Tree Based Access Facilities that defines and maintains tree views of biodiversity data…')
 
(Example)
Line 220: Line 220:
 
<?xml version="1.0" ?>
 
<?xml version="1.0" ?>
  
<t:root xmlns:t="http://gcube-system.org/namespaces/data/trees"
+
<t:root xmlns:t="http://gcube-system.org/namespaces/data/trees" t:id="BEP">
SpeciesServiceId="ITIS:159903" storeId="1" t:id="ITIS:159903"
+
t:source="6153d4d5-f872-46f2-9ab1-2a056042030e">
+
  
<dwc t:id="12">
+
<alpha_cod>BEP</alpha_cod>
<taxonRemarks t:id="16">valid</taxonRemarks>
+
<name_en>Eastern Pacific bonito</name_en>
<scientificName t:id="21">Carcharodon carcharias</scientificName>
+
<name_fr>Bonite du Pacifique oriental</name_fr>
<verbatimTaxonRank t:id="33"></verbatimTaxonRank>
+
<name_es>Bonito del Pacífico oriental</name_es>
<class t:id="26">Chondrichthyes</class>
+
<images>figis/species/images/Sarda/sco_sar_chi_web_3275_0.gif</images>
<scientificNameAuthorship t:id="13">(Linnaeus,1758)</scientificNameAuthorship>
+
<scientific_name>Sarda chiliensis</scientific_name>
<nameAccordingTo t:id="22">Accessed through: the Integrated
+
<family>Scombridae</family>
Taxonomic Information System (ITIS) at http://www.itis.gov on
+
<personal_author>(Cuvier, 1831)</personal_author>
04-29-2013</nameAccordingTo>
+
<year>1831</year>
<genus t:id="29">Carcharodon</genus>
+
<diagnostic_features>Upper jaw teeth 18 to 30; lower jaw teeth 14 to
<taxonomicStatus t:id="15">VALID</taxonomicStatus>
+
25; vomerine teeth absent; supramaxilla wide (Collette &amp; Chao,
<infraspecificEpithet t:id="32"></infraspecificEpithet>
+
1975:fig. 32d) 23 to 27 gillrakers on first arch. First dorsal fin
<modified t:id="19"></modified>
+
with 17 to 19 spines, length of fin base 26.7 to 31.4% of fork length
<acceptedNameUsageID t:id="14"></acceptedNameUsageID>
+
; dorsal finlets usually 8; 12 to 15 rays in anal fin; anal finlets
<phylum t:id="25">Chordata</phylum>
+
usually 6 or 7; pectoral fin rays 22 to 26, usually 24 or 25.
 
+
Vertebrae 22 to 24 precaudal plus 20 to 23 caudal, total 42 to 46,
<vernacularNames t:id="34">
+
usually 44 or 45. Colour: dorsal stripes slightly oblique.
<language t:id="35">English</language>
+
</diagnostic_features>
<locality t:id="36"></locality>
+
<area_text>Restricted to the eastern Pacific Ocean (Collette &amp;
<vernacularName t:id="37">great white shark</vernacularName>
+
Chao, 1975:fig. 70). Its geographical range includes a northern and a
</vernacularNames>
+
southern subspecies separated by a tropical population of Sarda
 
+
orientalis . The southern subspecies S. chiliensis chiliensis, occurs
<vernacularNames t:id="38">
+
from Mancora, Peru, just south of the Gulf of Guayaquil southward to
<language t:id="39">Spanish</language>
+
Talcahuano, Chile. The northern subspecies S. chiliensis lineolata
<locality t:id="40"></locality>
+
(Girard) occurs from off the coast of Alaska (60° 16'N, 145° 32'W)
<vernacularName t:id="41">jaquetón de ley</vernacularName>
+
southward to Cabo San Lucas at the tip of Baja California (22° 20'N,
</vernacularNames>
+
112° 27'W and in the Revillagigedo Islands).</area_text>
 
+
<habitat_bio>An epipelagic, neritic species attaining sexual maturity
<vernacularNames t:id="42">
+
at about 2 years of age.</habitat_bio>
<language t:id="43">French</language>
+
<interest_fisheries>In California, eastern Pacific bonito is taken
<locality t:id="44"></locality>
+
commercially by purse seiners, but is more important to the
<vernacularName t:id="45">requin blanc</vernacularName>
+
recreational hooks and lines fishery operating from private and party
</vernacularNames>
+
boats, piers and jetties, and from the shore (Yoshida, 1980:42). In
 
+
the mid-sixties, the Chilean bonito fishery between lquique and
<vernacularNames t:id="46">
+
Antofagasta expanded from an almost entirely artisanal activity with
<language t:id="47">Spanish</language>
+
floating gillnets and small purse seines to an industrial operation
<locality t:id="48"></locality>
+
with specialized bonito/tuna vessels (Yoshida, 1980:42). The landings
<vernacularName t:id="49">tiburón blanco</vernacularName>
+
of the northern subspecies ( S. c. lineolata ) in California and
</vernacularNames>
+
Mexico have fluctuated greatly over the last 50 years from less than 1
 
+
000 metric tons to nearly 14 000 t in the early seventies, ranking in
<vernacularNames t:id="50">
+
13th place (4 003 t worth $1 222 000) in total California landings of
<language t:id="51">English</language>
+
1976. The Peruvian landings of the southern subspecies ( S. c.
<locality t:id="52"></locality>
+
chiliensis ) increased from almost nil in 1940 to a peak of 110 000 t
<vernacularName t:id="53">white shark</vernacularName>
+
per year in the early sixties, thereafter gradually dropping off to 40
</vernacularNames>
+
000 t in the mid-seventies (Yoshida, 1980:44). The world catch for the
 
+
species as a whole was down to between 10 219 t in 1976 and 15 936 t
<order t:id="27">Lamniformes</order>
+
in 1981, reaching 21 308 t in 1977 (FAO, 1983). The total catch
<kingdom t:id="24">Animalia</kingdom>
+
reported for this species to FAO for 1999 was 3 187 t. The countries
<family t:id="28">Lamnidae</family>
+
with the largest catches were Mexico (1 775 t) and Peru (948 t).
<parentNameUsageID t:id="23">ITIS:159902</parentNameUsageID>
+
</interest_fisheries>
<rightsHolder t:id="17">This information
+
<local_names>Bonito (Chile),Bonito (Colombia),Bonito (Mexico),Aguadito
object has been generated via the Species Product Discovery service
+
(Peru),Chilensk bonit (Sweden),Pacific bonito (USA),Chilijskaya
on 04-29-2013 by interfacing with ITIS, the Integrated Taxonomic
+
pelamida (Former ussr)</local_names>
Information System (http://www.itis.gov/)</rightsHolder>
+
<factsheet_url>http://www.fao.org/fishery/species/3275/en
<subgenus t:id="30"></subgenus>
+
</factsheet_url>
<scientificNameID t:id="18">urn:lsid:itis.gov:itis_tsn:159903</scientificNameID>
+
<factsheet_id></factsheet_id>
<specificEpithet t:id="31">carcharias</specificEpithet>
+
<taxonRank t:id="20">Species</taxonRank>
+
</dwc>
+
 
+
<properties t:id="2">
+
<property t:id="3">
+
<key t:id="4">Source</key>
+
<value t:id="5">NODC Taxonomic Code, database (version 8.0).Acquired: 1996-07-29.</value>
+
</property>
+
<property t:id="6">
+
<key t:id="7">Source</key>
+
<value t:id="8">F. A. O., database (version 1). Acquired:1996-07-29.</value>
+
</property>
+
<property t:id="9">
+
<key t:id="10">Source</key>
+
<value t:id="11">Catalog of Fishes, 17-Mar-2003, website (version
+
13-Mar-03). Acquired: 2003-03-17.</value>
+
</property>
+
</properties>
+
 
+
<provenance t:id="54">
+
<wasDerivedFrom t:id="55">Accessed through: the Integrated
+
Taxonomic Information System (ITIS) at http://www.itis.gov on
+
04-29-2013</wasDerivedFrom>
+
<wasGeneratedBy t:id="56">This information object has been
+
generated via the Species Product Discovery service on 04-29-2013 by
+
interfacing with ITIS, the Integrated Taxonomic Information System
+
(http://www.itis.gov/)</wasGeneratedBy>
+
</provenance>
+
  
 
</t:root>
 
</t:root>
 
  
  

Revision as of 14:02, 16 May 2013

Species TM Plugin is a plugin of the Tree Based Access Facilities that defines and maintains tree views of biodiversity data sources exposed by the Species Manager services. Species TM Plugin provides an uniform model to access and storage data from SPD Service. Each Taxon generated via SPD Service is trasformed in a edge-labelled tree by Species TM Plugin.

Tree model

A tree generated by SpeciesTMPlugin has three subtrees:

Generic model

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified" >
       <xs:element name="t:root" >
              <xs:complexType>
                     <xs:sequence>
                            <xs:element name="dwc" >
                                   <xs:complexType>
                                          <xs:sequence>
                                                 <xs:element name="taxonRemarks" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="scientificName" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="verbatimTaxonRank" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="class" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="scientificNameAuthorship" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="nameAccordingTo" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="genus" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="taxonomicStatus" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="infraspecificEpithet" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="modified" type="xs:date" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="acceptedNameUsageID" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="phylum" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="vernacularNames" maxOccurs="unbounded" minOccurs="0">
                                                        <xs:complexType>
                                                               <xs:sequence>
                                                                      <xs:element name="language" type="xs:string" >
                                                                             <xs:complexType>
                                                                                    <xs:attribute name="t:id" type="xs:int" />
                                                                                </xs:complexType>
                                                                         </xs:element>
                                                                      <xs:element name="locality" type="xs:string" >
                                                                             <xs:complexType>
                                                                                    <xs:attribute name="t:id" type="xs:int" />
                                                                                </xs:complexType>
                                                                         </xs:element>
                                                                      <xs:element name="vernacularName" type="xs:string" >
                                                                             <xs:complexType>
                                                                                    <xs:attribute name="t:id" type="xs:int" />
                                                                                </xs:complexType>
                                                                         </xs:element>
                                                                  </xs:sequence>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="order" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="kingdom" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="family" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="parentNameUsageID" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="rightsHolder" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="subgenus" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="scientificNameID" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="specificEpithet" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="taxonRank" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                             </xs:sequence>
                                          <xs:attribute name="t:id" type="xs:int" />
                                      </xs:complexType>
                               </xs:element>
                            <xs:element name="properties" >
                                   <xs:complexType>
                                          <xs:sequence>
                                                 <xs:element name="property" maxOccurs="unbounded" >
                                                        <xs:complexType>
                                                               <xs:sequence>
                                                                      <xs:element name="key" type="xs:string" >
                                                                             <xs:complexType>
                                                                                    <xs:attribute name="t:id" type="xs:int" />
                                                                                </xs:complexType>
                                                                         </xs:element>
                                                                      <xs:element name="value" type="xs:string" >
                                                                             <xs:complexType>
                                                                                    <xs:attribute name="t:id" type="xs:int" />
                                                                                </xs:complexType>
                                                                         </xs:element>
                                                                  </xs:sequence>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                             </xs:sequence>
                                          <xs:attribute name="t:id" type="xs:int" />
                                      </xs:complexType>
                               </xs:element>
                            <xs:element name="provenance" >
                                   <xs:complexType>
                                          <xs:sequence>
                                                 <xs:element name="wasDerivedFrom" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                                 <xs:element name="wasGeneratedBy" type="xs:string" >
                                                        <xs:complexType>
                                                               <xs:attribute name="t:id" type="xs:int" />
                                                           </xs:complexType>
                                                    </xs:element>
                                             </xs:sequence>
                                          <xs:attribute name="t:id" type="xs:int" />
                                      </xs:complexType>
                               </xs:element>
                        </xs:sequence>
                     <xs:attribute name="xmlns:t" type="xs:string" />
                     <xs:attribute name="SpeciesServiceId" type="xs:string" />
                     <xs:attribute name="storeId" type="xs:int" />
                     <xs:attribute name="t:id" type="xs:string" />
                     <xs:attribute name="t:source" type="xs:string" />
                 </xs:complexType>
          </xs:element>
   </xs:schema>

Example

A tree generated by Species TM Plugin looks like this:

<?xml version="1.0" ?>
 
<t:root xmlns:t="http://gcube-system.org/namespaces/data/trees"	t:id="BEP">
 
	<alpha_cod>BEP</alpha_cod>
	<name_en>Eastern Pacific bonito</name_en>
	<name_fr>Bonite du Pacifique oriental</name_fr>
	<name_es>Bonito del Pacífico oriental</name_es>
	<images>figis/species/images/Sarda/sco_sar_chi_web_3275_0.gif</images>
	<scientific_name>Sarda chiliensis</scientific_name>
	<family>Scombridae</family>
	<personal_author>(Cuvier, 1831)</personal_author>
	<year>1831</year>
	<diagnostic_features>Upper jaw teeth 18 to 30; lower jaw teeth 14 to
		25; vomerine teeth absent; supramaxilla wide (Collette &amp; Chao,
		1975:fig. 32d) 23 to 27 gillrakers on first arch. First dorsal fin
		with 17 to 19 spines, length of fin base 26.7 to 31.4% of fork length
		; dorsal finlets usually 8; 12 to 15 rays in anal fin; anal finlets
		usually 6 or 7; pectoral fin rays 22 to 26, usually 24 or 25.
		Vertebrae 22 to 24 precaudal plus 20 to 23 caudal, total 42 to 46,
		usually 44 or 45. Colour: dorsal stripes slightly oblique.
	</diagnostic_features>
	<area_text>Restricted to the eastern Pacific Ocean (Collette &amp;
		Chao, 1975:fig. 70). Its geographical range includes a northern and a
		southern subspecies separated by a tropical population of Sarda
		orientalis . The southern subspecies S. chiliensis chiliensis, occurs
		from Mancora, Peru, just south of the Gulf of Guayaquil southward to
		Talcahuano, Chile. The northern subspecies S. chiliensis lineolata
		(Girard) occurs from off the coast of Alaska (60° 16'N, 145° 32'W)
		southward to Cabo San Lucas at the tip of Baja California (22° 20'N,
		112° 27'W and in the Revillagigedo Islands).</area_text>
	<habitat_bio>An epipelagic, neritic species attaining sexual maturity
		at about 2 years of age.</habitat_bio>
	<interest_fisheries>In California, eastern Pacific bonito is taken
		commercially by purse seiners, but is more important to the
		recreational hooks and lines fishery operating from private and party
		boats, piers and jetties, and from the shore (Yoshida, 1980:42). In
		the mid-sixties, the Chilean bonito fishery between lquique and
		Antofagasta expanded from an almost entirely artisanal activity with
		floating gillnets and small purse seines to an industrial operation
		with specialized bonito/tuna vessels (Yoshida, 1980:42). The landings
		of the northern subspecies ( S. c. lineolata ) in California and
		Mexico have fluctuated greatly over the last 50 years from less than 1
		000 metric tons to nearly 14 000 t in the early seventies, ranking in
		13th place (4 003 t worth $1 222 000) in total California landings of
		1976. The Peruvian landings of the southern subspecies ( S. c.
		chiliensis ) increased from almost nil in 1940 to a peak of 110 000 t
		per year in the early sixties, thereafter gradually dropping off to 40
		000 t in the mid-seventies (Yoshida, 1980:44). The world catch for the
		species as a whole was down to between 10 219 t in 1976 and 15 936 t
		in 1981, reaching 21 308 t in 1977 (FAO, 1983). The total catch
		reported for this species to FAO for 1999 was 3 187 t. The countries
		with the largest catches were Mexico (1 775 t) and Peru (948 t).
	</interest_fisheries>
	<local_names>Bonito (Chile),Bonito (Colombia),Bonito (Mexico),Aguadito
		(Peru),Chilensk bonit (Sweden),Pacific bonito (USA),Chilijskaya
		pelamida (Former ussr)</local_names>
	<factsheet_url>http://www.fao.org/fishery/species/3275/en
	</factsheet_url>
	<factsheet_id></factsheet_id>
 
</t:root>

Bind request

An Activation Record allows the creation of collections. Using an Activation Record the user selects scientific names and data sources to create the collection.

A request has this form:

        List<ScientificName> as ScientificName in List<DataSource> return Taxon

If List<DataSource> is empty, Species TM Plugin will retrieve data from all Data Sources.


Examples:

        'Carcharodon carcharias' , 'Rosa' in ITIS, CatalogueOfLife return Taxon
        'Carcharodon carcharias' , 'Rosa' return Taxon
        'Carcharodon carcharias' return Taxon

Maven coordinates

The Maven coordinates of species-tree-plugin of its development versions are:

<groupId>org.gcube.data.access</groupId>
<artifactId>species-tree-plugin</artifactId>
<version>1.1.0</version>

The request classes are separated from the species-tree-plugin, in a component upon which plugin depends. This component is species-tree-requests.

The Maven coordinates of species-tree-requests of its development versions are:

<groupId>org.gcube.data.access</groupId>
<artifactId>species-tree-requests</artifactId>
<version>1.0.0-SNAPSHOT</version>