JAL-1260 v2 patch from David Roldán-Martínez
[jalview.git] / src / jalview / io / xdb / genbank / GenBankSource.java
diff --git a/src/jalview/io/xdb/genbank/GenBankSource.java b/src/jalview/io/xdb/genbank/GenBankSource.java
new file mode 100644 (file)
index 0000000..c5ef3c2
--- /dev/null
@@ -0,0 +1,85 @@
+package jalview.io.xdb.genbank;
+
+/**
+ * <p>Free-format information including an abbreviated form of the organism
+ * name, sometimes followed by a molecule type. (See section 3.4.10 of the
+ * GenBank release notes for more info.)</p>
+ * <p>Entrez Search Field: Organism [ORGN] </p>
+ * <p>Search Tip: For some organisms that have well-established common names,
+ * such as baker's yeast, mouse, and human, a search for the common name will
+ * yield the same results as a search for the scientific name, e.g., a search
+ * for "baker's yeast" in the organism field retrieves the same number of
+ * documents as "Saccharomyces cerevisiae". This is true because the Organism
+ * field is connected to the NCBI Taxonomy Database, which contains
+ * cross-references between common names, scientific names, and synonyms for
+ * organisms represented in the Sequence databases.</p>
+ * <h1>Organism</h1>
+ * <p>The formal scientific name for the source organism (genus and species,
+ * where appropriate) and its lineage, based on the phylogenetic classification
+ * scheme used in the NCBI Taxonomy Database. If the complete lineage of an
+ * organism is very long, an abbreviated lineage will be shown in the GenBank
+ * record and the complete lineage will be available in the Taxonomy Database.
+ * (See also the /db_xref=taxon:nnnn Feature qualifer, below.)</p>
+ * <p>Entrez Search Field: Organism [ORGN] </p>
+ * <p>Search Tip: You can search the Organism field by any node in the taxonomic
+ * hierarchy, e.g., you can search for the term "Saccharomyces cerevisiae",
+ * "Saccharomycetales", "Ascomycota", etc. to retrieve all the sequences from
+ * organisms in a particular taxon. </p>
+ * 
+ */
+public class GenBankSource {
+    private String source="";
+    private String organism="";
+    private String taxonomic="";
+
+    public GenBankSource() {
+    }
+
+    @Override
+    public String toString() {
+        return String.format("%s\n\t%s\n\t%s", getSource(), getOrganism(), getTaxonomic());
+    }
+
+    /**
+     * @return the source
+     */
+    public String getSource() {
+        return source;
+    }
+
+    /**
+     * @param source the source to set
+     */
+    public void setSource(String source) {
+        this.source = source;
+    }
+
+    /**
+     * @return the organism
+     */
+    public String getOrganism() {
+        return organism;
+    }
+
+    /**
+     * @param organism the organism to set
+     */
+    public void setOrganism(String organism) {
+        this.organism = organism;
+    }
+
+    /**
+     * @return the taxonomic
+     */
+    public String getTaxonomic() {
+        return taxonomic;
+    }
+
+    /**
+     * @param taxonomic the taxonomic to set
+     */
+    public void setTaxonomic(String taxonomic) {
+        this.taxonomic = taxonomic;
+    }
+
+}