From: <mg...@us...> - 2006-07-27 18:46:23
|
Revision: 68 Author: mgibson Date: 2006-07-27 11:46:08 -0700 (Thu, 27 Jul 2006) ViewCVS: http://svn.sourceforge.net/obo/?rev=68&view=rev Log Message: ----------- ant war file creation task to ant for war files for jboss also fixed compile so it doesnt compile test (whether it needs it or not) Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxCharList.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-07-27 16:21:55 UTC (rev 67) +++ phenote/trunk/build.xml 2006-07-27 18:46:08 UTC (rev 68) @@ -52,7 +52,7 @@ <!-- The compile target runs javac on all the java files, and saves them into the classfiles directory. --> <target name="compile" depends="init"> - <javac srcdir="${src}" destdir="${classfiles}" debug="yes"> + <javac srcdir="${src}" destdir="${classfiles}" debug="yes" excludes="test/**"> <classpath refid="project.classpath3"/> </javac> </target> @@ -143,13 +143,15 @@ <exclude name="${dist}/**"/> <exclude name="svn-phenote/**"/> <exclude name="tars/**"/> - <exclude name="source/obo-files/**"/> <exclude name="src/obo-files/**"/> <exclude name="*.tar"/> <exclude name="*.jar"/> <exclude name="garbage/**"/> <exclude name="oldjars/**"/> - <exclude name="source/**"/> + <exclude name="src/java/**"/> + <exclude name="web-classfiles/**"/> + <exclude name="web-interface/**"/> + <exclude name="web-deployment/**"/> </tarfileset> </tar> <gzip zipfile="tars/${dist}/phenote-${dist}.tar.gz" src="tars/${dist}/phenote-${dist}.tar"/> @@ -162,7 +164,6 @@ <exclude name="${dist}/**"/> <exclude name="svn-phenote/**"/> <exclude name="tars/**"/> - <exclude name="source/obo-files/**"/> <exclude name="src/obo-files/**"/> <!-- for now take out go as its 8.5M & not being used yet --> <exclude name="obo-files/gene_ontology.obo"/> @@ -170,10 +171,12 @@ <exclude name="*.jar"/> <exclude name="garbage/**"/> <exclude name="oldjars/**"/> - <exclude name="jars/phenote.jar"/> - <exclude name="source/**"/> + <!-- exclude name="jars/phenote.jar"/ --> <exclude name="doc/**"/> <exclude name="classfiles/**"/> + <exclude name="web-classfiles/**"/> + <exclude name="web-interface/**"/> + <exclude name="web-deployment/**"/> </tarfileset> </tar> <gzip zipfile="tars/${dist}/phenote-${dist}-src.tar.gz" src="tars/${dist}/phenote-${dist}-src.tar"/> @@ -204,6 +207,16 @@ </copy> </target> + <target name="war" depends="jar"> + <war destfile="war-deployment-link/phenote.war" webxml="src/web/web.xml"> + <fileset dir="src/web"/> + <lib dir="${lib}"/> + <classes dir="${classfiles}" /> + <zipfileset dir="${obo}"/> <!-- prefix="obo-files"/ ??? --> + <zipfileset dir="${conf}"/> + </war> + </target> + </project> Modified: phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxCharList.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxCharList.java 2006-07-27 16:21:55 UTC (rev 67) +++ phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxCharList.java 2006-07-27 18:46:08 UTC (rev 68) @@ -3,3 +3,4 @@ /** not sure if this is needed as separate class. a lit of PhenoSyntaxChar objects that wrap CharacterIs */ +class PhenoSyntaxCharList {} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-08-14 13:17:00
|
Revision: 90 Author: mgibson Date: 2006-08-14 06:16:51 -0700 (Mon, 14 Aug 2006) ViewCVS: http://svn.sourceforge.net/obo/?rev=90&view=rev Log Message: ----------- changed build file for web deployment to use environment variable previously it was using directories which we're symobolic links also changed some indenting from kevins commit from 6 spaces to 2 env vars for web deploy to tomcat: setenv PHENOTE_WEB_CONF_FILES $TOMCAT_WEB_ROOT setenv PHENOTE_WEB_CLASSFILES "${TOMCAT_WEB_ROOT}/WEB-INF/classes" setenv PHENOTE_WEB_HTML "${TOMCAT_WEB_ROOT}/phenote/0.6/web-interface" well thats how i do it at least - you get the idea Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/conf/initial-zfin.cfg phenote/trunk/src/java/phenote/gui/Phenote.java phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java phenote/trunk/src/web/web.xml Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-08-09 22:18:09 UTC (rev 89) +++ phenote/trunk/build.xml 2006-08-14 13:16:51 UTC (rev 90) @@ -3,17 +3,24 @@ ant build file ====================================================================== --> +<!-- environment variable $PHENOTE_WEB_CONF_FILES need to be set to --> +<!-- where cfg & obo files go on the web deployment for web-deployment --> +<!-- to work, $PHENOTE_WEB_CLASSFILES for classfile deployment --> + <project name="phenote" default="compile" basedir="."> <description>phenote ant build</description> - + <!-- allows for use of environment vars --> + <property environment="env"/> <!-- property name="src-svn" value="./src/java" / --> <property name="src" value="./src/java" /> <property name="test" value="./src/java/test" /> <!-- where classes go --> <property name="classfiles" value="classfiles" /> <!-- symbolic link over to web world --> - <property name="web-classfiles" value="web-classfiles" /> + <property name="web-classfiles" value="${env.PHENOTE_WEB_CLASSFILES}" /> + <property name="web-conf" value="${env.PHENOTE_WEB_CONF_FILES}"/> + <property name="web-html" value="${env.PHENOTE_WEB_HTML}"/> <property name="lib" value="jars" /> <property name="jarfile" value="jars/phenote.jar"/> <property name="obo" value="obo-files" /> @@ -193,16 +200,16 @@ </target> <!-- web-deployment & web-config-files should be a symoblic link to ones web site --> - <target name="web-deployment"> - <copy todir="web-deployment"> + <target name="web-deployment" depends="compile-servlet"> + <copy todir="${web-html}"> <fileset dir="src/web"/> </copy> - <copy todir="${web-classfiles}"> + <copy todir="${web-conf}"> <fileset dir="conf"> <include name="*.cfg"/> </fileset> </copy> - <copy todir="${web-classfiles}"> + <copy todir="${web-conf}"> <fileset dir="obo-files" /> </copy> </target> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-08-09 22:18:09 UTC (rev 89) +++ phenote/trunk/conf/initial-zfin.cfg 2006-08-14 13:16:51 UTC (rev 90) @@ -1,4 +1,4 @@ -<phenote-configuration version="0.4"> +<phenote-configuration version="0.6"> <data-adapter name="phenoxml"/> Modified: phenote/trunk/src/java/phenote/gui/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/gui/Phenote.java 2006-08-09 22:18:09 UTC (rev 89) +++ phenote/trunk/src/java/phenote/gui/Phenote.java 2006-08-14 13:16:51 UTC (rev 90) @@ -16,7 +16,7 @@ public class Phenote { - private static final String VERSION = "0.6 dev"; + private static final String VERSION = "0.6"; //private static final String DEFAULT_CONFIG_FILE = Config.DEFAULT_CONFIG_FILE; private CharacterTablePanel characterTablePanel; Modified: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-09 22:18:09 UTC (rev 89) +++ phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-14 13:16:51 UTC (rev 90) @@ -40,7 +40,8 @@ } - /** this should be done in java server faces/pages(?), post comes from ajax + /** AUTO COMPLETE REQUEST + this should be done in java server faces/pages(?), post comes from ajax autocompleter on typing in stuff */ public void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { @@ -65,7 +66,7 @@ // "test</li>\n<li onmouseover=\"set_ontology()\" id=\"termId\" onclick=\"set_ontology()\">dude</li></ul>"; String ontol = getOntologyParamString(request); String list = getCompletionList(userInput,ontol); - int sz = (list.length() <= 85) ? list.length() : 85; + int sz = (list.length() <= 85) ? list.length() : 85; System.out.println("printing to response writer: "+list.substring(0,sz)+"..."); out.println(list); } @@ -78,9 +79,9 @@ /** this should be renamed from unintuitive "ontologyname" */ private String getTermCompletionParam(HttpServletRequest req) { - String par = req.getParameter("userInput"); // new way - if (par ==null) - par = req.getParameter("patoInput"); // for now + String par = req.getParameter("userInput"); // new way + if (par ==null) + par = req.getParameter("patoInput"); // for now if (par == null) par = req.getParameter("entityInput"); return par; @@ -92,7 +93,8 @@ - /** i cant tell ya why but term info is done with a get and term completion + /** TERM INFO request + i cant tell ya why but term info is done with a get and term completion is done with a post - is there rhyme or reason to this? */ public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { Modified: phenote/trunk/src/web/web.xml =================================================================== --- phenote/trunk/src/web/web.xml 2006-08-09 22:18:09 UTC (rev 89) +++ phenote/trunk/src/web/web.xml 2006-08-14 13:16:51 UTC (rev 90) @@ -12,6 +12,7 @@ <servlet-mapping> <servlet-name>Phenote</servlet-name> - <url-pattern>/Phenote</url-pattern> + <!-- url-pattern>/Phenote</url-pattern --> + <url-pattern>/phenote/Phenote</url-pattern> </servlet-mapping> </web-app> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-08-15 20:35:22
|
Revision: 91 Author: mgibson Date: 2006-08-15 13:35:14 -0700 (Tue, 15 Aug 2006) ViewCVS: http://svn.sourceforge.net/obo/?rev=91&view=rev Log Message: ----------- got entity ontology chooser working for webby phenote! Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/conf/initial-zfin.cfg phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java phenote/trunk/src/web/html/ncbo.html Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-08-14 13:16:51 UTC (rev 90) +++ phenote/trunk/build.xml 2006-08-15 20:35:14 UTC (rev 91) @@ -47,17 +47,19 @@ <exclude name="META-INF"/> </fileset> </path> + <path id="project.classpath3"> <fileset dir="${lib}"> <patternset id="non-phenote-jars"> <include name="**/*.jar"/> <exclude name="**/phenote.jar"/> + <exclude name="test/**"/> </patternset> </fileset> </path> <!-- The compile target runs javac on all the java files, and saves - them into the classfiles directory. --> + them into the classfiles directory. excludes="test/**" --> <target name="compile" depends="init"> <javac srcdir="${src}" destdir="${classfiles}" debug="yes" excludes="test/**"> <classpath refid="project.classpath3"/> @@ -67,7 +69,7 @@ <!-- runs off classfiles not jar, todo: run-jar --> <target name="run" depends="compile"> - <java classname="phenote.gui.Phenote" fork="yes" jvmargs="-Xmx200M"> + <java classname="phenote.gui.Phenote" fork="yes" jvmargs="-Xmx120M"> <!-- arg value="-c configfilehereventually"/ --> <classpath> <pathelement path="${classfiles}"/> @@ -194,7 +196,7 @@ </target> <target name="compile-servlet"> - <javac srcdir="${src}" destdir="${web-classfiles}" debug="yes"> + <javac srcdir="${src}" destdir="${web-classfiles}" debug="yes" excludes="test/**"> <classpath refid="project.classpath3"/> </javac> </target> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-08-14 13:16:51 UTC (rev 90) +++ phenote/trunk/conf/initial-zfin.cfg 2006-08-15 20:35:14 UTC (rev 91) @@ -4,7 +4,10 @@ <genetic-context file="context.obo"/> - <entity name="Anatomy" file="zebrafish_anatomy.obo"/> + <entity name="Entity"> + <ontology name="Anatomy" file="zebrafish_anatomy.obo" /> + <ontology name="GO" file="gene_ontology.obo"/> + </entity> <pato file="quality.obo"/> Modified: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-14 13:16:51 UTC (rev 90) +++ phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-15 20:35:14 UTC (rev 91) @@ -55,7 +55,7 @@ if (isTermCompletionRequest(request)) { String userInput = getTermCompletionParam(request); - System.out.println("ontology? "+getOntologyParamString(request)+" param entityInput? "+request.getParameter("entityInput")); + System.out.println("ontology? "+getOntologyParamString(request)+" param entityInput? "+getTermCompletionParam(request)); //ResourceBundle r=ResourceBundle.getBundle("LocalStrings",request.getLocale()); //Content-Type: text/html; charset=ISO-8859-1 response.setContentType("text/html"); @@ -139,7 +139,7 @@ // for now just grab the pato ontology - eventuall redo for multiple/config Ontology ontology = getOntology(ontol); if (ontology == null) { - System.out.println("failed to get pato from ontology manager"); + System.out.println("failed to get "+ontol+" from ontology manager"); return "ontology retrieval failed"; } Vector<OBOClass> v = ontology.getSearchTerms(userInput,getSearchParams()); Modified: phenote/trunk/src/web/html/ncbo.html =================================================================== --- phenote/trunk/src/web/html/ncbo.html 2006-08-14 13:16:51 UTC (rev 90) +++ phenote/trunk/src/web/html/ncbo.html 2006-08-15 20:35:14 UTC (rev 91) @@ -23,13 +23,14 @@ <script type="text/javascript"> function setEntityOntology(selectedOntology) { if (selectedOntology == 'AO') { - ontologyName = 'ZFA'; + ontologyName = 'Anatomy'; <!-- ZFA --> } else if (selectedOntology == 'GO') { ontologyName = 'GO'; } - entityAutoCompleter.options.parameters = "ontologyName=" + ontologyName; - alert(entityAutoCompleter.options.parameters); +<!-- entityAutoCompleter.options.parameters = "ontologyName=" + ontologyName; --> + entityAutoCompleter.options.defaultParams = "ontologyName=" + ontologyName; + alert(entityAutoCompleter.options.defaultParams); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-08-22 18:19:55
|
Revision: 93 Author: mgibson Date: 2006-08-22 11:19:35 -0700 (Tue, 22 Aug 2006) ViewCVS: http://svn.sourceforge.net/obo/?rev=93&view=rev Log Message: ----------- refactored configuration now does generic fields rather than specific entity, genetic context elements using xml beans to parse config instead of DOM uses phenoteconfigbeans jar generated from xsd from rnc for phenote config (ill commit those in a second) "pato" changed to "Quality" fixed test suite with new quality ontology Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/conf/initial-flybase.cfg phenote/trunk/conf/initial-zfin.cfg phenote/trunk/conf/obd.cfg phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java phenote/trunk/src/java/phenote/datamodel/CharField.java phenote/trunk/src/java/phenote/datamodel/Character.java phenote/trunk/src/java/phenote/datamodel/CharacterI.java phenote/trunk/src/java/phenote/gui/CharFieldGui.java phenote/trunk/src/java/phenote/gui/Phenote.java phenote/trunk/src/java/phenote/gui/TermPanel.java phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java phenote/trunk/src/java/test/phenote/gui/TestPhenote.java Added Paths: ----------- phenote/trunk/jars/phenoteconfigbeans.jar Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/build.xml 2006-08-22 18:19:35 UTC (rev 93) @@ -241,7 +241,16 @@ </war> </target> + <taskdef name="xmlbean" classname="org.apache.xmlbeans.impl.tool.XMLBean" classpath="${lib}/xbean.jar" /> +<!-- classgendir="${build.dir}" - if not doing jar but classes, schema is directory +where xsd files are (conf) --> + <target name="xml-beans"> + <xmlbean schema="${conf}" destfile="${lib}/phenotexmlbeans.jar" classpath="${project.classpath3}" + failonerror="true" javasource="1.5" > + </xmlbean> + </target> + </project> Modified: phenote/trunk/conf/initial-flybase.cfg =================================================================== --- phenote/trunk/conf/initial-flybase.cfg 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/conf/initial-flybase.cfg 2006-08-22 18:19:35 UTC (rev 93) @@ -1,14 +1,16 @@ -<phenote-configuration version="0.6"> +<phenote-configuration version="0.7" xmlns="phenote/config/xml"> <data-adapter name="phenoxml"/> - <genetic-context file="context.obo"/> + <field name="Genotype" type="free_text"/> - <entity name="Anatomy" file="fly_anatomy.obo"/> + <field name="Genetic Context" file="context.obo"/> - <pato file="quality.obo"/> + <field name="Entity" file="fly_anatomy.obo"/> + <field name="Quality" file="quality.obo"/> + </phenote-configuration> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/conf/initial-zfin.cfg 2006-08-22 18:19:35 UTC (rev 93) @@ -1,15 +1,17 @@ -<phenote-configuration version="0.6"> +<phenote-configuration version="0.7" xmlns="phenote/config/xml"> <data-adapter name="phenoxml"/> - <genetic-context file="context.obo"/> + <field name="Genotype" type="free_text"/> - <entity name="Entity"> + <field name="Genetic Context" file="context.obo"/> + + <field name="Entity"> <ontology name="Anatomy" file="zebrafish_anatomy.obo" /> <ontology name="GO" file="gene_ontology.obo"/> - </entity> + </field> - <pato file="quality.obo"/> + <field name="Quality" file="quality.obo"/> Modified: phenote/trunk/conf/obd.cfg =================================================================== --- phenote/trunk/conf/obd.cfg 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/conf/obd.cfg 2006-08-22 18:19:35 UTC (rev 93) @@ -1,17 +1,16 @@ -<phenote-configuration version="0.4"> +<phenote-configuration version="0.7" xmlns="phenote/config/xml"> <data-adapter name="phenoxml"/> - <genetic-context file="context.obo"/> - <entity name="Entity"> + <field name="Genetic Context" file="context.obo"/> + + <field name="Entity"> <ontology name="Anatomy" file="fly_anatomy.obo" /> <ontology name="GO" file="gene_ontology.obo"/> - </entity> + </field> - <pato file="quality.obo"/> + <field name="Quality" file="quality.obo"/> - - </phenote-configuration> Added: phenote/trunk/jars/phenoteconfigbeans.jar =================================================================== (Binary files differ) Property changes on: phenote/trunk/jars/phenoteconfigbeans.jar ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/config/Config.java 2006-08-22 18:19:35 UTC (rev 93) @@ -1,9 +1,11 @@ package phenote.config; import java.io.IOException; +import java.io.File; import java.io.FileNotFoundException; import java.util.ArrayList; import java.util.List; +import java.net.MalformedURLException; import java.net.URL; import javax.xml.parsers.DocumentBuilder; @@ -15,6 +17,14 @@ import org.w3c.dom.NodeList; import org.xml.sax.SAXException; +import org.apache.xmlbeans.XmlException; +// in phenoteconfigbeans.jar code generate xml beans +import phenote.config.xml.PhenoteConfigurationDocument; +import phenote.config.xml.PhenoteConfigurationDocument.PhenoteConfiguration; +import phenote.config.xml.DataadapterDocument.Dataadapter; +import phenote.config.xml.FieldDocument.Field; +import phenote.config.xml.OntologyDocument.Ontology; + import phenote.datamodel.CharField.CharFieldEnum; import phenote.dataadapter.DataAdapterI; import phenote.dataadapter.fly.FlybaseDataAdapter; @@ -27,13 +37,14 @@ private String configFile = DEFAULT_CONFIG_FILE; //private String patoFile = "attribute_and_values.obo"; // default value //private OntologyConfig patoConfig; - private FieldConfig patoConfig; + //private FieldConfig patoConfig; private FieldConfig lumpConfig = new FieldConfig(CharFieldEnum.LUMP,"Genotype"); //private String lumpOntologyFile = null; private OntologyConfig lumpConfig = new OntologyConfig("Genotype"); //private List<OntologyConfig> entityConfigList = new ArrayList<OntologyConfig>(); - private FieldConfig entityConfig; - private FieldConfig geneticContextConfig; + //private FieldConfig entityConfig; + //private FieldConfig geneticContextConfig; private List<DataAdapterI> dataAdapterList; + private List<FieldConfig> fieldList = new ArrayList<FieldConfig>(); /** singleton */ private Config() { @@ -43,7 +54,8 @@ public void setConfigFile(String configFile) { this.configFile = configFile; // ?? System.out.println("Attempting to read config from "+configFile); - parseXmlFile(configFile); // do parse here? + //parseXmlFileWithDom(configFile); // do parse here? + parseXmlFile(configFile); } public static Config inst() { @@ -84,48 +96,48 @@ return lumpConfig.getOntologyConfig(); } - public OntologyConfig getPatoOntologyConfig() { - return getPatoConfig().getOntologyConfig(); - } +// public OntologyConfig getPatoOntologyConfig() { +// return getPatoConfig().getOntologyConfig(); +// } /** paot config should always be present, make default if not set from xml */ - private FieldConfig getPatoConfig() { - if (patoConfig == null) { - System.out.println("error pato config is null, making default"); - OntologyConfig o = OntologyConfig.defaultPato; - patoConfig = new FieldConfig(CharFieldEnum.PATO,o); - } - return patoConfig; - } +// private FieldConfig getPatoConfig() { +// if (patoConfig == null) { +// System.out.println("error pato config is null, making default"); +// OntologyConfig o = OntologyConfig.defaultPato; +// patoConfig = new FieldConfig(CharFieldEnum.PATO,o); +// } +// return patoConfig; +// } - public boolean hasGeneticContextField() { - return geneticContextConfig != null; - } +// public boolean hasGeneticContextField() { +// return geneticContextConfig != null; +// } - public OntologyConfig getGeneticContextOntologyConfig() { - if (!hasGeneticContextField()) return null; - return getGeneticContextConfig().getOntologyConfig(); // check if has ont? - } +// public OntologyConfig getGeneticContextOntologyConfig() { +// if (!hasGeneticContextField()) return null; +// return getGeneticContextConfig().getOntologyConfig(); // check if has ont? +// } - public FieldConfig getGeneticContextConfig() { - return geneticContextConfig; - } +// public FieldConfig getGeneticContextConfig() { +// return geneticContextConfig; +// } - private void initGeneticContextConfig(OntologyConfig oc) { - geneticContextConfig = new FieldConfig(CharFieldEnum.GENETIC_CONTEXT,oc); - } +// private void initGeneticContextConfig(OntologyConfig oc) { +// geneticContextConfig = new FieldConfig(CharFieldEnum.GENETIC_CONTEXT,oc); +// } - private FieldConfig getEntityConfig() { - if (entityConfig == null) - entityConfig = new FieldConfig(CharFieldEnum.ENTITY,"Entity"); - return entityConfig; - } +// private FieldConfig getEntityConfig() { +// if (entityConfig == null) +// entityConfig = new FieldConfig(CharFieldEnum.ENTITY,"Entity"); +// return entityConfig; +// } - public List<OntologyConfig> getEntityOntologyConfigs() { -// if (entityConfigList.isEmpty()) entityConfigList = defaultEntityConfigList(); -// return entityConfigList; - return getEntityConfig().getOntologyConfigList(); - } +// public List<OntologyConfig> getEntityOntologyConfigs() { +// // if (entityConfigList.isEmpty()) entityConfigList = defaultEntityConfigList(); +// // return entityConfigList; +// return getEntityConfig().getOntologyConfigList(); +// } public int getNumberOfFields() { return getFieldConfigList().size(); @@ -144,34 +156,35 @@ return getFieldConfig(index).getCharFieldEnum(); } + /** needed for getFieldLabel for table */ private FieldConfig getFieldConfig(int index) { return getFieldConfigList().get(index); } - private List<FieldConfig> fieldList; + /** OntologyDataAdapter calls this to figure which ontologies to load */ public List<FieldConfig> getFieldConfigList() { - if (fieldList == null) - initFieldConfigList(); +// if (fieldList == null) +// initFieldConfigList(); return fieldList; } - // refactor! - just have it come straight from xml parse! - private void initFieldConfigList() { - fieldList = new ArrayList<FieldConfig>(); - if (hasLumpField()) { - fieldList.add(getLumpConfig()); - } - if (hasGeneticContextField()) { - fieldList.add(getGeneticContextConfig()); - } - // entity config should always be present shouldnt it? - fieldList.add(getEntityConfig()); - fieldList.add(getPatoConfig()); // pato required - } +// // refactor! - just have it come straight from xml parse! +// private void initFieldConfigList() { +// //fieldList = new ArrayList<FieldConfig>(); +// if (hasLumpField()) { +// fieldList.add(getLumpConfig()); +// } +// if (hasGeneticContextField()) { +// fieldList.add(getGeneticContextConfig()); +// } +// // entity config should always be present shouldnt it? +// fieldList.add(getEntityConfig()); +// fieldList.add(getPatoConfig()); // pato required +// } - /** Default entity list is the anatomy ontology */ + /** Default entity list is the anatomy ontology -- DELETE*/ private List<OntologyConfig> defaultEntityConfigList() { OntologyConfig oc = new OntologyConfig("Anatomy","anatomy.obo"); List<OntologyConfig> l = new ArrayList<OntologyConfig>(1); @@ -179,190 +192,284 @@ return l; } - /** Throws ParserConfig,SAXEx, & IOException if problems - sep class? */ - private Document getDocument(String filename) throws Exception { - DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); - DocumentBuilder builder = dbf.newDocumentBuilder(); - Document document = tryFile(builder,filename); - if (document == null) - document = tryFile(builder,"conf/"+filename); - if (document == null) { // try jar file - URL url = Config.class.getResource(filename); - if (url == null) - System.out.println("failed to get file from jar without '/' prepend"); - else - document = tryFile(builder,url.toString()); + + /** parse xml file with xml beans (phenoteconfigbeans.xml). Put in own class? */ + private void parseXmlFile(String filename) { + try { + URL configUrl = getConfigUrl(filename); + System.out.println("config file: "+configUrl); + PhenoteConfigurationDocument pcd = + PhenoteConfigurationDocument.Factory.parse(configUrl);//configFile); + PhenoteConfiguration pc = pcd.getPhenoteConfiguration(); + Dataadapter[] adapters = pc.getDataadapterArray(); + for (Dataadapter da : adapters) { + String name = da.getName().toString(); + addDataAdapterFromString(name); + } + + Field[] fields = pc.getFieldArray(); + for (Field f : fields) { + //String name = f.getName().getStringValue(); + //String file = f.getFile().getStringValue(); + makeFieldConfig(f); + } + } - // hmmmm - so ontology data adapter prepends "/" for jar file but above - // doesnt (which seems to work for web start but not jboss) try with - // prepended slash as well - what the heck - // its true this works for jboss - above for webstart - very strange - if (document == null) { - URL url = Config.class.getResource("/"+filename); - if (url == null) - System.out.println("failed to get file from jar with '/' prepend"); - else - document = tryFile(builder,url.toString()); + catch (IOException ie) { + System.out.println("IOException on config parse "+ie); } - - if (document == null) { - System.out.println("Failed to find config file "+filename); - throw new FileNotFoundException(filename); + catch (XmlException xe) { + System.out.println("Parse of config xml file failed "+xe); } - return document; } - /** Returns null if cant find file, throws exception if parse fails */ - private Document tryFile(DocumentBuilder builder, String uri) throws Exception { - if (uri == null) return null; - Document document = null; + private URL getConfigUrl(String filename) throws FileNotFoundException { + List<URL> possibleUrls = getPossibleUrls(filename); + for (URL u : possibleUrls) + if (urlExists(u)) return u; + System.out.println("Failed to find file "+filename); + throw new FileNotFoundException(filename+" not found"); + } + + private List<URL> getPossibleUrls(String filename) { + List<URL> urls = new ArrayList(5); try { - document = builder.parse(uri); + urls.add(new File(filename).toURL()); + urls.add(new File("conf/"+filename).toURL()); + } catch (MalformedURLException e) { + System.out.println("bad file url "+e); } - catch (FileNotFoundException e) { - return null; - } - return document; + urls.add(Config.class.getResource(filename)); + urls.add(Config.class.getResource("/"+filename)); + return urls; } - // do this with xml beans & xsd of config? - private void parseXmlFile(String filename) { - Document document=null; - try { - document = getDocument(filename); - } catch (Exception e) { - System.out.println("Xml config parse error: "+e); - e.printStackTrace(); - return; + private boolean urlExists(URL u) { + try { u.openStream(); } + catch (IOException e) { return false; } + //System.out.println("url suceeded "+u); + return true; + } + + // do some other way? DataAdapterManager has mapping? DataAdapter has mapping? + // DataAdapterManager.getAdapter(name)??? + private void addDataAdapterFromString(String daString) { + if (daString.equalsIgnoreCase("flybase")) + addDataAdapter(new FlybaseDataAdapter()); // for now... + else if (daString.equalsIgnoreCase("phenoxml")) + addDataAdapter(new PhenoXmlAdapter()); + } + + private void addDataAdapter(DataAdapterI da) { + if (dataAdapterList == null) + dataAdapterList = new ArrayList<DataAdapterI>(3); + dataAdapterList.add(da); + } + + private void makeFieldConfig(Field field) { + String name = field.getName().getStringValue(); + //String file = field.getFile().getStringValue(); + // has to be a valid value + CharFieldEnum cfe = CharFieldEnum.getCharFieldEnum(name); + //if (cfe == null) ??? + FieldConfig fc = new FieldConfig(cfe,name); + // if only one ontology file is an attribute... (convenience) + if (field.getFile() != null) { + String file = field.getFile().getStringValue(); + fc.addOntologyConfig(makeOntologyConfig(name,file)); } - Element root = document.getDocumentElement(); - NodeList kids = root.getChildNodes(); - int size = kids.getLength(); - for (int i=0; i<size; i++) { - Node node = kids.item(i); - parsePato(node); // if not pato does nothing - parseEntity(node); - parseGeneticContext(node); - parseDataAdapter(node); + // otherwise its multiple ontologies listed in ontology elements (entity) + else { + Ontology[] ontologies = field.getOntologyArray(); + for (Ontology o : ontologies) { + String oName = o.getName().getStringValue(); + String oFile = o.getFile().getStringValue(); + OntologyConfig oc = makeOntologyConfig(oName,oFile); + fc.addOntologyConfig(oc); + } } + fieldList.add(fc); } + + + private OntologyConfig makeOntologyConfig(String name, String file) { + OntologyConfig oc = new OntologyConfig(name,file); + return oc; + } + +} + +// OLD OLD OLD - DELETE - DOM STUFF - replaced with xml beans + +// /** Throws ParserConfig,SAXEx, & IOException if problems - sep class? */ +// private Document getDocument(String filename) throws Exception { +// DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); +// DocumentBuilder builder = dbf.newDocumentBuilder(); +// Document document = tryFile(builder,filename); +// if (document == null) +// document = tryFile(builder,"conf/"+filename); +// if (document == null) { // try jar file +// URL url = Config.class.getResource(filename); +// // hmmmm - so ontology data adapter prepends "/" for jar file but above +// // doesnt (which seems to work for web start but not jboss) try with +// // prepended slash as well - what the heck +// // its true this works for jboss - above for webstart - very strange +// if (url == null) +// url = Config.class.getResource("/"+filename); +// if (url == null) +// System.out.println("failed to get file from jar with or without '/' prepend"); +// else +// document = tryFile(builder,url.toString()); +// } + +// if (document == null) { +// System.out.println("Failed to find config file "+filename); +// throw new FileNotFoundException(filename); +// } +// return document; +// } + +// /** Returns null if cant find file, throws exception if parse fails */ +// private Document tryFile(DocumentBuilder builder, String uri) throws Exception { +// if (uri == null) return null; +// Document document = null; +// try { +// document = builder.parse(uri); +// } +// catch (FileNotFoundException e) { +// return null; +// } +// return document; +// } + +// // do this with xml beans & xsd of config? +// private void parseXmlFileWithDom(String filename) { +// Document document=null; +// try { +// document = getDocument(filename); +// } catch (Exception e) { +// System.out.println("Xml config parse error: "+e); +// e.printStackTrace(); +// return; +// } +// Element root = document.getDocumentElement(); +// NodeList kids = root.getChildNodes(); +// int size = kids.getLength(); +// for (int i=0; i<size; i++) { +// Node node = kids.item(i); +// parsePato(node); // if not pato does nothing +// parseEntity(node); +// parseGeneticContext(node); +// parseDataAdapter(node); +// } +// } + // private void parseLump(Node node) ... // return true if sucessfully parsed? - private void parsePato(Node node) { - if (!node.getNodeName().equals("pato")) return; - OntologyConfig oc = makeOntologyConfig(node,"Pato"); - //getPatoConfig().addOntologyConfig(oc); - patoConfig = new FieldConfig(CharFieldEnum.PATO,oc); - } +// private void parsePato(Node node) { +// if (!node.getNodeName().equals("pato")) return; +// OntologyConfig oc = makeOntologyConfig(node,"Pato"); +// //getPatoConfig().addOntologyConfig(oc); +// patoConfig = new FieldConfig(CharFieldEnum.PATO,oc); +// } - private void parseEntity(Node node) { - if (!node.getNodeName().equals("entity")) return; +// private void parseEntity(Node node) { +// if (!node.getNodeName().equals("entity")) return; - // while (hasMoreOntologies(node) ??? na! +// // while (hasMoreOntologies(node) ??? na! - // List <OntologyConfig> getOntologyConfigs(node) {} +// // List <OntologyConfig> getOntologyConfigs(node) {} - makeOntologyConfigs(node,getEntityConfig()); - //getEntityConfig().addOntologyConfig(oc); - //getEntityConfig().setOntologyConfigs(configs); - //entityConfigList.add(fc); - } +// makeOntologyConfigs(node,getEntityConfig()); +// //getEntityConfig().addOntologyConfig(oc); +// //getEntityConfig().setOntologyConfigs(configs); +// //entityConfigList.add(fc); +// } - private void parseGeneticContext(Node node) { - if (!node.getNodeName().equals("genetic-context")) return; - OntologyConfig oc = makeOntologyConfig(node,"Genetic Context"); - initGeneticContextConfig(oc); - // check if has ontology? - //getGeneticContextConfig().addOntologyConfig(oc); - } +// private void parseGeneticContext(Node node) { +// if (!node.getNodeName().equals("genetic-context")) return; +// OntologyConfig oc = makeOntologyConfig(node,"Genetic Context"); +// initGeneticContextConfig(oc); +// // check if has ontology? +// //getGeneticContextConfig().addOntologyConfig(oc); +// } - /** Return null if node doesnt actually have ontology info - like if there - is no file attribute which is required */ - private OntologyConfig makeOntologyConfig(Node node, String defaultName) { - String name = getNameAttribute(node); - if (name == null || name.equals("")) - name = defaultName; - // if field only has one ontology - if (!hasFileAttribute(node)) - return null; +// /** Return null if node doesnt actually have ontology info - like if there +// is no file attribute which is required */ +// private OntologyConfig makeOntologyConfig(Node node, String defaultName) { +// String name = getNameAttribute(node); +// if (name == null || name.equals("")) +// name = defaultName; +// // if field only has one ontology +// if (!hasFileAttribute(node)) +// return null; - String file = getFileAttribute(node); +// String file = getFileAttribute(node); - OntologyConfig oc = new OntologyConfig(name,file); - return oc; - } +// return makeOntologyConfig(name,file); +// } - /** so this is funny but the field node may contain info on a single ontology - or it may contain ontology kid nodes, in the case it has multiple ontolgies - like entity */ - private void makeOntologyConfigs(Node fieldNode, FieldConfig fieldConfig) { - String name = getNameAttribute(fieldNode); - if (name == null || name.equals("")) - name = fieldConfig.getLabel(); +// /** so this is funny but the field node may contain info on a single ontology +// or it may contain ontology kid nodes, in the case it has multiple ontolgies +// like entity */ +// private void makeOntologyConfigs(Node fieldNode, FieldConfig fieldConfig) { +// String name = getNameAttribute(fieldNode); +// if (name == null || name.equals("")) +// name = fieldConfig.getLabel(); - // if field only has one ontology will be specified in node attribs - OntologyConfig oc = makeOntologyConfig(fieldNode,name); - if (oc != null) - fieldConfig.addOntologyConfig(oc); // return? +// // if field only has one ontology will be specified in node attribs +// OntologyConfig oc = makeOntologyConfig(fieldNode,name); +// if (oc != null) +// fieldConfig.addOntologyConfig(oc); // return? - // see if theres mutliple ontologies specified as ontology elements - NodeList kids = fieldNode.getChildNodes(); - for (int i=0; i<kids.getLength(); i++) { - Node node = kids.item(i); - if (node.getNodeName().equals("ontology")) { - oc = makeOntologyConfig(node,name); - fieldConfig.addOntologyConfig(oc); - } - } - } +// // see if theres mutliple ontologies specified as ontology elements +// NodeList kids = fieldNode.getChildNodes(); +// for (int i=0; i<kids.getLength(); i++) { +// Node node = kids.item(i); +// if (node.getNodeName().equals("ontology")) { +// oc = makeOntologyConfig(node,name); +// fieldConfig.addOntologyConfig(oc); +// } +// } +// } - private boolean hasFileAttribute(Node node) { - return hasContent(getFileAttribute(node)); - } +// private boolean hasFileAttribute(Node node) { +// return hasContent(getFileAttribute(node)); +// } - private boolean hasContent(String s) { - return s != null && !s.equals(""); - } +// private boolean hasContent(String s) { +// return s != null && !s.equals(""); +// } - private String getFileAttribute(Node node) { - return getAttribute(node,"file"); - } +// private String getFileAttribute(Node node) { +// return getAttribute(node,"file"); +// } - private String getNameAttribute(Node node) { - return getAttribute(node,"name"); - } +// private String getNameAttribute(Node node) { +// return getAttribute(node,"name"); +// } - /** Returns null if node is not element, or attrib not attribute */ - private String getAttribute(Node node, String attrib) { - Element element = elementCast(node); - if (element == null) return null; - return element.getAttribute(attrib); - } +// /** Returns null if node is not element, or attrib not attribute */ +// private String getAttribute(Node node, String attrib) { +// Element element = elementCast(node); +// if (element == null) return null; +// return element.getAttribute(attrib); +// } - private Element elementCast(Node node) { - if (node instanceof Element) - return (Element)node; - System.out.println("Config xml parsing error, expected element " - +node.getNodeName()); - return null; // throw exception? - } +// private Element elementCast(Node node) { +// if (node instanceof Element) +// return (Element)node; +// System.out.println("Config xml parsing error, expected element " +// +node.getNodeName()); +// return null; // throw exception? +// } - private void parseDataAdapter(Node node) { - if (!node.getNodeName().equals("data-adapter")) return; - String name = getNameAttribute(node); - // do some other way? DataAdapterManager has mapping? DataAdapter has mapping? - // DataAdapterManager.getAdapter(name)??? - if (name.equalsIgnoreCase("flybase")) - addDataAdapter(new FlybaseDataAdapter()); // for now... - else if (name.equalsIgnoreCase("phenoxml")) - addDataAdapter(new PhenoXmlAdapter()); - } +// private void parseDataAdapter(Node node) { +// if (!node.getNodeName().equals("data-adapter")) return; +// String name = getNameAttribute(node); +// addDataAdapterFromString(name); +// } - private void addDataAdapter(DataAdapterI da) { - if (dataAdapterList == null) - dataAdapterList = new ArrayList<DataAdapterI>(3); - dataAdapterList.add(da); - } -} +//} Modified: phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java 2006-08-22 18:19:35 UTC (rev 93) @@ -55,7 +55,7 @@ if (key.equals(ENTITY)) character.setEntity(oboClass); else if (key.equals(VALUE)) - character.setPato(oboClass); + character.setQuality(oboClass); else if (key.equals(GENETIC_CONTEXT)) character.setGeneticContext(oboClass); } @@ -97,7 +97,7 @@ StringBuffer sb = new StringBuffer(); sb.append(ENTITY).append(" > ").append(termString(character.getEntity())); sb.append("|"); - sb.append(VALUE).append(" > ").append(termString(character.getPato())); + sb.append(VALUE).append(" > ").append(termString(character.getQuality())); if (character.hasGeneticContext()) { sb.append("|"); sb.append(GENETIC_CONTEXT).append(" > "); Modified: phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java 2006-08-22 18:19:35 UTC (rev 93) @@ -108,13 +108,13 @@ System.out.println("Character "+chr+" has no entity"); } - if (chr.getPato() != null) { + if (chr.getQuality() != null) { Quality q = pc.addNewQuality(); Typeref trq = q.addNewTyperef(); - trq.setAbout(chr.getPato().getID()); + trq.setAbout(chr.getQuality().getID()); } else { - System.out.println("Character "+chr+" has no quality(pato)"); + System.out.println("Character "+chr+" has no quality"); } } } Modified: phenote/trunk/src/java/phenote/datamodel/CharField.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-08-22 18:19:35 UTC (rev 93) @@ -37,12 +37,12 @@ return new CharFieldValue(c.getEntity(),c,this); } }, - PATO("Pato") { + QUALITY("Quality") { public void setValue(CharacterI c, CharFieldValue v) { - c.setPato(v.getOboClass()); + c.setQuality(v.getOboClass()); } public CharFieldValue getValue(CharacterI c) { - return new CharFieldValue(c.getPato(),c,this); + return new CharFieldValue(c.getQuality(),c,this); } }; @@ -52,20 +52,22 @@ public abstract void setValue(CharacterI c, CharFieldValue v); public abstract CharFieldValue getValue(CharacterI c); - // uncler if we need this??? -// public CharFieldEnum getCharFieldEnum(String fieldString) { -// for ( CharFieldEnum cfe : CharFieldEnum.values()) { -// if (cfe.name.equalsIgnoreCase(fieldString)) -// return cfe; -// } -// System.out.println("ERROR: No Char Field found for string "+fieldString); -// return null; -// } // is this getting silly? abstract? --> char field value i think //public void setOboClass(CharacterI c, OBOClass o) {} //public OBOClass getOBOClass(CharacterI c) { return null; } + + // unclear if we need this??? need it in generic field config + public static CharFieldEnum getCharFieldEnum(String fieldString) { + for ( CharFieldEnum cfe : CharFieldEnum.values()) { + if (cfe.name.equalsIgnoreCase(fieldString)) + return cfe; + } + System.out.println("ERROR: No Char Field found for string "+fieldString); + return null; + } }; + private List<Ontology> ontologyList = new ArrayList<Ontology>(3); private CharFieldEnum charFieldEnum; // or subclass private String name; Modified: phenote/trunk/src/java/phenote/datamodel/Character.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/Character.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/datamodel/Character.java 2006-08-22 18:19:35 UTC (rev 93) @@ -7,17 +7,17 @@ public class Character implements CharacterI, Cloneable { // private String entity=""; -// private String pato=""; +// private String quality=""; // private String geneticContext=""; private String genotype=""; // eventually Genotype class // OboClass? OntologyTerm?... private OBOClass entity; // CharFieldValue? - private OBOClass pato; + private OBOClass quality; private OBOClass geneticContext; public String getGenotype() { return genotype; } public OBOClass getEntity() { return entity; } - public OBOClass getPato() { return pato; } + public OBOClass getQuality() { return quality; } public boolean hasGeneticContext() { return geneticContext!=null && !geneticContext.equals(""); } @@ -25,18 +25,18 @@ // convenience functions public String getEntityName() { return entity.getName(); } - public String getPatoName() { return pato.getName(); } + public String getQualityName() { return quality.getName(); } public String getGeneticContextName() { return geneticContext.getName(); } public void setGenotype(String gt) { genotype = gt; } public void setEntity(OBOClass e) { entity = e; } - public void setPato(OBOClass p) { pato = p; } + public void setQuality(OBOClass p) { quality = p; } public void setGeneticContext(OBOClass gc) { geneticContext = gc; } public boolean equals(CharacterI ch) { return eq(genotype,ch.getGenotype()) && eq(entity,ch.getEntity()) - && eq(pato,ch.getPato()) && eq(geneticContext,ch.getGeneticContext()); + && eq(quality,ch.getQuality()) && eq(geneticContext,ch.getGeneticContext()); } /** check if both are null in addition to .equals() */ Modified: phenote/trunk/src/java/phenote/datamodel/CharacterI.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-08-22 18:19:35 UTC (rev 93) @@ -7,19 +7,19 @@ public interface CharacterI { public String getEntityName(); - public String getPatoName(); // OBOClass? + public String getQualityName(); // OBOClass? public String getGeneticContextName(); public String getGenotype(); public OBOClass getEntity(); - public OBOClass getPato(); // OBOClass? + public OBOClass getQuality(); // OBOClass? public boolean hasGeneticContext(); public OBOClass getGeneticContext(); /** eventually have Genotype object? probably */ public void setGenotype(String gt); public void setEntity(OBOClass e); - public void setPato(OBOClass p); + public void setQuality(OBOClass p); public void setGeneticContext(OBOClass gc); public CharacterI cloneCharacter(); Modified: phenote/trunk/src/java/phenote/gui/CharFieldGui.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharFieldGui.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/gui/CharFieldGui.java 2006-08-22 18:19:35 UTC (rev 93) @@ -65,6 +65,13 @@ boolean isCombo() { return isCombo; } void setValueFromChar(CharacterI character) { + if (charField == null) return; + if (charField.getCharFieldEnum() == null) { + System.out.println("ERROR: Cant set value for field. Gui for character field has" + +" not been associated with a datamodel field. check field" + +" names in config "); + return; + } String v = charField.getCharFieldEnum().getValue(character).getName(); setText(v); } @@ -158,7 +165,6 @@ private class FieldCharSelectListener implements CharSelectionListener { public void characterSelected(CharSelectionEvent e) { - /// do something... setValueFromChar(e.getCharacter()); } } Modified: phenote/trunk/src/java/phenote/gui/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/gui/Phenote.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/gui/Phenote.java 2006-08-22 18:19:35 UTC (rev 93) @@ -16,7 +16,7 @@ public class Phenote { - private static final String VERSION = "0.6"; + private static final String VERSION = "0.7 dev"; //private static final String DEFAULT_CONFIG_FILE = Config.DEFAULT_CONFIG_FILE; private CharacterTablePanel characterTablePanel; Modified: phenote/trunk/src/java/phenote/gui/TermPanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/TermPanel.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/gui/TermPanel.java 2006-08-22 18:19:35 UTC (rev 93) @@ -25,7 +25,7 @@ import phenote.config.FieldConfig; /** - * TermPanel holds all the fileds for the terms - Genotype, Entity/Anatomy, PATO. + * TermPanel holds all the fileds for the terms - Genotype, Entity/Anatomy, QUALITY. * Can be populated by hand (Genotype), or selection of instance in completion list. rename FieldPanel or CharFieldPanel? also has SearchParamPanel. @@ -122,8 +122,8 @@ return null; } - AutoComboBox getPatoComboBox() { - return getComboBox(CharFieldEnum.PATO); + AutoComboBox getQualityComboBox() { + return getComboBox(CharFieldEnum.QUALITY); } boolean hasLumpComboBox() { //return lumpField.isCombo(); @@ -141,7 +141,7 @@ // void clear() { // lumpField.setText(""); // entityField.setText(""); -// patoField.setText(""); +// qualityField.setText(""); // } // phase out direct connection for event/listener - obo edit stuff? @@ -151,8 +151,8 @@ // private boolean isEntity(String ontology) { // return ontology.equals(ANATOMY); // || GO... // } -// private boolean isPato(String ontology) { -// return ontology.equals(PATO); +// private boolean isQuality(String ontology) { +// return ontology.equals(QUALITY); // } // // this should be made generic to use beyond just genotype? yes yes yes @@ -177,9 +177,9 @@ // } // // change -> mvc -// void setPatoTableColumn(String patoTerm) { +// void setQualityTableColumn(String qualityTerm) { // // characterTablePanel.setSelectedColumn(ontEnum,term)??? -// characterTablePanel.setSelectedPatoTerm(patoTerm); +// characterTablePanel.setSelectedQualityTerm(qualityTerm); // } // /** rename - this sets term in table not field - hardwires from ontology @@ -189,8 +189,8 @@ // private void setTableColumn(String ontology, String term) { // if (isEntity(ontology)) // setEntityTableColumn(term); -// else if (isPato(ontology)) -// setPatoTableColumn(term); +// else if (isQuality(ontology)) +// setQualityTableColumn(term); // else if (ontology.equals(TAXONOMY)) // characterTablePanel.setSelectedGenotype(term); // //... @@ -202,9 +202,9 @@ // } // // change -> mvc -// void setPatoTableColumn(String patoTerm) { +// void setQualityTableColumn(String qualityTerm) { // // characterTablePanel.setSelectedColumn(ontEnum,term)??? -// characterTablePanel.setSelectedPatoTerm(patoTerm); +// characterTablePanel.setSelectedQualityTerm(qualityTerm); // } // /** rename - this sets term in table not field - hardwires from ontology @@ -214,8 +214,8 @@ // private void setTableColumn(String ontology, String term) { // if (isEntity(ontology)) // setEntityTableColumn(term); -// else if (isPato(ontology)) -// setPatoTableColumn(term); +// else if (isQuality(ontology)) +// setQualityTableColumn(term); // else if (ontology.equals(TAXONOMY)) // characterTablePanel.setSelectedGenotype(term); // //... @@ -267,38 +267,38 @@ // return ontologyManager.getEntityOntology(); // } -// private Ontology getPatoOntology() { -// //return new Ontology("Pato","attribute_and_value.obo"); -// return ontologyManager.getPatoOntology(); +// private Ontology getQualityOntology() { +// //return new Ontology("Quality","attribute_and_value.obo"); +// return ontologyManager.getQualityOntology(); // } // lumpField.setText(instance.getGenotype()); // entityField.setText(instance.getEntity()); -// patoField.setText(instance.getPato()); ???????? +// qualityField.setText(instance.getQuality()); ???????? // addLumpField(fieldPanel); // addGeneticContextField(fieldPanel); // if configured... // entityField = new CharFieldGui(getAnatomyOntology(),fieldPanel); -// //patoField = new CharFieldGui(getPatoOntology(),fieldPanel); -// patoField = new CharFieldGui(,fieldPanel); +// //qualityField = new CharFieldGui(getQualityOntology(),fieldPanel); +// qualityField = new CharFieldGui(,fieldPanel); // for (FieldConfig fieldConfig : config.getFieldConfigList() ) // addField(fieldConfig,fieldPanel); but field configs dont have ontologies... // would then have to do something like ontMan.getOntology(fc.getFieldEnum) // for (FieldOntology fieldOntology : ontologyManager.getFieldOntologyList()) // addField(fieldOntology,fieldPanel); // final static String ANATOMY = "Anatomy"; -// final static String PATO = "Pato"; +// final static String QUALITY = "Quality"; // final static String TAXONOMY = "Taxonomy"; // private CharFieldGui lumpField; // private CharFieldGui entityField; -// private CharFieldGui patoField; +// private CharFieldGui qualityField; // private CharFieldGui geneticContextField; // private String getInput(String ontology) { // if (isEntity(ontology)) // return entityField.getText(); -// if (isPato(ontology)) -// return patoField.getText(); +// if (isQuality(ontology)) +// return qualityField.getText(); // return ""; // error? // } // take out editable - always editable @@ -367,12 +367,12 @@ // searchPanel = sp; // // overlay?? home made jcombo - jcombo mac bug - list on top of jtext // // mac bug worked around thank goodness -// //searchPanel.setLocation(patoTextField.getLocation()); +// //searchPanel.setLocation(qualityTextField.getLocation()); // } //comboBox.setEditable(true); //ActionListener a = new AutoActionListener(ontologyString,comboBox); //comboBox.getEditor().addActionListener(a); //comboBox.addActionListener(a); //entityField.getDocument().addDocumentListener(new AutoDocumentListener(ANATOMY)); - //patoTextField = addField("Pato Term",this,true); - //patoTextField.getDocument().addDocumentListener(new AutoDocumentListener(PATO)); + //qualityTextField = addField("Quality Term",this,true); + //qualityTextField.getDocument().addDocumentListener(new AutoDocumentListener(QUALITY)); Modified: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-22 18:19:35 UTC (rev 93) @@ -37,6 +37,8 @@ String[] args = {"-c","initial-zfin.cfg"}; phenote.initConfig(args); // hardwire for now to zfin phenote.initOntologies(); + OntologyFileCheckThread ofct = new OntologyFileCheckThread(); + ofct.run(); } @@ -66,8 +68,7 @@ // "test</li>\n<li onmouseover=\"set_ontology()\" id=\"termId\" onclick=\"set_ontology()\">dude</li></ul>"; String ontol = getOntologyParamString(request); String list = getCompletionList(userInput,ontol); - int sz = (list.length() <= 85) ? list.length() : 85; - System.out.println("printing to response writer: "+list.substring(0,sz)+"..."); + System.out.println("printing to response writer: "+substring(list,55)+"..."); out.println(list); } @@ -118,11 +119,16 @@ System.out.println("term info: no obo class found for "+termId); return; } - System.out.println("term info "+HtmlUtil.termInfo(oboClass)); + System.out.println("term info "+substring(HtmlUtil.termInfo(oboClass),60)); out.println(HtmlUtil.termInfo(oboClass,ontologyName)); } } + private String substring(String s,int sz) { + sz = (s.length() <= sz) ? s.length() : sz; + return s.substring(0,sz); + } + private boolean isTermInfoRequest(HttpServletRequest req) { return getTermIdFromTermInfoRequest(req) != null; } @@ -151,16 +157,16 @@ /** returns null if ontolName not found */ private Ontology getOntology(String ontolName) { // termid?? or ontology name? - //return getPatoOntology(); + //return getQualityOntology(); return OntologyManager.getOntologyForName(ontolName); } // for now... - private Ontology getPatoOntology() { + private Ontology getQualityOntology() { for (CharField cf : OntologyManager.inst().getCharFieldList()) - if (cf.getCharFieldEnum() == CharFieldEnum.PATO) + if (cf.getCharFieldEnum() == CharFieldEnum.QUALITY) return cf.getFirstOntology(); - System.out.println("pato ontology not found in ontology manager"); + System.out.println("quality ontology not found in ontology manager"); return null; } @@ -185,6 +191,22 @@ } + /** thread wakes up and checks if theres a new ontology file - if so loads it + this should go in ontology data adapter... not here and configged */ + private class OntologyFileCheckThread extends Thread { + + public void run() { + + while(true) { + // check for files... + + + // sleep in milliseconds - sleep for 5 seconds for now (test) + //sleep(5000); + } + } + } + } Modified: phenote/trunk/src/java/test/phenote/gui/TestPhenote.java =================================================================== --- phenote/trunk/src/java/test/phenote/gui/TestPhenote.java 2006-08-21 15:49:04 UTC (rev 92) +++ phenote/trunk/src/java/test/phenote/gui/TestPhenote.java 2006-08-22 18:19:35 UTC (rev 93) @@ -36,7 +36,7 @@ private static TermPanel termPanel; private static SearchParamPanel searchParamPanel; private static AutoComboBox entityComboBox; - private static AutoComboBox patoComboBox; + private static AutoComboBox qualityComboBox; private static TermInfo termInfo; private static CharacterTablePanel characterTablePanel; @@ -55,8 +55,8 @@ searchParamPanel = termPanel.getSearchParamPanel(); entityComboBox = termPanel.getEntityComboBox(); entityComboBox.setTestMode(true); // turns off popup, hanging bug only in test - patoComboBox = termPanel.getPatoComboBox(); - patoComboBox.setTestMode(true); + qualityComboBox = termPanel.getQualityComboBox(); + qualityComboBox.setTestMode(true); termInfo = phenote.getTermInfo(); characterTablePanel = phenote.getCharacterTablePanel(); } @@ -69,9 +69,9 @@ comboTermSelectionGoesToTableTest(); synonymDupTest(); termInfoSelectTermTest(); - //attributeInPatoCompletionTest(); --> need 3 keystrokes 'ttr' + //attributeInQualityCompletionTest(); --> need 3 keystrokes 'ttr' //backspaceInComboBoxTest(); cant sim backspace..... - flyDataAdapterTest(); + //flyDataAdapterTest(); out of date its now doing phenoxml - soon will be syntax } private void displayTermInfoOnCompMouseOverTest() { @@ -81,15 +81,15 @@ System.out.println("set entity text to hea"); //entityComboBox.setText("hea",doCompletion); // already have list from l from previous test - for some reason 2nd l doesnt jibe - // even though there are lots of pato terms with 'll' ??? - //patoComboBox.simulateLKeyStroke(); // just does 'l' + // even though there are lots of quality terms with 'll' ??? + //qualityComboBox.simulateLKeyStroke(); // just does 'l' System.out.println("set text - getting 3rd term"); //JList entityJList = entityComboBox.getJList(); // pick 3rd item //String thirdTerm = (String)entityJList.getModel().getElementAt(2); //String thirdTerm = getEntityThirdAutoTerm(); - String thirdTerm = getPatoThirdAutoTerm(); - assertNotNull("3rd term from pato combo shouldnt be null",thirdTerm); + String thirdTerm = getQualityThirdAutoTerm(); + assertNotNull("3rd term from quality combo shouldnt be null",thirdTerm); //entityJList.setSelectedIndex(2); entityComboBox.doMouseOver(2); // 2 is 3rd - 0 indexing @@ -109,18 +109,18 @@ return entityComboBox.getModel().getElementAt(2).toString(); } - private String getPatoThirdAutoTerm() { - assertNotNull(patoComboBox.getModel()); - assertNotNull("3rd term from pato combo shouldnt be null", - patoComboBox.getModel().getElementAt(2)); - return patoComboBox.getModel().getElementAt(2).toString(); + private String getQualityThirdAutoTerm() { + assertNotNull(qualityComboBox.getModel()); + assertNotNull("3rd term from quality combo shouldnt be null", + qualityComboBox.getModel().getElementAt(2)); + return qualityComboBox.getModel().getElementAt(2).toString(); } - private String getPatoTerm(int index) { - assertNotNull(patoComboBox.getModel()); - assertNotNull(index+" term from pato combo shouldnt be null", - patoComboBox.getModel().getElementAt(index)); - return patoComboBox.getModel().getElementAt(index).toString(); + private String getQualityTerm(int index) { + assertNotNull(qualityComboBox.getModel()); + assertNotNull(index+" term from quality combo shouldnt be null", + qualityComboBox.getModel().getElementAt(index)); + return qualityComboBox.getModel().getElementAt(index).toString(); } /** Selecting item in entity combo box should cause that item to appear in @@ -128,25 +128,25 @@ private void comboTermSelectionGoesToTableTest() { // selecting item should make it go in table... System.out.println("Selecting 3rd entity item"); - patoComboBox.setSelectedIndex(2); // 2 is 3rd - String selectedPatoTerm = getPatoThirdAutoTerm(); + qualityComboBox.setSelectedIndex(2); // 2 is 3rd + String selectedQualityTerm = getQualityThirdAutoTerm(); CharacterI selPheno = characterTablePanel.getSelectedCharacter(); - String tablePato = selPheno.getPato().getName(); // oboclass - assertEquals(selectedPatoTerm,tablePato); - System.out.println("term to table test passed, selected pato term " - +selectedPatoTerm+" pato in table "+tablePato+"\n"); + String tableQuality = selPheno.getQuality().getName(); // oboclass + assertEquals(selectedQualityTerm,tableQuality); + System.out.println("term to table test passed, selected quality term " + +selectedQualityTerm+" quality in table "+tableQuality+"\n"); } - /** Test that attributes are being filtered out of pato term completion list */ - private void attributeInPatoCompletionTest() { + /** Test that attributes are being filtered out of quality term completion list */ + private void attributeInQualityCompletionTest() { boolean doCompletion = true; - System.out.println("Testing pato for attribute filtering"); + System.out.println("Testing quality for attribute filtering"); // need to do this with key strokes now - set text doesnt work // need at least 3 key strokes 'ttr' for attributes - i seem to have problems // getting more than one key stroke in - hmmmmm - patoComboBox.setText("attribute",doCompletion); - int count = patoComboBox.getItemCount(); - String m = "Attributes are not being filtered out of Pato completion "+ + qualityComboBox.setText("attribute",doCompletion); + int count = qualityComboBox.getItemCount(); + String m = "Attributes are not being filtered out of Quality completion "+ "There are "+count+" terms with 'attribute'"; System.out.println("There are "+count+" attributes in comp list"); assertTrue(m,count == 0); @@ -155,32 +155,32 @@ // cant get null pointer to fly - gotta love testing guis /** theres a null pointer on selcting item for 1st time, not sure i can replicate*/ private void compListSelectionTest() { - //patoComboBox.setText("larg",true); - patoComboBox.simulateLKeyStroke(); - patoComboBox.setSelectedIndex(2); - // this is admittedly presumptious of pato - assertEquals("AbnormalValue",patoComboBox.getText()); - System.out.println("comp list sel ok "+patoComboBox.getText()); + //qualityComboBox.setText("larg",true); + qualityComboBox.simulateLKeyStroke(); + qualityComboBox.setSelectedIndex(2); + // this is admittedly presumptious of quality + assertEquals("acute angle",qualityComboBox.getText()); + System.out.println("comp list sel ok "+qualityComboBox.getText()); } /** After term selected in comp list popup should not come up - this doesnt actually test this - the popup does go away with setSelInd - only with mouse click it sometimes doesnt - need simulated mouse click! */ private void selectionPopupTest() { - patoComboBox.setText("larg",true); - patoComboBox.setSelectedIndex(2); - assertFalse(patoComboBox.isPopupVisible()); + qualityComboBox.setText("larg",true); + qualityComboBox.setSelectedIndex(2); + assertFalse(qualityComboBox.isPopupVisible()); } /** with searching on synonyms hit bug where terms come in more than once if have 2 syns */ private void synonymDupTest() { - patoComboBox.setText(""); + qualityComboBox.setText(""); searchParamPanel.setTermSearch(false); searchParamPanel.setSynonymSearch(true); - simulateAPatoKeyStroke(); - String first = getPatoTerm(0); - String second = getPatoTerm(1); + simulateAQualityKeyStroke(); + String first = getQualityTerm(0); + String second = getQualityTerm(1); assertFalse(first.equals(second)); } @@ -189,7 +189,8 @@ simulatePhenoteHyperlinkUpdate(); String m = "term info hyper link test fail, term info should have body tone val " +" term info: "+termInfo.getText(); - assertTrue(m,termInfo.getText().contains("BodyToneValue")); + // how to make this test not so pato specific?? + assertTrue(m,termInfo.getText().contains("body tone value")); } private void simulatePhenoteHyperlinkUpdate() { @@ -200,12 +201,12 @@ termInfo.simulateHyperlinkEvent(e); } - private void simulateAPatoKeyStroke() { - simulatePatoKeyStroke(KeyEvent.VK_A,'a'); + private void simulateAQualityKeyStroke() { + simulateQualityKeyStroke(KeyEvent.VK_A,'a'); } - private void simulatePatoKeyStroke(int keyCode, char c) { - patoComboBox.simulateKeyStroke(keyCode,c); + private void simulateQualityKeyStroke(int keyCode, char c) { + qualityComboBox.simulateKeyStroke(keyCode,c); } private void flyDataAdapterTest() { @@ -264,17 +265,17 @@ // completion list */ // private void backspaceInComboBoxTest() { // boolean doCompletion = true; -// patoComboBox.clear(); -// patoComboBox.setText("larg",doCompletion); -// int preBackspaceCount = patoComboBox.getItemCount(); +// qualityComboBox.clear(); +// qualityComboBox.setText("larg",doCompletion); +// int preBackspaceCount = qualityComboBox.getItemCount(); // // simulate backspace/delete key -// KeyEvent ke = new KeyEvent(patoComboBox,KeyEvent.VK_DELETE,Calendar.getInstance().getTimeInMillis(),0,KeyEvent.VK_UNDEFINED,KeyEvent.CHAR_UNDEFINED); -// //patoComboBox.processKeyEvent(ke); -// patoComboBox.getEditor().getEditorComponent().processKeyEvent(ke); +// KeyEvent ke = new KeyEvent(qualityComboBox,KeyEvent.VK_DELETE,Calendar.getInstance().getTimeInMillis(),0,KeyEvent.VK_UNDEFINED,KeyEvent.CHAR_UNDEFINED); +// //qualityComboBox.processKeyEvent(ke); +// qualityComboBox.getEditor().getEditorComponent().processKeyEvent(ke); -// String postDelText = patoComboBox.getText(); -// int postBackspaceCount = patoComboBox.getItemCount(); +// String postDelText = qualityComboBox.getText(); +// int postBackspaceCount = qualityComboBox.getItemCount(); // System.out.println("post text "+postDelText+" pre count "+preBackspaceCount+" post count "+postBackspaceCount); // assertTrue(preBackspaceCount != postBackspaceCount); // } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-08-25 18:27:30
|
Revision: 100 Author: mgibson Date: 2006-08-25 11:27:12 -0700 (Fri, 25 Aug 2006) ViewCVS: http://svn.sourceforge.net/obo/?rev=100&view=rev Log Message: ----------- Added "Use Term" button in term info that commits the currently browsed term to the datamodel - this was sorely needed for a while now as it was silly to browse a term and then not be able to shove it in. eventually would like to be able to do with a double click - need to somehow supress first click. TermInfo sends out update transaction with obo class - CharFieldEnum is figured via OnotologyManager - figures out which field needs to get updated - and encodes in transaction. CharFieldGui listens for char change event which maybe should be called char field change event - and queries if the field is its field and if so updates to string in event, and thus synchs with model. Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/src/java/phenote/datamodel/CharField.java phenote/trunk/src/java/phenote/datamodel/CharFieldValue.java phenote/trunk/src/java/phenote/datamodel/Ontology.java phenote/trunk/src/java/phenote/datamodel/OntologyManager.java phenote/trunk/src/java/phenote/edit/CharChangeEvent.java phenote/trunk/src/java/phenote/edit/EditManager.java phenote/trunk/src/java/phenote/edit/UpdateTransaction.java phenote/trunk/src/java/phenote/gui/AutoComboBox.java phenote/trunk/src/java/phenote/gui/CharFieldGui.java phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java phenote/trunk/src/java/phenote/gui/TermInfo.java phenote/trunk/src/java/phenote/util/HtmlUtil.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/build.xml 2006-08-25 18:27:12 UTC (rev 100) @@ -146,7 +146,7 @@ <target name="test" depends="build-test"> - <java classname="org.junit.runner.JUnitCore" fork="yes"> + <java classname="org.junit.runner.JUnitCore" fork="yes" jvmargs="-Xmx120M"> <arg value="phenote.gui.TestPhenote"/> <classpath> <pathelement path="${classfiles}"/> Modified: phenote/trunk/src/java/phenote/datamodel/CharField.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-08-25 18:27:12 UTC (rev 100) @@ -81,16 +81,7 @@ private CharFieldEnum charFieldEnum; // or subclass private String name; -// public CharField(CharFieldEnum c, Ontology o) { -// charFieldEnum = c; -// ontologyList.add(o); -// } -// public CharField(CharFieldEnum c, String n) { -// charFieldEnum = c; -// name = n; -// } - public CharField(CharFieldEnum c) { charFieldEnum = c; } @@ -118,12 +109,14 @@ boolean isGeneticContext() { return charFieldEnum == CharFieldEnum.GENETIC_CONTEXT; } public List<Ontology> getOntologyList() { return ontologyList; } + public boolean hasOntologies() { return ontologyList != null && !ontologyList.isEmpty(); } public boolean hasOneOntology() { return hasOntologies() && getOntologySize() == 1; } + public Ontology getOntology() { if (!hasOntologies()) return null; return getFirstOntology(); @@ -149,7 +142,16 @@ } } +// public CharField(CharFieldEnum c, Ontology o) { +// charFieldEnum = c; +// ontologyList.add(o); +// } +// public CharField(CharFieldEnum c, String n) { +// charFieldEnum = c; +// name = n; +// } + // hmmmmmm.... wrap String & OBOClass in one class // public class CharFieldValue { // OBOClass oboClassValue Modified: phenote/trunk/src/java/phenote/datamodel/CharFieldValue.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharFieldValue.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/datamodel/CharFieldValue.java 2006-08-25 18:27:12 UTC (rev 100) @@ -50,6 +50,8 @@ charFieldEnum.setValue(character,this); } + public CharFieldEnum getCharFieldEnum() { return charFieldEnum; } + public String toString() { return getName(); } } Modified: phenote/trunk/src/java/phenote/datamodel/Ontology.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/Ontology.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/datamodel/Ontology.java 2006-08-25 18:27:12 UTC (rev 100) @@ -51,6 +51,12 @@ return oboSession.getTerm(id); } + /** Returns true if ontology holds obo class */ + boolean hasOboClass(OBOClass oboClass) { + // if this is too slow can do optimizations with prefixes + return getOboClass(oboClass.getID()) != null; + } + /** Returns a Vector of OBOTerms from ontology that contain input string constrained by compParams. compParams specifies syns,terms,defs,& obs should input be just part of search params? @@ -70,8 +76,7 @@ // if obsoletes set then add them in addition to regulars if (searchParams.searchObsoletes()) { ontologyTermList = getSortedObsoleteTerms(); - Vector obsoletes = getSearchTerms(input,ontologyTermList,searchParams) -; + Vector obsoletes = getSearchTerms(input,ontologyTermList,searchParams); searchTerms.addAll(obsoletes); } return searchTerms; @@ -255,6 +260,10 @@ } } + + +// GARBAGE + // /** Load up/cache Sets for all ontologies used, anatomyOntologyTermSet // * and patoOntologyTermSet -- move to dataadapter/OntologyDataAdapter... */ // private void loadOntology(String filename) {//loadAllOntologyTerms() { Modified: phenote/trunk/src/java/phenote/datamodel/OntologyManager.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/OntologyManager.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/datamodel/OntologyManager.java 2006-08-25 18:27:12 UTC (rev 100) @@ -15,27 +15,17 @@ actually manages CharFields(which may have ontologies) - rename CharFieldManager?*/ public class OntologyManager { - final static String ANATOMY = "Anatomy"; - final static String PATO = "Pato"; - final static String TAXONOMY = "Taxonomy"; private static OntologyManager singleton; - private Ontology lumpOntology; - private List<Ontology> entityOntologyList; - //private Ontology entityOntology; - private Ontology patoOntology; + // isnt this redundant with charFieldList? convenience? private List<Ontology> allOntologyList = new ArrayList<Ontology>(); - private Ontology geneticContextOntology; - //private Map<CharFieldEnum,List<Ontology>> fieldToOntologyList; - /** CharFields generically hold one or more ontologies - i think above - hardwired fields are pase - or at least should be */ + /** CharFields generically hold one or more ontologies - are charFields that dont + have ontologies in this list?? not sure */ private List<CharField> charFieldList = new ArrayList<CharField>(6); /** Singleton */ - private OntologyManager() { - //fieldToOntologyList = new HashMap<CharFieldEnum,List<Ontology>>(); - } + private OntologyManager() {} public static OntologyManager inst() { if (singleton == null) @@ -43,86 +33,8 @@ return singleton; } - // public List<Ontology> getOntologyList(CharFieldEnum e) {} - - public boolean haveLumpOntology() { return getLumpOntology() != null; } - - public void setLumpOntology(Ontology lo) { - lumpOntology = lo; - addOntology(lumpOntology); - } - - public Ontology getLumpOntology() { - return lumpOntology; - } - - public void setEntityOntologyList(List<Ontology> entList) { - entityOntologyList = entList; - } - - public void addEntityOntology(Ontology o) { - getEntityOntologyList().add(o); - allOntologyList.add(o); - } - - public List<Ontology> getEntityOntologyList() { - if (entityOntologyList == null) - entityOntologyList = new ArrayList<Ontology>(); - return entityOntologyList; - } - - // for now just 1 - public Ontology getEntityOntology() { - return getEntityOntologyList().get(0); - } - - /** Set from OntologyDataAdapter */ - public void setPatoOntology(Ontology patoOntology) { - this.patoOntology = patoOntology; - addOntology(patoOntology); - } - - // pase? - public Ontology getPatoOntology() { - //if (patoOntology != null) - return patoOntology; - } - - public boolean hasGeneticContext() { - return geneticContextOntology != null; - } - - public void setGeneticContextOntology(Ontology gc) { - geneticContextOntology = gc; - addOntology(geneticContextOntology); - } - - public Ontology getGeneticContextOntology() { - return geneticContextOntology; - } - - - // eventually... - // Ontology getOntology(CharFieldEnum c) { return fieldToOntology.get(c); } - -// public void addOntology(CharFieldEnum c, Ontology o) { -// // for now... -// if (c == CharFieldEnum.GENETIC_CONTEXT) -// setGeneticContextOntology(o); -// addOntology(o); - -// // OR -// // addOntologyToMap(c,o); - -// // OR -// charFieldList.add(new CharField(c,o)); -// } public void addField(CharField cf) { - // for now... - // if hasOnlyOne? for (Ontology :...)? - if (cf.isGeneticContext()) - setGeneticContextOntology(cf.getFirstOntology()); addOntologyList(cf.getOntologyList()); charFieldList.add(cf); } @@ -141,23 +53,7 @@ return null; } - // for now i know that only genetic context is in char field list... - public CharField getGeneticContextCharField() { - if (charFieldList == null || charFieldList.isEmpty()) - return null; - return charFieldList.get(0); // revisit this!!!! - } - -// private void addOntologyToMap(CharFieldEnum c, Ontology o) { -// List<Ontology> l = fieldToOntologyList.get(c); -// if (l == null) { -// l = new ArrayList<Ontology>(3); -// fieldToOntologyList.put(c,l); -// } -// l.add(o); -// } - private void addOntologyList(List<Ontology> l) { allOntologyList.addAll(l); } @@ -180,8 +76,126 @@ return null; // not found - null } - // ??? + /** for obo class find its char field enum via ontology & char field */ + public CharFieldEnum getCharFieldEnumForOboClass(OBOClass oboClass) { + for (CharField cf : charFieldList) { + //if (!cf.hasOntologies()) continue; // is this needed? not sure + for (Ontology ont : cf.getOntologyList()) { + if (ont.hasOboClass(oboClass)) + return cf.getCharFieldEnum(); + } + } + return null; // this shouldnt happen - err msg? + } +} + // i think char field now does this + //fieldToOntologyList = new HashMap<CharFieldEnum,List<Ontology>>(); + //private Map<CharFieldEnum,List<Ontology>> fieldToOntologyList; +// private List<Ontology> entityOntologyList; + //private Ontology geneticContextOntology; + //private Ontology lumpOntology; + //private Ontology entityOntology; + //private Ontology patoOntology; -} +// final static String ANATOMY = "Anatomy"; +// final static String PATO = "Pato"; +// final static String TAXONOMY = "Taxonomy"; + // for now... + // if hasOnlyOne? for (Ontology :...)? +// if (cf.isGeneticContext()) +// setGeneticContextOntology(cf.getFirstOntology()); + + // for now i know that only genetic context is in char field list... +// public CharField getGeneticContextCharField() { +// if (charFieldList == null || charFieldList.isEmpty()) +// return null; +// return charFieldList.get(0); // revisit this!!!! +// } + + +// private void addOntologyToMap(CharFieldEnum c, Ontology o) { +// List<Ontology> l = fieldToOntologyList.get(c); +// if (l == null) { +// l = new ArrayList<Ontology>(3); +// fieldToOntologyList.put(c,l); +// } +// l.add(o); +// } + + + // public List<Ontology> getOntologyList(CharFieldEnum e) {} + +// public boolean haveLumpOntology() { return getLumpOntology() != null; } + +// public void setLumpOntology(Ontology lo) { +// lumpOntology = lo; +// addOntology(lumpOntology); +// } + +// public Ontology getLumpOntology() { +// return lumpOntology; +// } + +// public void setEntityOntologyList(List<Ontology> entList) { +// entityOntologyList = entList; +// } + +// public void addEntityOntology(Ontology o) { +// getEntityOntologyList().add(o); +// allOntologyList.add(o); +// } + +// public List<Ontology> getEntityOntologyList() { +// if (entityOntologyList == null) +// entityOntologyList = new ArrayList<Ontology>(); +// return entityOntologyList; +// } + +// // for now just 1 +// public Ontology getEntityOntology() { +// return getEntityOntologyList().get(0); +// } + + /** Set from OntologyDataAdapter */ +// public void setPatoOntology(Ontology patoOntology) { +// this.patoOntology = patoOntology; +// addOntology(patoOntology); +// } + + // pase? +// public Ontology getPatoOntology() { +// //if (patoOntology != null) +// return patoOntology; +// } + +// public boolean hasGeneticContext() { +// return geneticContextOntology != null; +// } + +// public void setGeneticContextOntology(Ontology gc) { +// geneticContextOntology = gc; +// addOntology(geneticContextOntology); +// } + +// public Ontology getGeneticContextOntology() { +// return geneticContextOntology; +// } + + + // eventually... + // Ontology getOntology(CharFieldEnum c) { return fieldToOntology.get(c); } + +// public void addOntology(CharFieldEnum c, Ontology o) { +// // for now... +// if (c == CharFieldEnum.GENETIC_CONTEXT) +// setGeneticContextOntology(o); +// addOntology(o); + +// // OR +// // addOntologyToMap(c,o); + +// // OR +// charFieldList.add(new CharField(c,o)); +// } Modified: phenote/trunk/src/java/phenote/edit/CharChangeEvent.java =================================================================== --- phenote/trunk/src/java/phenote/edit/CharChangeEvent.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/edit/CharChangeEvent.java 2006-08-25 18:27:12 UTC (rev 100) @@ -2,13 +2,26 @@ import java.util.EventObject; +import phenote.datamodel.CharField; + +/** This actually is for a CharField change - rename this CharFieldChangeEvent? */ public class CharChangeEvent extends EventObject { // UpdateTrans -> Transaction? private UpdateTransaction transaction; + // boolean undo??? or in trans? of just editManager? CharChangeEvent(Object source, UpdateTransaction ut) { super(source); transaction = ut; } + + public String getValueString() { // getNewVal, getOldVal??? + // if undo return ut.getOldValue().getName()??? + return transaction.getNewValueString(); + } + + public boolean isForCharField(CharField cf) { + return transaction.getCharFieldEnum() == cf.getCharFieldEnum(); + } } Modified: phenote/trunk/src/java/phenote/edit/EditManager.java =================================================================== --- phenote/trunk/src/java/phenote/edit/EditManager.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/edit/EditManager.java 2006-08-25 18:27:12 UTC (rev 100) @@ -3,6 +3,14 @@ import java.util.ArrayList; import java.util.List; + +/** The way editing works is gui makes update transaction (see CharFieldGui and + AutoComboBox) and calls + EditManager.updateModel(), EM calls UpdateTrans constructs CharFieldValues and calls + CVF..editModel which call charFieldEnum.setValue which calls the appropriate + method in CharacterI. EM also shoots out char change event to its listeners + UpdateTrans takes Strings(for free text) or OBOClasses(ontologies). */ + public class EditManager { private static EditManager singleton; Modified: phenote/trunk/src/java/phenote/edit/UpdateTransaction.java =================================================================== --- phenote/trunk/src/java/phenote/edit/UpdateTransaction.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/edit/UpdateTransaction.java 2006-08-25 18:27:12 UTC (rev 100) @@ -14,6 +14,7 @@ //private String oldValue; private CharFieldValue newValue; private CharFieldValue oldValue; + //private boolean undo? public UpdateTransaction(CharacterI c, CharFieldEnum e, String newVal, String old) { newValue = new CharFieldValue(newVal,c,e); @@ -36,6 +37,15 @@ //charFieldEnum.setValue(character,newValue); } + /** return new value for regular trans, old value for undo? */ + //String getValue() { // if undo } - does updateTrans know of undo??? not sure + + String getNewValueString() { return newValue.getName(); } + + CharFieldEnum getCharFieldEnum() { + return newValue.getCharFieldEnum(); + } + //public void undo() { oldValue.setValue();//charFieldEnum.setValue(character,oldValue); } } Modified: phenote/trunk/src/java/phenote/gui/AutoComboBox.java =================================================================== --- phenote/trunk/src/java/phenote/gui/AutoComboBox.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/gui/AutoComboBox.java 2006-08-25 18:27:12 UTC (rev 100) @@ -426,20 +426,41 @@ //setTableFromField(ontology); } - /** edits Character field, sends out CharChangeEvent. + /** edits Character field via EditManager. checks that text in text field from user is actually an item in completion list, is an obo term. */ private void editCharField() { String input = getText(); if (input == null) return; // probably doesnt happen // the input should be from selected obo class shouldnt it? is it possible - // for this not to be so? + // for this not to be so? returns null if no oboclass? OBOClass oboClass = getSelectedCompListOboClass(); if (oboClass == null) return; /// happens on return on invalid term name + if (charField == null) return; // shouldnt happen + + CharacterI c = getSelectedCharacter(); + CharFieldEnum cfe = charField.getCharFieldEnum(); + UpdateTransaction ut = new UpdateTransaction(c,cfe,oboClass,previousOboClass); + EditManager.inst().updateModel(this,ut); + + previousOboClass = oboClass; // for undo + } + } + +} + +// GARBAGE + //t.editModel(); // or charField.editModel? + // CharacterChangeEvent e = new CharacterChangeEvent(t); + // OR CharEditManager.inst().updateModel(c,cfe,input,previousModelValue); + // CEM.handleTransaction(new UT), CEM.updateModel(UT) + // fireChangeEvent(e); + + // can this happen? yes when user hits return on text - actually i think this // is the test for being in the completion list isnt it? - boolean DEBUG = true; +// boolean DEBUG = true; // bug - on first return input is the user text not the term selected yet! // if (!input.equals(oboClass.getName())) { // if (DEBUG) @@ -454,29 +475,7 @@ // boolean valid = isInCompletionList(oboClass); //input); // if (!valid) // return; - - if (charField == null) // shouldnt happen - return; - - CharacterI c = getSelectedCharacter(); - CharFieldEnum cfe = charField.getCharFieldEnum(); - UpdateTransaction ut = new UpdateTransaction(c,cfe,oboClass,previousOboClass); - //t.editModel(); // or charField.editModel? - // CharacterChangeEvent e = new CharacterChangeEvent(t); - // OR CharEditManager.inst().updateModel(c,cfe,input,previousModelValue); - // CEM.handleTransaction(new UT), CEM.updateModel(UT) - EditManager.inst().updateModel(this,ut); - // fireChangeEvent(e); - - // for undo - previousOboClass = oboClass; - - } - } - -} - // /** Sets table value from field. checks that text in text field from user // is actually an item in completion list, is an obo term. */ // private void setTableFromField(String ontology) { Modified: phenote/trunk/src/java/phenote/gui/CharFieldGui.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharFieldGui.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/gui/CharFieldGui.java 2006-08-25 18:27:12 UTC (rev 100) @@ -15,6 +15,8 @@ import phenote.datamodel.Ontology; import phenote.datamodel.OntologyManager; import phenote.datamodel.SearchParamsI; +import phenote.edit.CharChangeEvent; +import phenote.edit.CharChangeListener; import phenote.edit.EditManager; import phenote.edit.UpdateTransaction; import phenote.gui.selection.CharSelectionListener; @@ -42,10 +44,22 @@ else initCombo(charField,parent); - // do just for text field - or both??? + // do just for text field - or both??? listens for selection (eg from table) SelectionManager.inst().addCharSelectionListener(new FieldCharSelectListener()); + // listen for model changes (eg TermInfo commit) + + EditManager.inst().addCharChangeListener(new FieldCharChangeListener()); } + private class FieldCharChangeListener implements CharChangeListener { + public void charChanged(CharChangeEvent e) { + // check charField is this char field + if (e.isForCharField(charField)) + // i think all we need to do is setText to synch with model + setText(e.getValueString()); + } + } + AutoComboBox getAutoComboBox() { if (isCombo) return comboBox; @@ -55,6 +69,7 @@ // hasOntology? boolean isCombo() { return isCombo; } + /** Set the gui from the model */ void setValueFromChar(CharacterI character) { if (charField == null) return; if (charField.getCharFieldEnum() == null) { @@ -123,19 +138,19 @@ CharFieldEnum getCharFieldEnum() { return charField.getCharFieldEnum(); } // separate char text field class? - // this should be made generic to use beyond just genotype? yes yes yes - // and put in CharFieldGui... + /** This is where the model gets updated */ private class TextFieldDocumentListener implements DocumentListener { private String previousVal = null; - public void changedUpdate(DocumentEvent e) { updateInstanceTable(); } - public void insertUpdate(DocumentEvent e) { updateInstanceTable(); } - public void removeUpdate(DocumentEvent e) { updateInstanceTable(); } - private void updateInstanceTable() { + public void changedUpdate(DocumentEvent e) { updateModel(); } + public void insertUpdate(DocumentEvent e) { updateModel(); } + public void removeUpdate(DocumentEvent e) { updateModel(); } + private void updateModel() { // on delete last pheno row clearing of text will trigger this //if (!characterTablePanel.hasRows()) return; //String genotype = lumpField.getText(); //characterTablePanel.setSelectedGenotype(genotype); CharacterI c = SelectionManager.inst().getSelectedCharacter(); + // i believe this isnt using oboClass as we just have string String v = getText(); UpdateTransaction ut = new UpdateTransaction(c,getCharFieldEnum(),v,previousVal); EditManager.inst().updateModel(this,ut); Modified: phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2006-08-25 18:27:12 UTC (rev 100) @@ -177,7 +177,7 @@ /** List/row selection listener - fired when user selects new row of table - refactor - this should send out CharacterSelectionEvent */ + notifies selectionManager of new char selection */ private class CharacterSelectionListener implements ListSelectionListener { public void valueChanged(ListSelectionEvent e) { if (!hasSelection()) // this can happen with a delete row Modified: phenote/trunk/src/java/phenote/gui/TermInfo.java =================================================================== --- phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-08-25 18:27:12 UTC (rev 100) @@ -2,13 +2,17 @@ import java.net.URL; import java.util.Iterator; -//import java.util.Set; +import java.awt.BorderLayout; import java.awt.Color; import java.awt.Dimension; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; import javax.swing.BorderFactory; +import javax.swing.JButton; import javax.swing.JComponent; import javax.swing.JList; import javax.swing.JEditorPane; +import javax.swing.JPanel; import javax.swing.JScrollPane; import javax.swing.JTextArea; import javax.swing.text.JTextComponent; @@ -22,13 +26,13 @@ import edu.stanford.ejalbert.exception.BrowserLaunchingInitializingException; import edu.stanford.ejalbert.exception.UnsupportedOperatingSystemException; -//import org.geneontology.oboedit.datamodel.Link; -//import org.geneontology.oboedit.datamodel.LinkedObject; import org.geneontology.oboedit.datamodel.OBOClass; -//import org.geneontology.oboedit.datamodel.OBOProperty; import phenote.datamodel.CharacterI; +import phenote.datamodel.CharField.CharFieldEnum; import phenote.datamodel.OntologyManager; +import phenote.edit.EditManager; +import phenote.edit.UpdateTransaction; import phenote.util.HtmlUtil; import phenote.gui.selection.SelectionManager; import phenote.gui.selection.TermSelectionEvent; @@ -38,29 +42,19 @@ //private JEditorPane textArea; private JTextComponent textArea; - //private static final boolean DO_HTML = false; private static final boolean DO_HTML = HtmlUtil.DO_HTML; - //static final String PHENOTE_LINK_PREFIX = "Phenote?id="; private TermHyperlinkListener termHyperlinkListener; // current obo class being navigated private OBOClass currentOboClass; + private OBOClass previousOboClass=null; // for undo - not implemented yet TermInfo(TermPanel termPanel) { - // do this more generically? some sort of controller? -// CompletionListListener l = new CompletionListListener(); -// termPanel.getEntityComboBox().addCompletionListListener(l); -// termPanel.getPatoComboBox().addCompletionListListener(l); -// if (termPanel.hasLumpComboBox()) -// termPanel.getLumpComboBox().addCompletionListListener(l); SelectionManager.inst().addTermSelectionListener(new InfoTermSelectionListener()); } JComponent getComponent() { - // JEditorPane allows for html formatting - bold... but doesnt do word wrap - bummer! - // as far as i can tell - // would have to explicitly put <br> in text. can also do hyperlinks! - // for now just doing JTextArea + JPanel termInfoPanel = new JPanel(new BorderLayout(0,0)); // hgap,vgap if (DO_HTML) { JEditorPane editorPane = new JEditorPane(); editorPane.setContentType("text/html"); // sets up HTMLEditorKit @@ -68,7 +62,7 @@ editorPane.addHyperlinkListener(termHyperlinkListener); textArea = editorPane; } - else { + else { // pase - delete? JTextArea jTextArea = new JTextArea(17,50); jTextArea.setLineWrap(true); jTextArea.setWrapStyleWord(true); @@ -80,9 +74,22 @@ scrollPane.setMaximumSize(new Dimension(400,300)); // border - make JPanel for it (there is a disclaimer about non JPanel) scrollPane.setBorder(BorderFactory.createTitledBorder("Term Info")); - return scrollPane; + termInfoPanel.add(scrollPane,BorderLayout.CENTER); + + JButton useTermButton = new JButton("Use Term"); + useTermButton.addActionListener(new UseTermActionListener()); + termInfoPanel.add(useTermButton,BorderLayout.SOUTH); + + return termInfoPanel; } + /** Commits currently browsed term when useTermButton is pressed */ + private class UseTermActionListener implements ActionListener { + public void actionPerformed(ActionEvent e) { + commitTerm(); + } + } + // for TestPhenote String getText() { return textArea.getText(); } @@ -97,8 +104,7 @@ } - - + /** Listen for selection from phenote (mouse over completion list) */ private class InfoTermSelectionListener implements TermSelectionListener { public boolean termSelected(TermSelectionEvent e) { setTextFromOboClass(e.getOboClass()); @@ -106,10 +112,23 @@ } } - /** put present term into current character */ + /** put present term into current character - not used yet...*/ private void commitTerm() { CharacterI ch = SelectionManager.inst().getSelectedCharacter(); - // currentOboClass... + if (ch == null) { // can this happen? + System.out.println("ERROR: no character selected to update"); + return; + } + if (currentOboClass == null) { // can this happen? + System.out.println("ERROR: no term in term info to add to character"); + return; + } + + CharFieldEnum cfe = OntologyManager.inst().getCharFieldEnumForOboClass(currentOboClass); + + UpdateTransaction ut = new UpdateTransaction(ch,cfe,currentOboClass,previousOboClass); + EditManager.inst().updateModel(this,ut); + previousOboClass = currentOboClass; } /** for testing */ @@ -119,7 +138,7 @@ /** inner class TermHyperlink Listener, listens for clicks on term & external - hyper links and birngs up the term or brings up the external web page */ + hyper links and brings up the term or brings up the external web page */ private class TermHyperlinkListener implements HyperlinkListener { public void hyperlinkUpdate(HyperlinkEvent e) { @@ -131,7 +150,7 @@ // internal link to term... if (HtmlUtil.isPhenoteLink(e)) { - bringUpTermInPhenote(e); + bringUpTermInTermInfo(e); return; } @@ -142,11 +161,6 @@ bringUpInBrowser(url); - // ..... BrowserLauncher2? webstart BasicService? config browser... - // somehow distinguish local links from non local?? - // look for localhost? - - // set up localhost servlet? or just pick out text from url? - // hmmmmm...... } private void bringUpInBrowser(URL url) { @@ -164,27 +178,45 @@ } } + + private void bringUpTermInTermInfo(HyperlinkEvent e) { + // or do through obo session? + String id = HtmlUtil.getIdFromHyperlink(e); + if (id == null) return; + OBOClass term = OntologyManager.inst().getOboClass(id); + setTextFromOboClass(term); + } + } +} + + // JEditorPane allows for html formatting - bold... but doesnt do word wrap - bummer! + // as far as i can tell + // would have to explicitly put <br> in text. can also do hyperlinks! + // for now just doing JTextArea + // do this more generically? some sort of controller? +// CompletionListListener l = new CompletionListListener(); +// termPanel.getEntityComboBox().addCompletionListListener(l); +// termPanel.getPatoComboBox().addCompletionListListener(l); +// if (termPanel.hasLumpComboBox()) +// termPanel.getLumpComboBox().addCompletionListListener(l); + + // ..... BrowserLauncher2? webstart BasicService? config browser... + // somehow distinguish local links from non local?? + // look for localhost? - + // set up localhost servlet? or just pick out text from url? + // hmmmmm...... // private boolean isPhenoteLink(HyperlinkEvent e) { // return e.getURL() == null && e.getDescription().startsWith(PHENOTE_LINK_PREFIX); // } - private void bringUpTermInPhenote(HyperlinkEvent e) { // String desc = e.getDescription(); // if (desc == null || desc.equals("")) return; // String id = getIdFromDescription(desc); - // or do through obo session? - String id = HtmlUtil.getIdFromHyperlink(e); - if (id == null) return; - OBOClass term = OntologyManager.inst().getOboClass(id); - setTextFromOboClass(term); - } + // private String getIdFromDescription(String desc) { // return desc.substring(PHENOTE_LINK_PREFIX.length()); // } - } -} - // /** Listens for completion list selection (via moouse over) and populates // term info with term selected -- this is pase - replaced by // TermSelectionEvent/Listener */ Modified: phenote/trunk/src/java/phenote/util/HtmlUtil.java =================================================================== --- phenote/trunk/src/java/phenote/util/HtmlUtil.java 2006-08-24 19:19:49 UTC (rev 99) +++ phenote/trunk/src/java/phenote/util/HtmlUtil.java 2006-08-25 18:27:12 UTC (rev 100) @@ -49,6 +49,8 @@ if (definition != null && !definition.equals("")) sb.append(nl()).append(nl()).append(bold("Definition: ")).append(definition); + System.out.println(sb); + return sb.toString(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-08-31 16:08:09
|
Revision: 107 http://svn.sourceforge.net/obo/?rev=107&view=rev Author: mgibson Date: 2006-08-31 09:07:57 -0700 (Thu, 31 Aug 2006) Log Message: ----------- comented out nascent thread for obo file checking from servlet - wasnt acutally working as thread updated pato -> quality ontology name and Anatomy -> ZF for zfin Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/datamodel/CharField.java phenote/trunk/src/java/phenote/datamodel/CharacterI.java phenote/trunk/src/java/phenote/gui/AutoComboBox.java phenote/trunk/src/java/phenote/gui/Phenote.java phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java phenote/trunk/src/web/html/ncbo.html phenote/trunk/src/web/javascript/ncbo-term-info.js Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/build.xml 2006-08-31 16:07:57 UTC (rev 107) @@ -21,6 +21,8 @@ <property name="web-classfiles" value="${env.PHENOTE_WEB_CLASSFILES}" /> <property name="web-conf" value="${env.PHENOTE_WEB_CONF_FILES}"/> <property name="web-html" value="${env.PHENOTE_WEB_HTML}"/> + <property name="web-jars" value="${env.PHENOTE_WEB_JAR_DIR}" /> + <property name="lib" value="jars" /> <property name="jarfile" value="jars/phenote.jar"/> <property name="obo" value="obo-files" /> @@ -278,6 +280,12 @@ <copy todir="${web-conf}"> <fileset dir="obo-files" /> </copy> + <copy todir="${web-jars}"> + <fileset dir="${lib}"> + <include name="*.jar"/> + <exclude name="phenote.jar"/> + </fileset> + </copy> </target> <target name="war" depends="jar"> Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/java/phenote/config/Config.java 2006-08-31 16:07:57 UTC (rev 107) @@ -52,6 +52,8 @@ //parseXmlFile("./conf/initial-flybase.cfg"); // hardwired for now... } + /** This is the config file from command line - + todo... if user has personal config file use that instead */ public void setConfigFile(String configFile) { this.configFile = configFile; // ?? System.out.println("Attempting to read config from "+configFile); Modified: phenote/trunk/src/java/phenote/datamodel/CharField.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-08-31 16:07:57 UTC (rev 107) @@ -9,79 +9,10 @@ // associates enum & ontologies public class CharField { - // separate class? labels? methods? subclasses? - // is this taking enums too far? or a good use of them? - // would it be nice to have a class that wrapped String and OBOClass? - // and all possible field values? or would that be annoying? -// public enum CharFieldEnum { - -// PUB("Pub") { -// public void setValue(CharacterI c, CharFieldValue v) { -// c.setPub(v.getName()); -// } -// public CharFieldValue getValue(CharacterI c) { -// return new CharFieldValue(c.getPub(),c,this); -// } -// }, -// LUMP("Genotype") { // genotype? default? -// public void setValue(CharacterI c, CharFieldValue v) { -// c.setGenotype(v.getName()); -// } -// public CharFieldValue getValue(CharacterI c) { -// return new CharFieldValue(c.getGenotype(),c,this); -// } -// }, -// GENETIC_CONTEXT("Genetic Context") { -// public void setValue(CharacterI c, CharFieldValue v) { -// c.setGeneticContext(v.getOboClass()); -// } -// public CharFieldValue getValue(CharacterI c) { -// return new CharFieldValue(c.getGeneticContext(),c,this); -// } -// }, -// ENTITY("Entity") { -// public void setValue(CharacterI c, CharFieldValue v) { -// c.setEntity(v.getOboClass()); -// } -// public CharFieldValue getValue(CharacterI c) { -// return new CharFieldValue(c.getEntity(),c,this); -// } -// }, -// QUALITY("Quality") { -// public void setValue(CharacterI c, CharFieldValue v) { -// c.setQuality(v.getOboClass()); -// } -// public CharFieldValue getValue(CharacterI c) { -// return new CharFieldValue(c.getQuality(),c,this); -// } -// }; - - -// // CHAR FIELD ENUM vars & methods (make its own class!) -// private final String name; -// private CharFieldEnum(String name) { this.name = name; } -// public String toString() { return name; } -// public abstract void setValue(CharacterI c, CharFieldValue v); -// public abstract CharFieldValue getValue(CharacterI c); - -// // unclear if we need this??? need it in generic field config -// public static CharFieldEnum getCharFieldEnum(String fieldString) { -// for ( CharFieldEnum cfe : CharFieldEnum.values()) { -// if (cfe.name.equalsIgnoreCase(fieldString)) -// return cfe; -// } -// System.out.println("ERROR: No Char Field found for string "+fieldString); -// return null; -// } - -// }; - - // CHAR FIELD VARS private List<Ontology> ontologyList = new ArrayList<Ontology>(3); private CharFieldEnum charFieldEnum; // or subclass private String name; - public CharField(CharFieldEnum c) { charFieldEnum = c; } @@ -135,7 +66,7 @@ return getOntologyForName(ontologyName) != null; } - /** Returns Ontology with name ontologyName, null if dont have it */ + /** Returns Ontology with name ontologyName (ignores case), null if dont have it */ public Ontology getOntologyForName(String ontologyName) { for (Ontology o : getOntologyList()) { if (o.getName().equalsIgnoreCase(ontologyName)) @@ -170,3 +101,69 @@ // above would be setValue(CharFieldValue) // getValue(CharFieldValue) + // separate class? labels? methods? subclasses? + // is this taking enums too far? or a good use of them? + // would it be nice to have a class that wrapped String and OBOClass? + // and all possible field values? or would that be annoying? +// public enum CharFieldEnum { + +// PUB("Pub") { +// public void setValue(CharacterI c, CharFieldValue v) { +// c.setPub(v.getName()); +// } +// public CharFieldValue getValue(CharacterI c) { +// return new CharFieldValue(c.getPub(),c,this); +// } +// }, +// LUMP("Genotype") { // genotype? default? +// public void setValue(CharacterI c, CharFieldValue v) { +// c.setGenotype(v.getName()); +// } +// public CharFieldValue getValue(CharacterI c) { +// return new CharFieldValue(c.getGenotype(),c,this); +// } +// }, +// GENETIC_CONTEXT("Genetic Context") { +// public void setValue(CharacterI c, CharFieldValue v) { +// c.setGeneticContext(v.getOboClass()); +// } +// public CharFieldValue getValue(CharacterI c) { +// return new CharFieldValue(c.getGeneticContext(),c,this); +// } +// }, +// ENTITY("Entity") { +// public void setValue(CharacterI c, CharFieldValue v) { +// c.setEntity(v.getOboClass()); +// } +// public CharFieldValue getValue(CharacterI c) { +// return new CharFieldValue(c.getEntity(),c,this); +// } +// }, +// QUALITY("Quality") { +// public void setValue(CharacterI c, CharFieldValue v) { +// c.setQuality(v.getOboClass()); +// } +// public CharFieldValue getValue(CharacterI c) { +// return new CharFieldValue(c.getQuality(),c,this); +// } +// }; + + +// // CHAR FIELD ENUM vars & methods (make its own class!) +// private final String name; +// private CharFieldEnum(String name) { this.name = name; } +// public String toString() { return name; } +// public abstract void setValue(CharacterI c, CharFieldValue v); +// public abstract CharFieldValue getValue(CharacterI c); + +// // unclear if we need this??? need it in generic field config +// public static CharFieldEnum getCharFieldEnum(String fieldString) { +// for ( CharFieldEnum cfe : CharFieldEnum.values()) { +// if (cfe.name.equalsIgnoreCase(fieldString)) +// return cfe; +// } +// System.out.println("ERROR: No Char Field found for string "+fieldString); +// return null; +// } + +// }; Modified: phenote/trunk/src/java/phenote/datamodel/CharacterI.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-08-31 16:07:57 UTC (rev 107) @@ -3,7 +3,12 @@ import org.geneontology.oboedit.datamodel.OBOClass; /** CharacterIs are the building blocks of phenotypes. All the Characters for a - genotype make up a Phenotype - at least thats my understanding. */ + genotype make up a Phenotype - at least thats my understanding. + an alternate approach would be to just have a list of CharFields, it would + certainly be more generic - hybrid approach would be to retain these fields + but also have a CharField list that can just come from config (& take out enum + in config xsd for field names) - downside: lose strong typing, and a config + misspelling would end up in a char field */ public interface CharacterI { public String getEntityName(); Modified: phenote/trunk/src/java/phenote/gui/AutoComboBox.java =================================================================== --- phenote/trunk/src/java/phenote/gui/AutoComboBox.java 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/java/phenote/gui/AutoComboBox.java 2006-08-31 16:07:57 UTC (rev 107) @@ -1,6 +1,7 @@ package phenote.gui; import java.awt.Dimension; +import java.awt.Font; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.KeyAdapter; @@ -52,6 +53,7 @@ AutoComboBox(Ontology ontology,SearchParamsI sp) { // this inner class enables retrieving of JList for mouse over // this will probably throw errors if non metal look & feel is used + //setFont(new Font("Courier",Font.PLAIN,12)); setUI(new MetalListComboUI()); setOntology(ontology); @@ -59,7 +61,7 @@ setEditable(true); AutoTextFieldEditor autoTextFieldEditor = new AutoTextFieldEditor(); this.setEditor(autoTextFieldEditor); - setPreferredSize(new Dimension(325,22)); + setPreferredSize(new Dimension(350,22)); addCompletionListListener(new CompletionListListener()); @@ -276,6 +278,8 @@ // too soon - text field doesnt have text yet.... hmmmm.... String input = getText(); // this is a vector of OBOClasses + // i think ultimately we will need to wrap the OBOClass to be able to + // have more control over the string - cut off w ... & [syn][obs] tags Vector<OBOClass> v = getTerms(input); // throws IllegalStateException, Attempt to mutate in notification // this tries to change text field amidst notification hmmmm..... Modified: phenote/trunk/src/java/phenote/gui/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/gui/Phenote.java 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/java/phenote/gui/Phenote.java 2006-08-31 16:07:57 UTC (rev 107) @@ -17,7 +17,7 @@ public class Phenote { - private static final String VERSION = "0.7.4 dev"; + private static final String VERSION = "0.7.5 dev"; //private static final String DEFAULT_CONFIG_FILE = Config.DEFAULT_CONFIG_FILE; private CharacterTablePanel characterTablePanel; @@ -62,7 +62,14 @@ } /** for now just looking for '-c configFile.cfg', use command line package - if we need to get more sophisticated */ + if we need to get more sophisticated + so if user has personal config file should override this - however maybe + there should be a distinction between initial config file and user made configs + well really the initials are db/species specific - so could be + --initialConfig zf|fb|obd - actually da heck with that with entity chooser just + put all 3 ontologies in one which is then the default (unspecified on cmd line) + and -c file.cfg will load/overwrite that cfg into .phenote/my-phenote.cfg + (if it exists) - we can always add --init later if we need it */ private void doCommandLine(String[] args) { String configFile = getConfigFileFromCommandLine(args); if (configFile == null) Modified: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-08-31 16:07:57 UTC (rev 107) @@ -37,8 +37,11 @@ String[] args = {"-c","initial-zfin.cfg"}; phenote.initConfig(args); // hardwire for now to zfin phenote.initOntologies(); - OntologyFileCheckThread ofct = new OntologyFileCheckThread(); - ofct.run(); + // this is not running as a separate thread - investigate +// System.out.println("ontologies loaded - starting file checking thread"); +// OntologyFileCheckThread ofct = new OntologyFileCheckThread(); +// ofct.run(); // is this not running as threaded? +// System.out.println("file thread launched - moving on"); } @@ -82,7 +85,7 @@ private String getTermCompletionParam(HttpServletRequest req) { String par = req.getParameter("userInput"); // new way if (par ==null) - par = req.getParameter("patoInput"); // for now + par = req.getParameter("qualityInput"); // for now - pase i think if (par == null) par = req.getParameter("entityInput"); return par; @@ -108,7 +111,6 @@ // "<td class=\"data\">"+initDate+"</td></tr>\n"+ // "<tr><td class=\"label\">Term name...</td><td class=\"data\">" // +userInput+"</td></tr></table>"); - // for now hard wire to pato Ontology ont = getOntology(ontologyName); if (ont == null) { System.out.println("ERROR: Failed to get ontology for "+ontologyName); @@ -173,6 +175,7 @@ private String makeCompListHtmlItem(OBOClass term,String ontol) { String id = "'"+term.getID()+"'"; return "<li onmouseover=\"getTermInfo("+id+",'"+ontol+"')\" id="+id+" "+ +// this is wrong - needs ontology name as well... "onclick=\"getTermInfo("+id+")\">"+term.getName()+"</li>\n"; } @@ -198,11 +201,13 @@ public void run() { while(true) { + System.out.println("checking for new files..."); // check for files... // sleep in milliseconds - sleep for 5 seconds for now (test) - //sleep(5000); + try { sleep(5000); } + catch (InterruptedException e) { System.out.println("interrupted"); } } } } Modified: phenote/trunk/src/web/html/ncbo.html =================================================================== --- phenote/trunk/src/web/html/ncbo.html 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/web/html/ncbo.html 2006-08-31 16:07:57 UTC (rev 107) @@ -23,7 +23,7 @@ <script type="text/javascript"> function setEntityOntology(selectedOntology) { if (selectedOntology == 'AO') { - ontologyName = 'Anatomy'; <!-- ZFA --> + ontologyName = 'ZF'; <!-- ZF Anatomy --> } else if (selectedOntology == 'GO') { ontologyName = 'GO'; } @@ -81,7 +81,7 @@ <!-- tr -- --> <!-- td --> - <!-- PATO --> + <!-- QUALITY --> <div style="clear: left;"> <!-- div width="20%" --> @@ -91,9 +91,9 @@ <label>Quality: </label> <!-- input autocomplete="off" id="ontologyname" name="ontologyname" size="20" type="text" value="" / --> - <input autocomplete="off" id="patoInput" name="patoInput" size="40" type="text" value="" /> + <input autocomplete="off" id="qualityInput" name="qualityInput" size="40" type="text" value="" /> </br> - <div class="auto_complete" id="pato_auto_complete"></div> + <div class="auto_complete" id="quality_auto_complete"></div> </fieldset> </div> @@ -108,8 +108,8 @@ <script type="text/javascript"> - <!-- this is the crucial javascript bit here, patoInput is the --> - <!-- input field, i pato_auto_complete is the div where--> + <!-- this is the crucial javascript bit here, qualityInput is the --> + <!-- input field, i quality_auto_complete is the div where--> <!--the auto completion will pop up, and the last param is the--> <!-- script that will does the fetching of terms --> <!-- Autocomp is in js/prototype/controls.js --> @@ -117,14 +117,14 @@ <!-- 'ontologyname_auto_complete', '/phenote-ontology.cgi',{ }) --> <!-- new Ajax.Autocompleter( 'ontologyname', 'ontologyname_auto_complete', '/servlet/PhenoteStub',{ }) --> <!-- new Ajax.Autocompleter( 'ontologyname', 'ontologyname_auto_complete', '/servlet/phenote.servlet.PhenoteServlet',{ }) --> - var complete = new Ajax.Autocompleter( 'patoInput', 'pato_auto_complete', '/phenote/Phenote',{parameters:'ontologyName=pato',paramName: "userInput" }) - <!-- complete.options.defaultParams = "ontology=pato"; --> - <!-- complete.options.parameters = "ontology=pato"; --> - <!-- more params? 'ontology=pato&x=y&...' --> + var complete = new Ajax.Autocompleter( 'qualityInput', 'quality_auto_complete', '/phenote/Phenote',{parameters:'ontologyName=quality',paramName: "userInput" }) + <!-- complete.options.defaultParams = "ontology=quality"; --> + <!-- complete.options.parameters = "ontology=quality"; --> + <!-- more params? 'ontology=quality&x=y&...' --> </script> <script type="text/javascript"> - var entityAutoCompleter = new Ajax.Autocompleter( 'entityInput', 'entity_auto_complete', '/phenote/Phenote',{parameters:'ontologyName=anatomy',paramName: "userInput"}) + var entityAutoCompleter = new Ajax.Autocompleter( 'entityInput', 'entity_auto_complete', '/phenote/Phenote',{parameters:'ontologyName=ZF',paramName: "userInput"}) </script> Modified: phenote/trunk/src/web/javascript/ncbo-term-info.js =================================================================== --- phenote/trunk/src/web/javascript/ncbo-term-info.js 2006-08-29 22:13:13 UTC (rev 106) +++ phenote/trunk/src/web/javascript/ncbo-term-info.js 2006-08-31 16:07:57 UTC (rev 107) @@ -33,7 +33,7 @@ // ontologyinfo is the div where the table goes for term info // note: this is a "get" not a post! (term comp is post) - //var myAjax = new Ajax.Updater('termInfo', url, {method: 'get', parameters: pars, onComplete: document.forms[0].patoInput.value = '' } ); + //var myAjax = new Ajax.Updater('termInfo', url, {method: 'get', parameters: pars, onComplete: document.forms[0].qualityInput.value = '' } ); // take out wipe out on complete var myAjax = new Ajax.Updater('termInfo', url, {method: 'get', parameters: pars } ); // have to have [1] next to form item because the edit subform and This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-09-12 23:01:20
|
Revision: 124 http://svn.sourceforge.net/obo/?rev=124&view=rev Author: mgibson Date: 2006-09-12 16:01:03 -0700 (Tue, 12 Sep 2006) Log Message: ----------- got log4j working for standalone - standalone logs to stdout in addition to file - and starting to switch print statements over to log statements - as in OntologyDataAdapter. you can config the log configuration with <log config-file="conf/log4j-standalone.xml" /> defaults to conf/log4j.xml (no stdout - for servlet) Modified Paths: -------------- phenote/trunk/conf/initial-flybase.cfg phenote/trunk/conf/initial-zfin.cfg phenote/trunk/conf/log4j.xml phenote/trunk/conf/phenote-config.rnc phenote/trunk/conf/phenote-config.xsd phenote/trunk/jars/phenoteconfigbeans.jar phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java phenote/trunk/src/java/phenote/gui/Phenote.java phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java Added Paths: ----------- phenote/trunk/conf/log4j-standalone.xml Modified: phenote/trunk/conf/initial-flybase.cfg =================================================================== --- phenote/trunk/conf/initial-flybase.cfg 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/conf/initial-flybase.cfg 2006-09-12 23:01:03 UTC (rev 124) @@ -3,6 +3,8 @@ <dataadapter name="phenosyntax"/> + <log config-file="conf/log4j-standalone.xml" /> + <field name="Pub" /> <field name="Genotype" type="free_text"/> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/conf/initial-zfin.cfg 2006-09-12 23:01:03 UTC (rev 124) @@ -4,6 +4,8 @@ <check-for-new-ontologies intervalMinutes="5"/> + <log config-file="conf/log4j.xml"/> + <field name="Pub" /> <field name="Genotype" type="free_text"/> Added: phenote/trunk/conf/log4j-standalone.xml =================================================================== --- phenote/trunk/conf/log4j-standalone.xml (rev 0) +++ phenote/trunk/conf/log4j-standalone.xml 2006-09-12 23:01:03 UTC (rev 124) @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8" ?> + +<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd"> +<log4j:configuration xmlns:log4j='http://jakarta.apache.org/log4j/'> + + <appender name="MAIN" class="org.apache.log4j.RollingFileAppender"> + <param name="File" value="phenote_log4j.log" /> + <param name="Append" value="true" /> + <param name="MaxFileSize" value="1MB" /> + <param name="MaxBackupIndex" value="10" /> + <layout class="org.apache.log4j.PatternLayout"> + <param name="ConversionPattern" value="%d [%t] %-5p %c{2} - %m%n"/> + </layout> + </appender> + + <appender name="console" class="org.apache.log4j.ConsoleAppender"> + <layout class="org.apache.log4j.PatternLayout"> + <param name="ConversionPattern" value="%d [%t] %-5p %c{2} - %m%n"/> + </layout> + </appender> + + <category name="phenote" additivity="true"> + <priority value="debug"/> + <appender-ref ref="MAIN" /> + <appender-ref ref="console"/> + </category> + + <root> + <priority value="info" /> + <appender-ref ref="MAIN" /> + </root> +</log4j:configuration> + Modified: phenote/trunk/conf/log4j.xml =================================================================== --- phenote/trunk/conf/log4j.xml 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/conf/log4j.xml 2006-09-12 23:01:03 UTC (rev 124) @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="UTF-8" ?> +<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd"> <log4j:configuration xmlns:log4j='http://jakarta.apache.org/log4j/'> <appender name="MAIN" class="org.apache.log4j.RollingFileAppender"> @@ -19,7 +20,7 @@ </appender> <category name="phenote" additivity="true"> - <priority value="error"/> + <priority value="info"/> <appender-ref ref="MAIN" /> </category> Modified: phenote/trunk/conf/phenote-config.rnc =================================================================== --- phenote/trunk/conf/phenote-config.rnc 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/conf/phenote-config.rnc 2006-09-12 23:01:03 UTC (rev 124) @@ -5,6 +5,7 @@ element phenote-configuration { attribute version { xsd:float }, check-for-new-ontologies, + log, dataadapter*, field* } @@ -15,12 +16,18 @@ attribute name {"phenoxml" | "phenosyntax"} } -## Whether to +## Whether to check if ontology(obo) has been updated/more current obo file check-for-new-ontologies = element check-for-new-ontologies { attribute intervalMinutes { xsd:integer } } +## Where the config file for log4j is +log = + element log { + attribute config-file { text } + } + field = element field { attribute name { "Pub" | "Genotype" | "Genetic Context" | "Entity" | "Quality" }, Modified: phenote/trunk/conf/phenote-config.xsd =================================================================== --- phenote/trunk/conf/phenote-config.xsd 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/conf/phenote-config.xsd 2006-09-12 23:01:03 UTC (rev 124) @@ -4,6 +4,7 @@ <xs:complexType> <xs:sequence> <xs:element ref="x:check-for-new-ontologies"/> + <xs:element ref="x:log"/> <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:dataadapter"/> <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:field"/> </xs:sequence> @@ -30,6 +31,11 @@ <xs:attribute name="intervalMinutes" use="required" type="xs:integer"/> </xs:complexType> </xs:element> + <xs:element name="log"> + <xs:complexType> + <xs:attribute name="config-file" use="required"/> + </xs:complexType> + </xs:element> <xs:element name="field"> <xs:complexType> <xs:sequence> Modified: phenote/trunk/jars/phenoteconfigbeans.jar =================================================================== (Binary files differ) Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/src/java/phenote/config/Config.java 2006-09-12 23:01:03 UTC (rev 124) @@ -28,7 +28,9 @@ import phenote.config.xml.DataadapterDocument.Dataadapter; import phenote.config.xml.FieldDocument.Field; import phenote.config.xml.OntologyDocument.Ontology; +import phenote.config.xml.LogDocument.Log; +import phenote.util.FileUtil; import phenote.datamodel.CharFieldEnum; import phenote.dataadapter.DataAdapterI; import phenote.dataadapter.fly.FlybaseDataAdapter; @@ -52,6 +54,7 @@ private List<FieldConfig> fieldList = new ArrayList<FieldConfig>(); private boolean checkForNewOntologies = false; private int newOntologyCheckMinutes = 10; + private String logConfigFile = "conf/log4j.xml"; // default log config file /** singleton */ private Config() { @@ -160,6 +163,10 @@ /** How many minutes between checks for new ontologies */ public int getOntologyCheckMinutes() { return newOntologyCheckMinutes; } + public URL getLogConfigUrl() throws FileNotFoundException { + return FileUtil.findUrl(logConfigFile); + } + private FieldConfig getLumpConfig() { // name = Taxonmony, file = BTO.obo... return lumpConfig; @@ -203,13 +210,6 @@ return fieldList; } - /** Default entity list is the anatomy ontology -- DELETE*/ - private List<OntologyConfig> defaultEntityConfigList() { - OntologyConfig oc = new OntologyConfig("Anatomy","anatomy.obo"); - List<OntologyConfig> l = new ArrayList<OntologyConfig>(1); - l.add(oc); - return l; - } /** parse xml file with xml beans (phenoteconfigbeans.xml). Put in own class? */ private void parseXmlFile(String filename) throws ConfigException { @@ -230,6 +230,11 @@ newOntologyCheckMinutes = bi.intValue(); } + // LOG CONFIG FILE + Log log = pc.getLog(); + if (log != null && log.getConfigFile() != null) { + logConfigFile = log.getConfigFile().getStringValue(); + } // DATA ADAPTERS Dataadapter[] adapters = pc.getDataadapterArray(); @@ -256,37 +261,9 @@ } private URL getConfigUrl(String filename) throws FileNotFoundException { - List<URL> possibleUrls = getPossibleUrls(filename); - for (URL u : possibleUrls) - if (urlExists(u)) return u; - System.out.println("Failed to find file "+filename); - throw new FileNotFoundException(filename+" not found"); + return FileUtil.findUrl(filename); } - private List<URL> getPossibleUrls(String filename) { - List<URL> urls = new ArrayList(5); - try { - URL u = new File(filename).toURL(); - if (u != null) urls.add(u); - u = new File("conf/"+filename).toURL(); - if (u != null) urls.add(u); - } catch (MalformedURLException e) { - System.out.println("bad file url "+e); - } - URL jarUrl = Config.class.getResource(filename); - if (jarUrl != null) urls.add(jarUrl); - jarUrl = Config.class.getResource("/"+filename); - if (jarUrl != null) urls.add(jarUrl); - return urls; - } - - private boolean urlExists(URL u) { - try { u.openStream(); } - catch (IOException e) { return false; } - //System.out.println("url suceeded "+u); - return true; - } - // do some other way? DataAdapterManager has mapping? DataAdapter has mapping? // DataAdapterManager.getAdapter(name)??? private void addDataAdapterFromString(String daString) { @@ -345,6 +322,44 @@ } // OLD OLD OLD - DELETE - DOM STUFF - replaced with xml beans +// /** Default entity list is the anatomy ontology -- DELETE*/ +// private List<OntologyConfig> defaultEntityConfigList() { +// OntologyConfig oc = new OntologyConfig("Anatomy","anatomy.obo"); +// List<OntologyConfig> l = new ArrayList<OntologyConfig>(1); +// l.add(oc); +// return l; +// } +// List<URL> possibleUrls = getPossibleUrls(filename); +// for (URL u : possibleUrls) +// if (urlExists(u)) return u; +// System.out.println("Failed to find file "+filename); +// throw new FileNotFoundException(filename+" not found"); +// } + +// private List<URL> getPossibleUrls(String filename) { +// List<URL> urls = new ArrayList(5); +// try { +// URL u = new File(filename).toURL(); +// if (u != null) urls.add(u); +// u = new File("conf/"+filename).toURL(); +// if (u != null) urls.add(u); +// } catch (MalformedURLException e) { +// System.out.println("bad file url "+e); +// } +// URL jarUrl = Config.class.getResource(filename); +// if (jarUrl != null) urls.add(jarUrl); +// jarUrl = Config.class.getResource("/"+filename); +// if (jarUrl != null) urls.add(jarUrl); +// return urls; +// } + +// private boolean urlExists(URL u) { +// try { u.openStream(); } +// catch (IOException e) { return false; } +// //System.out.println("url suceeded "+u); +// return true; +// } + // public OntologyConfig getPatoOntologyConfig() { // return getPatoConfig().getOntologyConfig(); // } Modified: phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2006-09-12 23:01:03 UTC (rev 124) @@ -10,6 +10,7 @@ import java.util.Iterator; import java.util.List; +import org.apache.log4j.Logger; import org.geneontology.oboedit.datamodel.OBOSession; import org.geneontology.oboedit.datamodel.impl.OBOSessionImpl; import org.geneontology.dataadapter.DataAdapterException; @@ -17,6 +18,7 @@ import org.geneontology.dataadapter.IOOperation; import org.geneontology.oboedit.dataadapter.OBOFileAdapter; +import phenote.util.FileUtil; import phenote.datamodel.CharField; import phenote.datamodel.CharFieldEnum; import phenote.datamodel.Ontology; @@ -34,6 +36,7 @@ private Config config; private OntologyManager ontologyManager = OntologyManager.inst(); private boolean loadingOntologies = false; + private static final Logger LOG = Logger.getLogger(OntologyDataAdapter.class); public OntologyDataAdapter() { config = Config.inst(); @@ -54,7 +57,8 @@ Ontology o = loadOntology(oc); cf.addOntology(o); } catch (FileNotFoundException e) { - System.out.println(e.getMessage()+" ignoring ontology, fix config! "); + //System.out.println(e.getMessage()+" ignoring ontology, fix config! "); + LOG.error(e.getMessage()+" ignoring ontology, fix config! "); } } } @@ -70,19 +74,10 @@ /** Load up/cache Sets for all ontologies used, anatomyOntologyTermSet * and patoOntologyTermSet -- move to dataadapter/OntologyDataAdapter... */ private Ontology loadOntology(OntologyConfig ontCfg) throws FileNotFoundException { -// URL url = findFile(ontCfg.ontologyFile); // throws FileNotFoundEx -// File file = new File(url.getFile()); -// long date = file.lastModified(); -// System.out.println("url path "+url.getPath()+" file "+file+" mod "+date+" "+new Date(date)); -// OBOSession oboSession = getOboSession(url); Ontology ontology = new Ontology(ontCfg.name); if (ontCfg.hasFilter()) // set filter before loading obo session ontology.setFilter(ontCfg.getFilter()); loadOboSession(ontology,ontCfg.ontologyFile); // throws FileNotFoundEx -// if (date > 0) { // jar files have 0 date??? -// ontology.setTimestamp(date); -// ontology.setSource(file.toString()); -// } return ontology; } @@ -103,44 +98,47 @@ /** Look for file in current directory (.) and jar file */ private URL findFile(String fileName) throws FileNotFoundException { + return FileUtil.findUrl(fileName); + } - // first try file as is (full path provided) - File file = new File(fileName); - if (file.exists()) - return makeUrl(fileName); +// // first try file as is (full path provided) +// File file = new File(fileName); +// if (file.exists()) +// return makeUrl(fileName); - String oboFileDir = "obo-files/"; - // try current directory + obo-file dir - String currentDir = "./" + oboFileDir + fileName; - file = new File(currentDir); - if (file.exists()) - return makeUrl(currentDir); +// String oboFileDir = "obo-files/"; +// // try current directory + obo-file dir +// String currentDir = "./" + oboFileDir + fileName; +// file = new File(currentDir); +// if (file.exists()) +// return makeUrl(currentDir); - // try jar - hopefully this works... jar files have to have '/' prepended - // first try without obo-files dir (in jar) - String jarFile = "/" + fileName; - URL url = Ontology.class.getResource(jarFile); // looks in jar - // 2nd try with obo-files dir in jar file (i used to do it this way) - if (url == null) { - jarFile = "/" + oboFileDir + fileName; - url = Ontology.class.getResource(jarFile); // looks in jar - } +// // try jar - hopefully this works... jar files have to have '/' prepended +// // first try without obo-files dir (in jar) +// String jarFile = "/" + fileName; +// URL url = Ontology.class.getResource(jarFile); // looks in jar +// // 2nd try with obo-files dir in jar file (i used to do it this way) +// if (url == null) { +// jarFile = "/" + oboFileDir + fileName; +// url = Ontology.class.getResource(jarFile); // looks in jar +// } - if (url == null) { - throw new FileNotFoundException("No file found for "+fileName); - } - return url; - } +// if (url == null) { +// throw new FileNotFoundException("No file found for "+fileName); +// } +// return url; +// } - private URL makeUrl(String file) { - try { - return new URL("file:"+file); - } - catch (MalformedURLException e) { - System.out.println("malformed url "+file+" "+e); - return null; - } - } +// private URL makeUrl(String file) { +// try { +// return new URL("file:"+file); +// } +// catch (MalformedURLException e) { +// //System.out.println("malformed url "+file+" "+e); +// LOG.error("malformed url "+file+" "+e); +// return null; +// } +// } // String -> url to handle web start jar obo files @@ -158,7 +156,8 @@ return os; } catch (DataAdapterException e) { - System.out.println("got data adapter exception: "+e); + //System.out.println("got data adapter exception: "+e); + LOG.error("got data adapter exception: "+e); return null; // empty session? } } @@ -168,24 +167,29 @@ public void run() { int checkMilliSecs = config.getOntologyCheckMinutes() * 60000; + //int checkMilliSecs = 6000;//0.6 * 60000; // debug - 10 secs while(true) { // sleep in milliseconds try { sleep(checkMilliSecs); } - catch (InterruptedException e) { System.out.println("interrupted"); } + catch (InterruptedException e) { LOG.error("thread interrupted??"); } // if still loading ontologies from previous run then dont bother if (loadingOntologies) { - System.out.println("Ontologies are being loaded - ontology checker going "+ - "back to sleep"); + //System.out.println("Ontologies are being loaded - ontology checker going "+ + // "back to sleep"); + LOG.info("Ontologies are being loaded - ontology checker going "+ + "back to sleep"); continue; } - System.out.println("checking for new obo files..."); + LOG.info("checking for new obo files..."); + //System.out.println("checking for new obo files..."); // check for files... synchOntologies(); } } + /** Checks for new obo files */ private void synchOntologies() { for (CharField cf : ontologyManager.getCharFieldList()) { for (Ontology o : cf.getOntologyList()) { @@ -195,11 +199,14 @@ long newTimestamp = new File(file).lastModified(); if (newTimestamp > oldTimestamp) { Date d = new Date(newTimestamp); - System.out.println("loading new obo file "+file+" new date "+d); + //System.out.println("loading new obo file "+file+" new date "+d); + LOG.info("LOG loading new obo file "+file+" new date "+d); try { loadOboSession(o,file); } catch (FileNotFoundException e) { // shouldnt happen - System.out.println(e.getMessage()+" ignoring ontology, fix config! "); + //System.out.println(e.getMessage()+" ignoring ontology, fix config! "); + LOG.error(e.getMessage()+" ignoring ontology, fix config! "); + // LOG.debug(stacktrace)??? no string for stack trace... hmm... } } } @@ -209,6 +216,19 @@ } + + + +// GARBAGE +// if (date > 0) { // jar files have 0 date??? +// ontology.setTimestamp(date); +// ontology.setSource(file.toString()); +// } +// URL url = findFile(ontCfg.ontologyFile); // throws FileNotFoundEx +// File file = new File(url.getFile()); +// long date = file.lastModified(); +// System.out.println("url path "+url.getPath()+" file "+file+" mod "+date+" "+new Date(date)); +// OBOSession oboSession = getOboSession(url); // Ontology pato = loadOntology(config.getPatoOntologyConfig()); // ontologyManager.setPatoOntology(pato); Modified: phenote/trunk/src/java/phenote/gui/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/gui/Phenote.java 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/src/java/phenote/gui/Phenote.java 2006-09-12 23:01:03 UTC (rev 124) @@ -11,7 +11,11 @@ import javax.swing.UIManager; import javax.swing.UnsupportedLookAndFeelException; import javax.swing.plaf.metal.MetalLookAndFeel; +import java.io.FileNotFoundException; +import org.apache.log4j.Logger; +import org.apache.log4j.xml.DOMConfigurator; + import phenote.config.Config; import phenote.config.ConfigException; import phenote.dataadapter.OntologyDataAdapter; @@ -20,6 +24,7 @@ private static final String VERSION = "0.8 dev"; //private static final String DEFAULT_CONFIG_FILE = Config.DEFAULT_CONFIG_FILE; + private static final Logger LOG = Logger.getLogger(Phenote.class); private CharacterTablePanel characterTablePanel; private TermPanel termPanel; @@ -39,6 +44,9 @@ //System.out.println("sys CONFIG prop "+System.getProperty("CONFIG")); phenote = getPhenote(); phenote.initConfig(args); + // put this is in a phenote.util.Log class? - get file from config - default? + try { DOMConfigurator.configure(Config.inst().getLogConfigUrl()); } + catch (FileNotFoundException e) { LOG.error(e.getMessage()); } phenote.initOntologies(); phenote.initGui(); } @@ -84,8 +92,8 @@ else Config.inst().setInitialConfigFile(configFile); } catch (ConfigException e) { - System.out.println("EXITING! Fatal error in config file: "+e.getMessage()); - e.printStackTrace(); + LOG.fatal("EXITING! Fatal error in config file: "+e.getMessage()); + e.printStackTrace(); // log? System.exit(1); } } Modified: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-09-11 15:29:06 UTC (rev 123) +++ phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-09-12 23:01:03 UTC (rev 124) @@ -25,7 +25,8 @@ public class PhenoteServlet extends HttpServlet { private static final String CONFIG_FILE_PARAM = "configuration-file"; - private static final Logger LOG = Logger.getLogger(PhenoteServlet.class); + // PhenoteServlet.class is the distinct name for this logger + private static final Logger LOG = Logger.getLogger(PhenoteServlet.class); //private String configurationFileName; not sure needs to be var private Date initDate; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-09-14 15:33:55
|
Revision: 127 http://svn.sourceforge.net/obo/?rev=127&view=rev Author: mgibson Date: 2006-09-14 08:33:40 -0700 (Thu, 14 Sep 2006) Log Message: ----------- can now read files from command line with phenote -f psfile.psx will figure data adapter from suffix .psx & .syn -> pheno syntax .xml -> pheno xml .pxml? working on writeback from cmd line Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/doc/todo phenote/trunk/src/java/phenote/dataadapter/DataAdapterI.java phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxFileAdapter.java phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java phenote/trunk/src/java/phenote/main/Phenote.java Added Paths: ----------- phenote/trunk/jars/te-common.jar phenote/trunk/src/java/phenote/main/CommandLine.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-09-13 14:31:06 UTC (rev 126) +++ phenote/trunk/build.xml 2006-09-14 15:33:40 UTC (rev 127) @@ -144,6 +144,7 @@ <java classname="phenote.main.Phenote" fork="yes" jvmargs="-Xmx120M"> <!-- arg value="-c configfilehereventually"/ --> <arg value="-c"/> + <!-- from command line with -DCONF-FILE=initial-zfin.cfg --> <arg value="${CONF_FILE}"/> <classpath> <pathelement path="${classfiles}"/> Modified: phenote/trunk/doc/todo =================================================================== --- phenote/trunk/doc/todo 2006-09-13 14:31:06 UTC (rev 126) +++ phenote/trunk/doc/todo 2006-09-14 15:33:40 UTC (rev 127) @@ -1,3 +1,11 @@ +on load keeps blank character (from before load) around in table - shouldnt + +auto load from sourcforge or bioportal + +post compose gui +post compose syntax +post compose pheno xml + column sorting - do shift for descending, also if new added sort it in, and perhaps indicate sorted column in header with < & >? Added: phenote/trunk/jars/te-common.jar =================================================================== (Binary files differ) Property changes on: phenote/trunk/jars/te-common.jar ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: phenote/trunk/src/java/phenote/dataadapter/DataAdapterI.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/DataAdapterI.java 2006-09-13 14:31:06 UTC (rev 126) +++ phenote/trunk/src/java/phenote/dataadapter/DataAdapterI.java 2006-09-14 15:33:40 UTC (rev 127) @@ -10,4 +10,11 @@ public void commit(CharacterListI charList); + /** Set value to use for loading or writeback, for a file adapter this would be + the file name - is there a better name for this method? + For now just doing String - which may be sufficient - may need an + AdapterValue/DataInput object if this gets more involved - but that may + not be necasary - certianly string ok for now */ + public void setAdapterValue(String adapterValue); + } Modified: phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxFileAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxFileAdapter.java 2006-09-13 14:31:06 UTC (rev 126) +++ phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxFileAdapter.java 2006-09-14 15:33:40 UTC (rev 127) @@ -23,12 +23,19 @@ public class PhenoSyntaxFileAdapter implements DataAdapterI { private File previousFile; + private File file; + /** command line setting of file */ + public void setAdapterValue(String filename) { + file = new File(filename); + } + /** this should return CharacterList and caller should load CharListMan or CLM makes the call itself? */ public void load() { - File file = getFileFromUser(previousFile); + if (file == null) + file = getFileFromUser(previousFile); if (file == null) return; previousFile = file; @@ -51,6 +58,7 @@ catch (IOException e) { System.out.println("PhenoSyntax read failure "+e); } + file = null; // null it for next load/commit } /** returns null if user fails to pick a file */ @@ -60,7 +68,8 @@ public void commit(CharacterListI charList) { - File file = getFileFromUser(previousFile); + if (file == null) + file = getFileFromUser(previousFile); if (file == null) return; previousFile = file; @@ -85,6 +94,7 @@ } } pw.close(); + file = null; } } Modified: phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java 2006-09-13 14:31:06 UTC (rev 126) +++ phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java 2006-09-14 15:33:40 UTC (rev 127) @@ -29,13 +29,20 @@ private Set genotypesAlreadyAdded = new HashSet<String>(); private File previousFile; + private File file; + /** command line setting of file */ + public void setAdapterValue(String filename) { + file = new File(filename); + } + public void load() {} public void commit(CharacterListI charList) { - File file = getFileFromUser(previousFile); if (file == null) + file = getFileFromUser(previousFile); + if (file == null) return; previousFile = file; Added: phenote/trunk/src/java/phenote/main/CommandLine.java =================================================================== --- phenote/trunk/src/java/phenote/main/CommandLine.java (rev 0) +++ phenote/trunk/src/java/phenote/main/CommandLine.java 2006-09-14 15:33:40 UTC (rev 127) @@ -0,0 +1,310 @@ +package phenote.main; + +import com.townleyenterprises.command.CommandOption; +import com.townleyenterprises.command.CommandParser; +import com.townleyenterprises.command.DefaultCommandListener; + +import phenote.dataadapter.DataAdapterI; +import phenote.dataadapter.phenosyntax.PhenoSyntaxFileAdapter; +import phenote.dataadapter.phenoxml.PhenoXmlAdapter; + +/** a lot of this is copied from apollo.main.CommandLine - theres potential for + some generic super class but where would it go? in a jar file with one class? + org.bdgp? */ +public class CommandLine { + + /** the class that parses all the options */ + private CommandParser parser; + /** stores adapter class, filenames, etc. for reading data */ + private IOOptions readOptions; + /** stores adapter class, filenames, etc. for writing data */ + private IOOptions writeOptions; + private CommandOption inputFile = new InputFileCommandOption(); + //private CommandOption inputFmtOption = new InputFormatCommandOption(); + private CommandOption writeFile = new WriteFileCommandOption(); + + CommandOption[] options = new CommandOption[] { inputFile, writeFile }; + + // this guarantees that we get the right classes (compile time check) + private final static String PHENOXML = PhenoXmlAdapter.class.getName(); + private final static String PHENOSYNTAX = PhenoSyntaxFileAdapter.class.getName(); + + // there can be only one instance of this class (per JVM) + private static CommandLine commandLineSingleton; + + public static CommandLine inst() { + if (commandLineSingleton == null) + commandLineSingleton = new CommandLine(); + return commandLineSingleton; + } + + /** + * Set command-line arguments passed along from main(). + * + * @param args argStrings from command line + */ + public void setArgs(String[] args) throws Exception { + if (args.length == 0) + return; + if (parser != null) { + System.out.println("CommandLine: WARNING multiple calls to setArgs(), ignoring"); + return; // ? + } + parser = new CommandParser("Phenote"); // help text? + parser.addCommandListener(new DefaultCommandListener("Options",options)); + parser.parse(args); + //addConstraints(parser); + // does execute() on CommandOptions, throws generic Exception + //try { // should i wrap the exception like apollo? + parser.executeCommands(); + //} catch (Exception e) { throw new ApolloAdapterException(e); } + } + + /** + * If input & output (or batch) is fully specified, then we are in command line + * mode; no need for GUI. + */ + public static boolean isInCommandLineMode() { + return inst().writeIsSpecified(); //|| inst().isBatchMode(); + } + + /** if read has been (correctly) specified, read adapter is non null */ + boolean readIsSpecified() { + return getReadOptions().getSpecifiedState(); + } + + boolean writeIsSpecified() { + return getWriteOptions().getSpecifiedState(); + } + + private IOOptions getReadOptions() { + if (readOptions == null) + readOptions = new IOOptions(true); + return readOptions; + } + + private IOOptions getWriteOptions() { + if (writeOptions == null) + writeOptions = new IOOptions(false); + return writeOptions; + } + + /** + * If input/read was specified on the command line this returns the + * correctly-initialized read data adapter for it. Note that + * adapter returned may be the same object as that returned by + * <code>getWriteAdapter()</code> + * @return null if no read adapter specified on command line. + */ + DataAdapterI getReadAdapter() throws Exception { + IOOptions ioo = getReadOptions(); + DataAdapterI adapter = ioo.getAdapter(); + adapter.setAdapterValue(ioo.getAdapterValue()); + return adapter; + } + + + /** INPUT FILE COMMAND OPTION */ + private class InputFileCommandOption extends CommandOption { + private final static String help = + "Specify filename to read in (phenoxml.xml,phenosyntax.syn)"; + private InputFileCommandOption() { + // true -> has argument + super("inputFile",'f',true,"filename",help); + } + public void execute() throws Exception { + //System.out.println("executing input file command option "+getArg()); + getReadOptions().setFilename(getArg()); + setAdapterForFile(getReadOptions(), false); + } + } + + /** + * OUTPUT FILE COMMAND OPTION Specifies name of target/output file. + */ + private class WriteFileCommandOption extends CommandOption { + private WriteFileCommandOption() { + super("writeFile",'w',true,"filename","Filename to write to"); + } + public void execute() throws Exception { + getWriteOptions().setFilename(getArg()); + setAdapterForFile(getWriteOptions(), false); // sets data adapter from file suffix + } + } + + + /** + * Read & write file method. Retrieves data adapter either from format option or + * suffix and sets its DataInput with filename + */ + private void setAdapterForFile(IOOptions options, boolean setAdapterInput) + throws Exception + { + DataAdapterI adapter = getAdapterForFile(options); + if (!options.hasAdapter()) + options.setAdapter(adapter); + // is it scandalous to use DataInput for output?? should be called DataInfo? + // of DataSpecifitation? + String inputFile = options.getFilename(); + //DataInputType inputType = DataInputType.FILE; + //if (inputFile.startsWith("http:") || inputFile.startsWith("file:")) { + //inputType = DataInputType.URL; } + //DataInput di = new DataInput(inputType, inputFile); + // gff input may have seq file. + //if (haveSequenceFilename()) di.setSequenceFilename(getSequenceFilename()); + //options.setDataInput(di); + adapter.setAdapterValue(inputFile); + options.setSpecifiedState(true); + //if (setAdapterInput) adapter.setDataInput(di); + } + + private DataAdapterI getAdapterForFile(IOOptions options) throws Exception { + //DataAdapterI adapter; + // first see if input format explicitly specified + if (options.hasAdapter()) + return options.getAdapter(); + + // if nothing specified try to get format from file suffix + try { return getDataAdapterFromSuffix(options.getFilename()); } + catch (AdapterEx e) { + throw new AdapterEx("No input format specified and "+e.getMessage()); + } + + //return adapter; + } + + private DataAdapterI getDataAdapterFromSuffix(String filename) throws AdapterEx { + String suffix = getFileSuffix(filename); + // anything with game in it?? + if (suffix.matches(".*syn.*|psx")) // ??? + return getDataAdapter(PHENOSYNTAX); + if (suffix.matches(".*xml.*")) + return getDataAdapter(PHENOXML); + // configuration can specify what to do with .xml suffix (game or chado) + //else if (suffix.equals("xml") && xmlSuffixIsConfigged()) + // return getConfiggedXmlDataAdapter(); + throw new AdapterEx("Suffix "+suffix+" doesnt map to known format"); + } + + private class AdapterEx extends Exception { + private AdapterEx(String m) { super(m); } + private AdapterEx(Exception e) { super(e.getMessage()); } // save e? + } + + /** should this include the '.'? probably not. changing it to not include . */ + private String getFileSuffix(String filename) { + int index = filename.lastIndexOf('.'); + return filename.substring(index+1); // 1 past . + } + + private DataAdapterI getDataAdapter(String classString) throws AdapterEx { + try { + // introspection? or switch on string? + Class c = Class.forName(classString); + Object o = c.newInstance(); + if (!(o instanceof DataAdapterI)) // shouldnt happen + System.out.println("Class string is not data adapter "+o); + return (DataAdapterI)o; + } catch (Exception e) { throw new AdapterEx(e); } + } + + // eventually - multiple xmls? +// private boolean xmlSuffixIsConfigged() { +// return Config.commandLineXmlFileFormatIsConfigged(); +// } + +// private ApolloDataAdapterI getConfiggedXmlDataAdapter() { +// String config = Config.getCommandLineXmlFileFormat(); +// if (config.equalsIgnoreCase("game")) +// return getDataAdapter(GAME); +// if (config.equalsIgnoreCase("chado")) +// return getDataAdapter(CHADOXML); +// return null; +// } + + void printHelp() { + parser.help(); + } + + private void error(String m) throws Exception { + System.out.println(m); + printHelp(); + throw new Exception(m); + } + + + // ----------------------------------------------------------------------- + // IOOptions inner class + // ----------------------------------------------------------------------- + + /** + * IOOptions holds state for either read or write + */ + private class IOOptions { + private DataAdapterI adapter; + private String filename; + private boolean specified = false; + private boolean isRead; + private String adapterValue; + + + // ---------------------------------------------- + // Constructor + // ---------------------------------------------- + + private IOOptions(boolean isRead) { + this.isRead = isRead; + } + + // ---------------------------------------------- + // CommandLine - simple getters/setters + // ---------------------------------------------- + + private String getAdapterValue() { return adapterValue; } + + private void setFilename(String filename) { + this.filename = filename; + adapterValue = filename; + } + private String getFilename() { return filename; } + + private void setSpecifiedState(boolean specified) { this.specified = specified; } + private boolean getSpecifiedState() { return specified; } + + // ---------------------------------------------- + // CommandLine + // ---------------------------------------------- + + private void setAdapter(DataAdapterI adapter) { + this.adapter = adapter; + } + private DataAdapterI getAdapter() throws Exception { + if (adapter == null) { + //System.out.println("dont have adapter"); + // if not set from file extension get from format option +// if (isRead) { +// adapter = inputFmtOption.getAdapter(); +// } else { +// adapter = outputFmtOption.getAdapter(); +// } + } + return adapter; + } + private boolean hasAdapter() throws Exception { return getAdapter() != null; } + + /** type of input - type only needed for input */ + //private void setInputType(String inputTypeString) { + // actually i think this is adapter dependent - for game want to do + // stringToType - for chado its a so type + //try {inputType = DataInputType.stringToType(inputTypeString); } + //catch (UnknownTypeException e) { + // System.out.println(e.getMessage()+" Can not set input type"); } + //} + //private DataInputType getInputType() { return inputType; } + //private boolean haveInputType() { return inputType != null; } + + //private void setDataInput(DataInput dataInput) { this.dataInput = dataInput; } + //private DataInput getDataInput() { return this.dataInput; } + + } +} Modified: phenote/trunk/src/java/phenote/main/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/main/Phenote.java 2006-09-13 14:31:06 UTC (rev 126) +++ phenote/trunk/src/java/phenote/main/Phenote.java 2006-09-14 15:33:40 UTC (rev 127) @@ -35,6 +35,7 @@ private TermPanel termPanel; private static Phenote phenote; private TermInfo termInfo; + private CommandLine commandLine = CommandLine.inst(); public static void main(String[] args) { @@ -46,35 +47,50 @@ catch (UnsupportedLookAndFeelException e) { System.out.println("Failed to set to Java/Metal look & feel"); } - //System.out.println("sys CONFIG prop "+System.getProperty("CONFIG")); phenote = getPhenote(); - phenote.initConfig(args); + //phenote.initConfig(args); + phenote.doCommandLine(args); // does config // put this is in a phenote.util.Log class? - get file from config - default? try { DOMConfigurator.configure(Config.inst().getLogConfigUrl()); } catch (FileNotFoundException e) { LOG.error(e.getMessage()); } phenote.initOntologies(); + phenote.loadFromCommandLine(); // cant load data til ontologies loaded i think + phenote.initGui(); } /** private constructor -> singleton */ private Phenote() {} - /** args is most likely null if not called from command line */ - public void initConfig(String[] args) { - // gets config file from command line & loads - if no config file - // loads default. should actually put that logic here. - doCommandLine(args); // load config file - } +// /** args is most likely null if not called from command line */ +// public void initConfig(String[] args) { +// // gets config file from command line & loads - if no config file +// // loads default. should actually put that logic here. +// doCommandLine(args); // load config file +// } public void initOntologies() { OntologyDataAdapter oda = new OntologyDataAdapter(); // singleton? oda.loadOntologies(); // loads up OntologyManager } + + private void loadFromCommandLine() { + //LOG.debug("read spec "+commandLine.readIsSpecified()); + if (!commandLine.readIsSpecified()) return; + try { commandLine.getReadAdapter().load(); } + catch (Exception e) { LOG.error("Failed to do load via command line "+e); } + } public void initGui() { makeWindow(); } + private void doCommandLine(String[] args) { + doCommandLineOld(args); // -c -i --> move to CommandLine! + try { commandLine.setArgs(args); } // no log yet - sys.out + catch (Exception e) { System.out.println("Command line read failed"+e); } + } + /** for now just looking for '-c configFile.cfg', use command line package if we need to get more sophisticated so if user has personal config file should override this - however maybe @@ -85,7 +101,7 @@ and -c file.cfg will load/overwrite that cfg into .phenote/my-phenote.cfg (if it exists) - we can always add --init later if we need it -c overwrites, -i doesnt -i is for initial startup of phenote */ - private void doCommandLine(String[] args) { + private void doCommandLineOld(String[] args) { String configFile = getConfigFileFromCommandLine(args); // if no config file specified then set default initial config file. this will be // overridden by a personal config file if it exists This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-10-31 20:50:24
|
Revision: 171 http://svn.sourceforge.net/obo/?rev=171&view=rev Author: mgibson Date: 2006-10-31 12:50:09 -0800 (Tue, 31 Oct 2006) Log Message: ----------- web dev docs some work with getting syns in auto comp list in servlet/web not yet displaying term on selecting syn - getting there... may need to fiddle with ajax classes as shu has done Modified Paths: -------------- phenote/trunk/doc/developer-docs phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java phenote/trunk/src/java/phenote/gui/field/CompletionTerm.java phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java phenote/trunk/src/web/html/ncbo.html Added Paths: ----------- phenote/trunk/doc/web-developer-docs Modified: phenote/trunk/doc/developer-docs =================================================================== --- phenote/trunk/doc/developer-docs 2006-10-31 15:53:08 UTC (rev 170) +++ phenote/trunk/doc/developer-docs 2006-10-31 20:50:09 UTC (rev 171) @@ -38,3 +38,13 @@ So if a field only has one ontology you can shove that file in the field element as an attribute. For multiple ontologies you need to add ontology elements. Once the gui configuration is in place no one will need to know about this (unless one prefers mucking with xml over guis). + + + +> Is it correct that you keep the file information from which an ontology +> was loaded? + +yes - phenote keeps the file name (source) and timestamp (as long) in +phenote.datamodel.Ontology +phenote.datamodel.OntologyManager has a list of +phenote.datamodel.CharFields which have a list of Ontologys Added: phenote/trunk/doc/web-developer-docs =================================================================== --- phenote/trunk/doc/web-developer-docs (rev 0) +++ phenote/trunk/doc/web-developer-docs 2006-10-31 20:50:09 UTC (rev 171) @@ -0,0 +1,150 @@ +heres how PhenoteServlet makes the auto completion response: + + private String getCompletionList(String userInput,String ontol,String field) { + StringBuffer sb = new StringBuffer("<ul>"); + try { + Vector<CompletionTerm> v = +getCompListSearcher(ontol).getStringMatchTerms(userInput); + //Vector<OBOClass> v = ontology.getStringMatchTerms(userInput, +getSearchParams()); + for (CompletionTerm ct : v) + sb.append(makeCompListHtmlItem(ct, ontol, field)); + } + catch (OntologyException e) { sb.append(e.getMessage()); } + sb.append("</ul>"); + return sb.toString(); + } + private String makeCompListHtmlItem(CompletionTerm term, String ontol,String +field) { + String id = term.getID(), name=term.getName(); + String display = term.getCompListDisplayString(); + // pass in id, name & ontology - name for setting field on UseTerm + StringBuffer info = dq(fn("getTermInfo",new String[]{id,name,ontol,field})); + StringBuffer select = dq(fn("selectTerm",new String[]{name,field})); + //String info = "\"getTermInfo("+id +","+q(name)+","+ q(ontol) + ")\""; + return "<li onmouseover=" + info + " id=" + q(id) + " " + + "onclick=" + select + ">" + display + "</li>\n"; + } + + private static StringBuffer fn(String fnName, String[] params) { + return HtmlUtil.fn(fnName,params); + } + + +so basically the ajax autocompleter expects a <ul> list - not a page, not a +single string. furthermore the <li> elements of the list have onMouseOver +getTermInfo javascript functions wired into them. Im working on a selectTerm +fuction on mouse click to get term names to show up on synonym select but that +isnt working yet. So the response needs to look like this: + +<ul> + <li onmouseover=getTermInfo('id','name','ontol','field') id='id' + onclick=selectTerm('name','field') > termName </li> + <li ... +</ul> + + +src/web documentation of js,html,ajax...: + +This is a web widget to search ontologies dynamically using Ajax. The +following describes the various compoents of the widget and how to use it. + +Style sheet: /css/control.js +This contains all the styles used in the widget + +Javascript: +/javascript/dichty-term-info.js contains a method to call Ajax to +update the Ontology information in the term info panel. +In this javascript the "var url" should point to the processing script. + +/javascript/ajax-lib contains Ajax libraries from Prototype +for ajax and its auto completer +http://prototype.conio.net/ + +Perl +/perl contains an example of a Ajax request processing script. +It is written in CGI perl. + + +------------------- +src/web/html Files: +------------------- +dichty.html interface.html ncbo.html term_completer.html + +dichty.html: I think this is old and should be deleted - sohel? replaced by interface.html + + +interface.html: +--------------- +This should be renamed dichty-top.html as this is dichty base's new +top level html page. The improvement over dichty.html (amongst other additions) is +that it generically creates fields using the Sever Side Includes(SSI) file +term_completer.html. Also has commit & retrieve buttons, that call javascript functions. + +term_completer.html +------------------- +This is generic server side include stuff for interface.html. It takes vars tag, title, + & url. see interface.html for use. This should be renamed term_completion_field.ssi + or just field.ssi (are all fields term completion - some may be free text) or + field_template.ssi? + + +ncbo.html +--------- +This is the top html page for ncbo/zfin (rename zfin.html?). It should use the new +SSI paradigm and use the term_completer.html SSI stuff. But this does have stuff that +interface/term_completer lacks. That is it has an entity chooser (dichtybase has no +need for one), and a UseTerm button. These require both an ontology name and field +name to be passed into the auto completion function. Also method names are renamed +for clarity sake. + + +So in summary ncbo.html & interface.html need to grab stuff from each other. Both of which +serve as templates for new groups coming up with there own top level page (mod.html) + + + +-------------------------- +src/web/javascript readme +-------------------------- +3 files: dichty-term-info.js ncbo-term-info.js term-completer.js +one sub directory: ajax-lib + +ajax-lib is open source ajax code from scriptaculous that the above files use. +in theory these shouldnt need to be modified (though ive had my temptations) + +The 3 scripts are all for term info retrieval from the backend. They should +probably be merged & deleted. The main variant is the backend url to get term info +from and that url should come from the top page where all mod specific stuff is set, +rather than here. Once that is done should be able to merge. + +These scripts are called with onMouseOver that is in the completion list that is +returned by the backend server(be it perl servlet or whatnot) for autocompletion. + +dichty-term-info.js might be old and if so should be deleted? sohel? + +term_completer.js is the new dichty base script (or old??) should be merged +with ncbo-term-info.js. Sohel that would require you to change your mouseOver +function call from the completion list to getTermInfo - would that be ok? + +ncbo-term-info.js +----------------- +is used for zfin/ncbo. There are some difference to dichty here. +The method is called getTermInfo which is a clearer name then set_ontology or +set_ontology_term. The url is different and as said above should be set in +the top mod specific page not here. + +OntologyName & field are passed as +parameters. Ontology name is needed for cases where theres an ontology chooser +(zfin entity - dichty can ignore this). field is needed so the Use Term button +of TermInfo knows which field to update (its the field the original term came from). + +In the top level html (ncbo.html) the form with the terms is given the name +termForm and that is used instead of forms[0] which can be presumptious if plugging +into a mods web page. + +The checking of the length of the ontologyid array was scrapped as it was unnecasary. + +So these scripts should be merged, and I think the ncbo changes should be incorporated. +Would you agree sohel? + Modified: phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2006-10-31 15:53:08 UTC (rev 170) +++ phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2006-10-31 20:50:09 UTC (rev 171) @@ -126,46 +126,8 @@ return FileUtil.findUrl(fileName); } -// // first try file as is (full path provided) -// File file = new File(fileName); -// if (file.exists()) -// return makeUrl(fileName); -// String oboFileDir = "obo-files/"; -// // try current directory + obo-file dir -// String currentDir = "./" + oboFileDir + fileName; -// file = new File(currentDir); -// if (file.exists()) -// return makeUrl(currentDir); -// // try jar - hopefully this works... jar files have to have '/' prepended -// // first try without obo-files dir (in jar) -// String jarFile = "/" + fileName; -// URL url = Ontology.class.getResource(jarFile); // looks in jar -// // 2nd try with obo-files dir in jar file (i used to do it this way) -// if (url == null) { -// jarFile = "/" + oboFileDir + fileName; -// url = Ontology.class.getResource(jarFile); // looks in jar -// } - -// if (url == null) { -// throw new FileNotFoundException("No file found for "+fileName); -// } -// return url; -// } - -// private URL makeUrl(String file) { -// try { -// return new URL("file:"+file); -// } -// catch (MalformedURLException e) { -// //System.out.println("malformed url "+file+" "+e); -// LOG.error("malformed url "+file+" "+e); -// return null; -// } -// } - - // String -> url to handle web start jar obo files private OBOSession getOboSession(URL oboUrl) { if (oboUrl == null) @@ -245,6 +207,44 @@ // GARBAGE +// // first try file as is (full path provided) +// File file = new File(fileName); +// if (file.exists()) +// return makeUrl(fileName); + +// String oboFileDir = "obo-files/"; +// // try current directory + obo-file dir +// String currentDir = "./" + oboFileDir + fileName; +// file = new File(currentDir); +// if (file.exists()) +// return makeUrl(currentDir); + +// // try jar - hopefully this works... jar files have to have '/' prepended +// // first try without obo-files dir (in jar) +// String jarFile = "/" + fileName; +// URL url = Ontology.class.getResource(jarFile); // looks in jar +// // 2nd try with obo-files dir in jar file (i used to do it this way) +// if (url == null) { +// jarFile = "/" + oboFileDir + fileName; +// url = Ontology.class.getResource(jarFile); // looks in jar +// } + +// if (url == null) { +// throw new FileNotFoundException("No file found for "+fileName); +// } +// return url; +// } + +// private URL makeUrl(String file) { +// try { +// return new URL("file:"+file); +// } +// catch (MalformedURLException e) { +// //System.out.println("malformed url "+file+" "+e); +// LOG.error("malformed url "+file+" "+e); +// return null; +// } +// } // if (date > 0) { // jar files have 0 date??? // ontology.setTimestamp(date); // ontology.setSource(file.toString()); Modified: phenote/trunk/src/java/phenote/gui/field/CompletionTerm.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/CompletionTerm.java 2006-10-31 15:53:08 UTC (rev 170) +++ phenote/trunk/src/java/phenote/gui/field/CompletionTerm.java 2006-10-31 20:50:09 UTC (rev 171) @@ -31,10 +31,10 @@ boolean isStartsWithMatch() { return startsWith; } public String toString() { - return compListDisplayString(); + return getCompListDisplayString(); } - private String compListDisplayString() { + public String getCompListDisplayString() { StringBuffer display = new StringBuffer(); StringBuffer appends = new StringBuffer(); if (isSynMatch()) { Modified: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-10-31 15:53:08 UTC (rev 170) +++ phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java 2006-10-31 20:50:09 UTC (rev 171) @@ -75,7 +75,12 @@ /** * AUTO COMPLETE REQUEST * this should be done in java server faces/pages(?), post comes from ajax - * autocompleter on typing in stuff + * autocompleter on typing in stuff. prints html ul list to response: + <ul> + <li onmouseover=getTermInfo('id','name','ontol','field') id='id' + onclick=selectTerm('name','field') > termName </li> + <li ... + </ul> */ public void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { @@ -220,11 +225,13 @@ private String makeCompListHtmlItem(CompletionTerm term, String ontol,String field) { String id = term.getID(), name=term.getName(); + String display = term.getCompListDisplayString(); // pass in id, name & ontology - name for setting field on UseTerm StringBuffer info = dq(fn("getTermInfo",new String[]{id,name,ontol,field})); + StringBuffer select = dq(fn("selectTerm",new String[]{name,field})); //String info = "\"getTermInfo("+id +","+q(name)+","+ q(ontol) + ")\""; return "<li onmouseover=" + info + " id=" + q(id) + " " + - "onclick=" + info + ">" + name + "</li>\n"; + "onclick=" + select + ">" + display + "</li>\n"; } private static StringBuffer fn(String fnName, String[] params) { @@ -254,25 +261,25 @@ } private class HardWiredSearchParams implements SearchParamsI { - public boolean searchTerms() { - return true; - } - - public boolean searchSynonyms() { - return false; // --> true - } - - public boolean searchDefinitions() { - return false; // ?? w [def]?? - } - - /** - * Whether to include obsoletes in searching terms, syns, & definitions - * This should be in conjunction with the other 3 - */ - public boolean searchObsoletes() { - return false; // --> true w [obs], disallow selection - } + public boolean searchTerms() { + return true; + } + + public boolean searchSynonyms() { + return true; // --> true + } + + public boolean searchDefinitions() { + return false; // ?? w [def]?? + } + + /** + * Whether to include obsoletes in searching terms, syns, & definitions + * This should be in conjunction with the other 3 + */ + public boolean searchObsoletes() { + return false; // --> true w [obs], disallow selection + } } } Modified: phenote/trunk/src/web/html/ncbo.html =================================================================== --- phenote/trunk/src/web/html/ncbo.html 2006-10-31 15:53:08 UTC (rev 170) +++ phenote/trunk/src/web/html/ncbo.html 2006-10-31 20:50:09 UTC (rev 171) @@ -165,8 +165,23 @@ } </script> + <script type="text/javascript"> + function selectTerm(termName) { + var field = document.termForm.activeField.value; + //var termName = document.termForm.termInfoTermName.value; + //alert('use term info fn called - field '+field+' name '+termName); + <!-- document.termForm.qualityInput.value=document.termForm.termId.value; --> + if (field == "ENTITY") { + document.termForm.entityInput.value = termName; + } + else { + document.termForm.qualityInput.value= termName; + } + } + </script> + <!-- /td --> <!-- /tr --> <!-- tr height="80%" --><!-- td --> <!-- /td --></tr --> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cm...@us...> - 2006-11-03 23:03:03
|
Revision: 182 http://svn.sourceforge.net/obo/?rev=182&view=rev Author: cmpich Date: 2006-11-03 15:02:48 -0800 (Fri, 03 Nov 2006) Log Message: ----------- Added a simple home page that points to test pages and an admin page changed svn to use native eol style so that Win users do not mess up the EOL characters Modified Paths: -------------- phenote/trunk/src/web/WEB-INF/jsp/ajax.jsp phenote/trunk/src/web/WEB-INF/phenote-servlet.xml phenote/trunk/src/web/WEB-INF/web.xml Added Paths: ----------- phenote/trunk/jars/jstl-1.1.jar phenote/trunk/src/java/phenote/servlet/AdminBean.java phenote/trunk/src/java/phenote/servlet/AdminController.java phenote/trunk/src/web/WEB-INF/jsp/admin.jsp phenote/trunk/src/web/css/phenote.css phenote/trunk/src/web/index.html Property Changed: ---------------- phenote/trunk/src/java/phenote/servlet/PhenoteBean.java phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java phenote/trunk/src/web/WEB-INF/jsp/ajax.jsp phenote/trunk/src/web/css/control.css Added: phenote/trunk/jars/jstl-1.1.jar =================================================================== (Binary files differ) Property changes on: phenote/trunk/jars/jstl-1.1.jar ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: phenote/trunk/src/java/phenote/servlet/AdminBean.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/AdminBean.java (rev 0) +++ phenote/trunk/src/java/phenote/servlet/AdminBean.java 2006-11-03 23:02:48 UTC (rev 182) @@ -0,0 +1,25 @@ +package phenote.servlet; + +import phenote.datamodel.Ontology; + +import java.util.List; + +/** + * Created by IntelliJ IDEA. + * User: Christian Pich + * Date: Nov 3, 2006 + * Time: 10:57:20 AM + * To change this template use File | Settings | File Templates. + */ +public class AdminBean { + + private List<Ontology> ontologies; + + public List<Ontology> getOntologies() { + return ontologies; + } + + public void setOntologies(List<Ontology> ontologies) { + this.ontologies = ontologies; + } +} Added: phenote/trunk/src/java/phenote/servlet/AdminController.java =================================================================== --- phenote/trunk/src/java/phenote/servlet/AdminController.java (rev 0) +++ phenote/trunk/src/java/phenote/servlet/AdminController.java 2006-11-03 23:02:48 UTC (rev 182) @@ -0,0 +1,28 @@ +package phenote.servlet; + +import org.springframework.web.servlet.mvc.Controller; +import org.springframework.web.servlet.ModelAndView; + +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import phenote.datamodel.Ontology; +import phenote.datamodel.OntologyManager; + +import java.util.List; + +/** + * Controller that serves the version page: lists ontologies and their + * meta data. + */ +public class AdminController implements Controller { + + public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response) throws Exception { + + AdminBean form = new AdminBean(); + List<Ontology> ontologies = OntologyManager.inst().getAllOntologies(); + form.setOntologies(ontologies); + + return new ModelAndView("admin", "formBean", form); + } +} Property changes on: phenote/trunk/src/java/phenote/servlet/PhenoteBean.java ___________________________________________________________________ Name: svn:eol-style + native Property changes on: phenote/trunk/src/java/phenote/servlet/PhenoteServlet.java ___________________________________________________________________ Name: svn:eol-style + native Added: phenote/trunk/src/web/WEB-INF/jsp/admin.jsp =================================================================== --- phenote/trunk/src/web/WEB-INF/jsp/admin.jsp (rev 0) +++ phenote/trunk/src/web/WEB-INF/jsp/admin.jsp 2006-11-03 23:02:48 UTC (rev 182) @@ -0,0 +1,55 @@ +<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %> + +<html> +<head> + <title>List of Ontologies</title> + <link type="text/css" rel="stylesheet" href="<%= request.getContextPath()%>/css/phenote.css"/> +</head> + +<body> + + +<table cellpadding="2" cellspacing="1" border="0" width="80%"> + + <tr><td colspan="4" class="sectionTitle">Phenote Application</td></tr> + <tr> + <td class="listContentBold"> + Version + </td> + <td colspan="3" class="listContent"> + 0.9 + </td> + </tr> + <tr> + <td class="listContentBold"> + Date + </td> + <td colspan="3" class="listContent"> + 2006 + </td> + </tr> + <tr><td colspan="4" class="sectionTitle"> List of Ontologies</td></tr> + <tr> + <td width="100" class="sectionTitle">Ontology Name</td> + <td class="sectionTitle">Version</td> + <td class="sectionTitle">File Name</td> + <td class="sectionTitle">File Date</td> + </tr> + <c:forEach var="item" items="${formBean.ontologies}"> + <tr> + <td class="listContentBold"> + <c:out value='${item.name}'/> + </td> + <td class="listContent"> + </td> + <td class="listContent"> + <c:out value='${item.source}'/> + </td> + <td class="listContent"> + </td> + </tr> + </c:forEach> +</table> +</body> +</html> + Property changes on: phenote/trunk/src/web/WEB-INF/jsp/admin.jsp ___________________________________________________________________ Name: svn:eol-style + native Modified: phenote/trunk/src/web/WEB-INF/jsp/ajax.jsp =================================================================== --- phenote/trunk/src/web/WEB-INF/jsp/ajax.jsp 2006-11-03 19:38:34 UTC (rev 181) +++ phenote/trunk/src/web/WEB-INF/jsp/ajax.jsp 2006-11-03 23:02:48 UTC (rev 182) @@ -1,6 +1,6 @@ -<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %> -<html> -<body> -<c:out value="${formBean.ajaxList}" escapeXml="false"/> -</body> +<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %> +<html> +<body> +<c:out value="${formBean.ajaxList}" escapeXml="false"/> +</body> </html> \ No newline at end of file Property changes on: phenote/trunk/src/web/WEB-INF/jsp/ajax.jsp ___________________________________________________________________ Name: svn:eol-style + native Modified: phenote/trunk/src/web/WEB-INF/phenote-servlet.xml =================================================================== --- phenote/trunk/src/web/WEB-INF/phenote-servlet.xml 2006-11-03 19:38:34 UTC (rev 181) +++ phenote/trunk/src/web/WEB-INF/phenote-servlet.xml 2006-11-03 23:02:48 UTC (rev 182) @@ -15,6 +15,8 @@ <bean name="/" class="phenote.servlet.PhenoteController"/> + <bean name="/admin.ph" class="phenote.servlet.AdminController"/> + <bean id="viewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver" > <property name="prefix"> <value>/WEB-INF/jsp/</value> @@ -46,7 +48,28 @@ </property> </bean> - <bean id="cronOntologyTrigger" class="org.springframework.scheduling.quartz.CronTriggerBean"> + <bean id="geneOntologyReloadJob" class="org.springframework.scheduling.quartz.JobDetailBean"> + <property name="jobClass"> + <value>phenote.jobs.OntologyUpdateJob</value> + </property> + <property name="jobDataAsMap"> + <map> + <entry key="ontologyName"> + <value>GO</value> + </entry> + <!-- This directory is relative to the webroot --> + <entry key="archiveDirectory"> + <value>archive-ontology</value> + </entry> + <!-- time stated in days (can be a fraction) --> + <entry key="purgePeriodInDays"> + <value>0.0035</value> + </entry> + </map> + </property> + </bean> + + <bean id="cronAOTrigger" class="org.springframework.scheduling.quartz.CronTriggerBean"> <property name="jobDetail"> <ref bean="anatomyOntologyReloadJob"/> </property> @@ -58,7 +81,7 @@ <bean class="org.springframework.scheduling.quartz.SchedulerFactoryBean"> <property name="triggers"> <list> - <ref bean="cronOntologyTrigger"/> + <ref bean="cronAOTrigger"/> </list> </property> </bean> Modified: phenote/trunk/src/web/WEB-INF/web.xml =================================================================== --- phenote/trunk/src/web/WEB-INF/web.xml 2006-11-03 19:38:34 UTC (rev 181) +++ phenote/trunk/src/web/WEB-INF/web.xml 2006-11-03 23:02:48 UTC (rev 182) @@ -1,7 +1,6 @@ <?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE web-app - PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" - "http://java.sun.com/j2ee/dtds/web-app_2_4.dtd"> + PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/dtd/web-app_2_3.dtd"> <web-app> <servlet> @@ -20,7 +19,7 @@ </servlet-mapping> <welcome-file-list> - <welcome-file>html/ncbo.html</welcome-file> + <welcome-file>/index.html</welcome-file> </welcome-file-list> </web-app> Property changes on: phenote/trunk/src/web/css/control.css ___________________________________________________________________ Name: svn:eol-style + native Added: phenote/trunk/src/web/css/phenote.css =================================================================== --- phenote/trunk/src/web/css/phenote.css (rev 0) +++ phenote/trunk/src/web/css/phenote.css 2006-11-03 23:02:48 UTC (rev 182) @@ -0,0 +1,26 @@ +.sectionTitle { + color: #FFFFFF; + font-size: 10pt; + line-height: 15pt; + font-weight: bold; + padding-left: 10px; + background-color: #000000; +} + +.listContent { + font-size: 10pt; + padding-left: 10px; + padding-right: 10px; + vertical-align: top; + background-color: #EEEEEE; +} + +.listContentBold { + font-size: 10pt; + padding-left: 10px; + padding-right: 10px; + font-weight: bold; + vertical-align: top; + background-color: #EEEEEE; +} + Added: phenote/trunk/src/web/index.html =================================================================== --- phenote/trunk/src/web/index.html (rev 0) +++ phenote/trunk/src/web/index.html 2006-11-03 23:02:48 UTC (rev 182) @@ -0,0 +1,40 @@ +<html> +<head> + <title>Phenote Web Admin</title> + <link type="text/css" rel="stylesheet" href="/phenote/css/phenote.css"/> +</head> + +<body> + +<table cellpadding="2" cellspacing="1" border="0" width="80%"> + + <tr><td colspan="3" class="sectionTitle">Phenote Application:</td></tr> + + <tr> + <td valign=top class="listContentBold"> + Check ncbo test page: </td> + <td colspan="2" class="listContent"> + <a href="html/ncbo.html">NCBO Test page</a> + </td> + </tr> + <tr> + <td valign=top class="listContentBold"> + Test Ajax Return String: + </td> + <td colspan="2" class="listContent"> + <a href="html/ajax-test.html">Test Ajax Return String</a> + </td> + </tr> + + <tr> + <td valign=top class="listContentBold"> + Phenote Versions: </td> + <td colspan="2" class="listContent"> + <a href="Phenote/admin.ph">Versions</a> + </td> + </tr> +</table> + + +</body> +</html> \ No newline at end of file Property changes on: phenote/trunk/src/web/index.html ___________________________________________________________________ Name: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-11-10 21:48:30
|
Revision: 197 http://svn.sourceforge.net/obo/?rev=197&view=rev Author: mgibson Date: 2006-11-10 13:48:24 -0800 (Fri, 10 Nov 2006) Log Message: ----------- preserving order on undo for bulk delete its sorta funny if ya dont Modified Paths: -------------- phenote/trunk/conf/initial-flybase.cfg phenote/trunk/conf/initial-zfin.cfg phenote/trunk/src/java/phenote/datamodel/CharacterList.java phenote/trunk/src/java/phenote/datamodel/CharacterListI.java phenote/trunk/src/java/phenote/edit/CompoundTransaction.java phenote/trunk/src/java/phenote/edit/DeleteTransaction.java Modified: phenote/trunk/conf/initial-flybase.cfg =================================================================== --- phenote/trunk/conf/initial-flybase.cfg 2006-11-10 21:18:30 UTC (rev 196) +++ phenote/trunk/conf/initial-flybase.cfg 2006-11-10 21:48:24 UTC (rev 197) @@ -2,6 +2,7 @@ <phenote-configuration version="0.8" xmlns="phenote/config/xml"> <dataadapter name="phenosyntax"/> + <dataadapter name="phenoxml"/> <log config-file="conf/log4j-standalone.xml" /> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-11-10 21:18:30 UTC (rev 196) +++ phenote/trunk/conf/initial-zfin.cfg 2006-11-10 21:48:24 UTC (rev 197) @@ -1,6 +1,7 @@ <phenote-configuration version="0.8" xmlns="phenote/config/xml"> <dataadapter name="phenosyntax"/> + <dataadapter name="phenoxml"/> <log config-file="conf/log4j.xml"/> Modified: phenote/trunk/src/java/phenote/datamodel/CharacterList.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharacterList.java 2006-11-10 21:18:30 UTC (rev 196) +++ phenote/trunk/src/java/phenote/datamodel/CharacterList.java 2006-11-10 21:48:24 UTC (rev 197) @@ -15,9 +15,11 @@ public CharacterI get(int i) { return characterList.get(i); } public void add(CharacterI c) { characterList.add(c); } + public void add(int i, CharacterI c) {characterList.add(i,c); } public void remove(int i) { characterList.remove(i); } public void remove(CharacterI c) { characterList.remove(c); } public int size() { return characterList.size(); } + public int indexOf(CharacterI c) { return characterList.indexOf(c); } public List<CharacterI> getList() { return characterList; } public boolean equals(CharacterListI cl) { Modified: phenote/trunk/src/java/phenote/datamodel/CharacterListI.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharacterListI.java 2006-11-10 21:18:30 UTC (rev 196) +++ phenote/trunk/src/java/phenote/datamodel/CharacterListI.java 2006-11-10 21:48:24 UTC (rev 197) @@ -10,9 +10,11 @@ public CharacterI get(int i); public void add(CharacterI c); + public void add(int order,CharacterI c); public void remove(int i); public void remove(CharacterI c); public int size(); + public int indexOf(CharacterI c); public List<CharacterI> getList(); public boolean equals(CharacterListI cl); /** Sort data by char field enum field */ Modified: phenote/trunk/src/java/phenote/edit/CompoundTransaction.java =================================================================== --- phenote/trunk/src/java/phenote/edit/CompoundTransaction.java 2006-11-10 21:18:30 UTC (rev 196) +++ phenote/trunk/src/java/phenote/edit/CompoundTransaction.java 2006-11-10 21:48:24 UTC (rev 197) @@ -56,8 +56,12 @@ } public void undo() { - for (TransactionI childTrans : childTransactions) - childTrans.undo(); + // actually i think for undo it should be done in reverse - this actually + // matters for delete getting order correct + //for (TransactionI childTrans : childTransactions) + //childTrans.undo(); + for (int i=childTransactions.size()-1; i>=0; i--) + childTransactions.get(i).undo(); } List<TransactionI> getTransactions() { return childTransactions; } Modified: phenote/trunk/src/java/phenote/edit/DeleteTransaction.java =================================================================== --- phenote/trunk/src/java/phenote/edit/DeleteTransaction.java 2006-11-10 21:18:30 UTC (rev 196) +++ phenote/trunk/src/java/phenote/edit/DeleteTransaction.java 2006-11-10 21:48:24 UTC (rev 197) @@ -8,14 +8,20 @@ class DeleteTransaction implements TransactionI { private CharacterI delChar; + // remember where the char was in the list for undo + private int listOrder; DeleteTransaction(CharacterI c) { delChar = c; } public void editModel() { + listOrder = getCharList().indexOf(delChar); getCharList().remove(delChar); } - public void undo() { getCharList().add(delChar); } + // this doesnt put it where it came from on bulk delete as its getting reentered in + // opposite order it got deleted - maybe compound trans should be aware and do kids + // in reverse on undo? - actually thats general + public void undo() { getCharList().add(listOrder,delChar); } public boolean isUpdate() { return false; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-11-22 20:26:16
|
Revision: 219 http://svn.sourceforge.net/obo/?rev=219&view=rev Author: mgibson Date: 2006-11-22 12:26:15 -0800 (Wed, 22 Nov 2006) Log Message: ----------- so ive added the ability to get generic - that is you can now specify any field you want in the config file - you are no longer restricted to just the limited set that phenote knows about - however the data adapter is another matter - the data adapter has to know what you are setting up - and currently the data adapters are broken - will fix soon the datamodel is now basically a hash of char fields to char field values. no longer a hardwired datamodel - which is wierd to me - but given the need for a configuration driven data there was no other way to go. char field enum and the hard wired datamdoel need to be phased out - i dont think they are actually being used anywhere - need to clean that up - the big methods are no Character.setValue(CharField,CharFieldValue) and CharFieldValue Char.getValue(CharField) table gets char field info from ontology manager for column/int in same checkin - related: added new fields cos i can! evidence, description, absent, abnormal made a slim of pato for abnormal & absent - 2 term slims phenote can now read in slims - this will be useful for attribute slim as well Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/conf/initial-flybase.cfg phenote/trunk/conf/initial-zfin.cfg phenote/trunk/conf/phenote-config.rnc phenote/trunk/conf/phenote-config.xsd phenote/trunk/jars/BrowserLauncher2-10rc4.jar phenote/trunk/jars/commons-lang-2.1.jar phenote/trunk/jars/commons-logging-1.0.4.jar phenote/trunk/jars/jsr173_1.0_api.jar phenote/trunk/jars/jstl-1.1.jar phenote/trunk/jars/junit-4.0.jar phenote/trunk/jars/log4j-1.2.13.jar phenote/trunk/jars/oboedit.jar phenote/trunk/jars/org.geneontology.jar phenote/trunk/jars/phenoteconfigbeans.jar phenote/trunk/jars/phenoxmlbeans.jar phenote/trunk/jars/quartz-1.5.2.jar phenote/trunk/jars/spring.jar phenote/trunk/jars/standard-1.1.jar phenote/trunk/jars/te-common.jar phenote/trunk/jars/tomcat-servlet.jar phenote/trunk/jars/xbean.jar phenote/trunk/obo-files/quality.obo phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/config/FieldConfig.java phenote/trunk/src/java/phenote/config/OntologyConfig.java phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java phenote/trunk/src/java/phenote/datamodel/CharField.java phenote/trunk/src/java/phenote/datamodel/CharFieldEnum.java phenote/trunk/src/java/phenote/datamodel/CharFieldValue.java phenote/trunk/src/java/phenote/datamodel/Character.java phenote/trunk/src/java/phenote/datamodel/CharacterI.java phenote/trunk/src/java/phenote/datamodel/Ontology.java phenote/trunk/src/java/phenote/datamodel/OntologyManager.java phenote/trunk/src/java/phenote/edit/CompoundTransaction.java phenote/trunk/src/java/phenote/edit/EditManager.java phenote/trunk/src/java/phenote/edit/UpdateTransaction.java phenote/trunk/src/java/phenote/gui/CharacterTableModel.java phenote/trunk/src/java/phenote/gui/field/CharFieldGui.java phenote/trunk/src/java/phenote/gui/field/FreeTextField.java phenote/trunk/src/java/phenote/gui/field/PostCompGui.java phenote/trunk/src/java/phenote/gui/field/TermCompList.java phenote/trunk/src/java/phenote/main/Phenote.java phenote/trunk/src/java/phenote/main/PhenoteVersion.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-11-22 19:58:50 UTC (rev 218) +++ phenote/trunk/build.xml 2006-11-22 20:26:15 UTC (rev 219) @@ -375,9 +375,9 @@ <!-- todo do all jars not just phenote - take out -signed --> <!-- depends on sym link phenote-webstart and env var PHENOTE_VERSION --> - <target name="phenote-webstart-website" depends="sign-jars"> + <target name="webstart-website" depends="sign-jars"> <copy todir="phenote-webstart"> - <fileset file="doc/phenote-website/*.html"> + <fileset file="doc/phenote-website/*.html"/> </copy> <mkdir dir="phenote-webstart/${env.PHENOTE_VERSION}"/> <copy todir="phenote-webstart/${env.PHENOTE_VERSION}"> Modified: phenote/trunk/conf/initial-flybase.cfg =================================================================== --- phenote/trunk/conf/initial-flybase.cfg 2006-11-22 19:58:50 UTC (rev 218) +++ phenote/trunk/conf/initial-flybase.cfg 2006-11-22 20:26:15 UTC (rev 219) @@ -20,6 +20,12 @@ </field> <field name="Quality" file="quality.obo"/> - + <field name="Absent" file="quality.obo" slim="absent_slim" /> + <field name="Abnormal" file="quality.obo" slim="abnormal_slim" /> + + <field name="Evidence" file="evidence_code.obo"/> + + <field name="Description" /> + </phenote-configuration> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-11-22 19:58:50 UTC (rev 218) +++ phenote/trunk/conf/initial-zfin.cfg 2006-11-22 20:26:15 UTC (rev 219) @@ -18,8 +18,15 @@ <ontology name="SP" file="spatial.obo"/> </field> + <field name="Stage" file="zebrafish_anatomy.obo" filter-out="ZFA:" /> + <field name="Quality" file="quality.obo"/> - + <field name="Absent" file="quality.obo" slim="absent_slim" /> + <field name="Abnormal" file="quality.obo" slim="abnormal_slim" /> + <field name="Evidence" file="evidence_code.obo"/> + + <field name="Description" /> + </phenote-configuration> Modified: phenote/trunk/conf/phenote-config.rnc =================================================================== --- phenote/trunk/conf/phenote-config.rnc 2006-11-22 19:58:50 UTC (rev 218) +++ phenote/trunk/conf/phenote-config.rnc 2006-11-22 20:26:15 UTC (rev 219) @@ -4,8 +4,6 @@ start = element phenote-configuration { attribute version { xsd:float }, - check-for-new-ontologies, - ontology-archive, log, dataadapter*, field* @@ -32,12 +30,15 @@ field = element field { - attribute name { "Pub" | "Genotype" | "Genetic Context" | "Entity" | "Quality" }, + ##attribute name { "Pub" | "Genotype" | "Genetic Context" | "Entity" | "Quality" }, + attribute name { text }, ## whether field is free text or constrained by ontology - take out? ## this is actually unnecasary - if there is no file free text is assumed attribute type { "free_text" | "ontology" }, ## file is for single ontology - rename ontology_file? attribute file { text }, + attribute filter-out { text }, + attribute slim { text }, postcomp?, ontology* } @@ -47,7 +48,8 @@ attribute name { text }, ## obo file for ontology attribute file { text }, - attribute filter-out { text } + attribute filter-out { text }, + attribute slim { text } } postcomp = Modified: phenote/trunk/conf/phenote-config.xsd =================================================================== --- phenote/trunk/conf/phenote-config.xsd 2006-11-22 19:58:50 UTC (rev 218) +++ phenote/trunk/conf/phenote-config.xsd 2006-11-22 20:26:15 UTC (rev 219) @@ -3,7 +3,6 @@ <xs:element name="phenote-configuration"> <xs:complexType> <xs:sequence> - <xs:element ref="x:check-for-new-ontologies"/> <xs:element ref="x:log"/> <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:dataadapter"/> <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:field"/> @@ -26,11 +25,6 @@ </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="check-for-new-ontologies"> - <xs:complexType> - <xs:attribute name="intervalMinutes" use="required" type="xs:integer"/> - </xs:complexType> - </xs:element> <xs:element name="log"> <xs:complexType> <xs:attribute name="config-file" use="required"/> @@ -43,15 +37,9 @@ <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:ontology"/> </xs:sequence> <xs:attribute name="name" use="required"> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:enumeration value="Pub"/> - <xs:enumeration value="Genotype"/> - <xs:enumeration value="Genetic Context"/> - <xs:enumeration value="Entity"/> - <xs:enumeration value="Quality"/> - </xs:restriction> - </xs:simpleType> + <xs:annotation> + <xs:documentation>attribute name { "Pub" | "Genotype" | "Genetic Context" | "Entity" | "Quality" },</xs:documentation> + </xs:annotation> </xs:attribute> <xs:attribute name="type" use="required"> <xs:simpleType> @@ -66,6 +54,8 @@ <xs:documentation>file is for single ontology - rename ontology_file? </xs:documentation> </xs:annotation> </xs:attribute> + <xs:attribute name="filter-out" use="required"/> + <xs:attribute name="slim" use="required"/> </xs:complexType> </xs:element> <xs:element name="ontology"> @@ -77,6 +67,7 @@ </xs:annotation> </xs:attribute> <xs:attribute name="filter-out" use="required"/> + <xs:attribute name="slim" use="required"/> </xs:complexType> </xs:element> <xs:element name="postcomp"> Modified: phenote/trunk/jars/BrowserLauncher2-10rc4.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/commons-lang-2.1.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/commons-logging-1.0.4.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/jsr173_1.0_api.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/jstl-1.1.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/junit-4.0.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/log4j-1.2.13.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/oboedit.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/org.geneontology.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/phenoteconfigbeans.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/phenoxmlbeans.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/quartz-1.5.2.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/spring.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/standard-1.1.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/te-common.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/tomcat-servlet.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/xbean.jar =================================================================== (Binary files differ) Modified: phenote/trunk/obo-files/quality.obo =================================================================== --- phenote/trunk/obo-files/quality.obo 2006-11-22 19:58:50 UTC (rev 218) +++ phenote/trunk/obo-files/quality.obo 2006-11-22 20:26:15 UTC (rev 219) @@ -1,3519 +1,2991 @@ format-version: 1.0 -date: 11:08:2006 17:21 -saved-by: gg295 -auto-generated-by: OBO-Edit 1.000-beta16 -default-namespace: unknown +date: 13:11:2006 14:30 +saved-by: George Gkoutos +auto-generated-by: OBO-Edit 1.002 +subsetdef: absent_slim "Absent/Present slim" +subsetdef: abnormal_slim "Abnormal/Normal slim" +default-namespace: quality [Term] id: PATO:0000000 name: pato -namespace: attribute is_obsolete: true [Term] id: PATO:0000001 name: quality -namespace: attribute +def: "A dependent entity that\ninheres in a bearer by virtue of how the bearer is related to other entities." [PATO GVG:] [Term] id: PATO:0000002 name: value -namespace: attribute is_obsolete: true [Term] id: PATO:0000003 name: assay -namespace: attribute is_obsolete: true [Term] id: PATO:0000004 name: mobility -namespace: attribute -def: "The quality of moving freely." [XX:<new dbxref>] +def: "A quality of moving freely." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000005 name: absolute activity -namespace: attribute is_obsolete: true [Term] id: PATO:0000006 name: process -namespace: attribute is_obsolete: true [Term] id: PATO:0000007 name: relative activity -namespace: attribute is_obsolete: true [Term] id: PATO:0000008 -name: speed -namespace: attribute -def: "Rate of change of the position of an object." [XX:<new dbxref>] +name: speed/velocity +def: "A physical quality inhering in an object by virtue of the rate of change of its position." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000009 name: absolute speed -namespace: attribute is_obsolete: true [Term] id: PATO:0000010 name: relative speed -namespace: attribute is_obsolete: true [Term] id: PATO:0000011 name: age -namespace: attribute -is_a: PATO:0000050 ! life span +is_a: PATO:0000165 ! time [Term] id: PATO:0000012 name: absolute age -namespace: attribute is_obsolete: true [Term] id: PATO:0000013 name: relative age -namespace: attribute is_obsolete: true [Term] id: PATO:0000014 name: color -namespace: attribute -def: "Color is a property of light that is determined by its wavelength (or by its composition as a blend of several wavelengths). " [Wikipedia:] -is_a: PATO:0001237 ! monadic quality of continuant +def: "A composite chromatic quality composed of hue, saturation and intensity parts." [XX:<new dbxref>] +is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000015 name: color hue -namespace: attribute -is_obsolete: true +def: "a chromatic scalar-circular quality inhering in an object that manifests in an observer by virtue of the dominant wavelength of the visible light; may be subject to fiat divisions, typically into 7 or 8 spectra" [XX:<new dbxref>] +is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000016 -name: color intensity -namespace: attribute -is_obsolete: true +name: color brightness +def: "A scalar optical quality which obtains by the bearer producing the effects of light emittance in an observer." [XX:<new dbxref>] +is_a: PATO:0001300 ! optical quality [Term] id: PATO:0000017 name: color saturation -namespace: attribute -is_obsolete: true +def: "a scalar chromatic quality that manifests by virtue of the range of wavelengths in perceived light." [XX:<new dbxref>] +is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000018 -name: flourescence -namespace: attribute -def: "Fluorescence is a luminescence that is mostly found as an optical phenomenon in cold bodies, in which the molecular absorption of a photon triggers the emission of a lower-energy photon with a longer wavelength." [Wikipedia:] -is_obsolete: true +name: fluorescence +def: "Luminosity in which the bearer emits longer wavelength light following the absorption of shorter wavelength radiation; fluorescence is common with aromatic compounds with several rings joined together." [XX:<new dbxref>] +is_a: PATO:0001296 ! luminosity [Term] id: PATO:0000019 name: color pattern -namespace: attribute is_obsolete: true [Term] id: PATO:0000020 name: relative color -namespace: attribute -is_a: PATO:0000014 ! color +is_a: PATO:0001300 ! optical quality [Term] id: PATO:0000021 name: compatibility -namespace: attribute -def: "The quality of having or lacking the ability harmonious coexistence." [gg:] +def: "A quality of having or lacking the ability harmonious coexistence." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000022 name: gametophytic compatability -namespace: attribute is_obsolete: true [Term] id: PATO:0000023 name: relative compatability -namespace: attribute is_obsolete: true [Term] id: PATO:0000024 name: sporophytic compatability -namespace: attribute is_obsolete: true [Term] id: PATO:0000025 name: composition -namespace: attribute +def: "A monadic quality of continuant inhering in an object by virtue of the quantities or relative ratios of subparts of the inhering entity; for example calcium composition (which may inhere in bone), haemoglobin composition (which may inhere in blood)" [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000026 name: carbohydrate composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000027 name: electrolyte composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000028 name: macromolecular composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000029 name: protein composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000030 name: enzyme composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000031 name: metabolite composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000032 name: secondary product composition -namespace: attribute is_obsolete: true [Term] id: PATO:0000033 name: concentration -namespace: attribute -def: "The proportion of the whole a subtance makes up in a mixture of two substances." [XX:<new dbxref>] +def: "A physical quality inhering in a substance by \nvirtue of the amount of it there is mixed with another substance." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000034 name: protein concentration -namespace: attribute is_obsolete: true [Term] id: PATO:0000035 name: carbohydrate concentration -namespace: attribute is_obsolete: true [Term] id: PATO:0000036 name: water content -namespace: attribute is_obsolete: true [Term] id: PATO:0000037 name: consistency -namespace: attribute -def: "the property of holding together and retaining shape" [PATO:gg] -is_obsolete: true +def: "A physical quality that inheres in a continuant by\nvirtue of density, firmness, or viscosity." [PATO GVG:] +is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000038 name: gel consistency -namespace: attribute is_obsolete: true [Term] id: PATO:0000039 name: direction -namespace: attribute -def: "The orientation of a line in space." [XX:<new dbxref>] +def: "The orientation of a line in space." [: "http://thesaurus.maths.org/"] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000040 name: distance -namespace: attribute def: "The extent of space between two objects or places." [XX:<new dbxref>] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000041 name: absolutedistance -namespace: attribute is_obsolete: true [Term] id: PATO:0000042 name: relative distance -namespace: attribute is_obsolete: true [Term] id: PATO:0000043 name: flavor -namespace: attribute -is_a: PATO:0001237 ! monadic quality of continuant +def: "A relational quality inhering in an object or the molecules of an object, in which the molecules are perceived by a taste and odorant receptors." [XX:<new dbxref>] +is_a: PATO:0001238 ! relational quality of continuant [Term] id: PATO:0000044 name: frequency -namespace: attribute -def: "The number of times something happens in a period of time." [XX:<new dbxref>] +def: "A physical quality which inhers to the bearer by virtue of the number of repetitive actions in a particular time." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000045 name: absolute frequency -namespace: attribute is_obsolete: true [Term] id: PATO:0000046 name: relative frequency -namespace: attribute is_obsolete: true [Term] id: PATO:0000047 -name: gender -namespace: attribute +name: biological sex +def: "A monadic quality of continuant inhering in an organism by virtue of its ability to undergo sexual reproduction in order to differentiate the individuals or types involved." [MGED:MGED] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000048 name: hardness -namespace: attribute -def: "The constant of proportionality of the force on an elastic body to the body's extension." [XX:<new dbxref>] +def: "A physical quality inhering in a bearer as the constant of proportionality of the force on its elastic body to its body's extension." [: "http://thesaurus.maths.org/"] related_synonym: "stiffness" [] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000049 name: intensity -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000050 name: life span -namespace: attribute +def: "A time quality which is the expected maximum age." [XX:<new dbxref>] is_a: PATO:0000165 ! time [Term] id: PATO:0000051 name: morphology -namespace: attribute +def: "A quality inhering in the bearer by virtue of its size, shape and structure" [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000052 name: shape -namespace: attribute +def: "A morphology quality inhering in a bearer by virtue of the ratios of distances between its features (points, edges, surfaces and also holes etc). " [PATO GVG:] is_a: PATO:0000051 ! morphology [Term] id: PATO:0000053 name: count -namespace: attribute is_a: PATO:0001226 ! quantitative [Term] id: PATO:0000054 name: absolute number -namespace: attribute is_obsolete: true [Term] id: PATO:0000055 name: relative number -namespace: attribute is_obsolete: true [Term] id: PATO:0000056 name: nutritional -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000057 -name: occurence -namespace: attribute +name: occurrence is_a: PATO:0001226 ! quantitative [Term] id: PATO:0000058 name: odor -namespace: attribute -is_a: PATO:0001237 ! monadic quality of continuant +def: "A relational quality inhering in an object by virtue of the molecules being are aerially dispersed and perceived by an odorant receptor. " [XX:<new dbxref>] +is_a: PATO:0001238 ! relational quality of continuant [Term] id: PATO:0000059 name: parental type -namespace: attribute -is_a: PATO:0000047 ! gender +is_a: PATO:0000047 ! biological sex [Term] id: PATO:0000060 name: pattern -namespace: attribute +def: "A monadic quality of continuant defined by the mathematic properties of the relative position of subparts" [XX:<new dbxref>] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000061 name: relative pattern -namespace: attribute is_obsolete: true [Term] id: PATO:0000062 name: sleep pattern -namespace: attribute is_a: PATO:0000186 ! behavioral quality [Term] id: PATO:0000063 name: percentage -namespace: attribute is_obsolete: true [Term] id: PATO:0000064 name: absolute percentage -namespace: attribute is_obsolete: true [Term] id: PATO:0000065 name: relative percentage -namespace: attribute is_obsolete: true [Term] id: PATO:0000066 name: pilosity -namespace: attribute -def: "The quality of having hair." [XX:<new dbxref>] +def: "A quality of having hair." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000067 name: relative pilosity -namespace: attribute is_obsolete: true [Term] id: PATO:0000068 name: qualitative -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000069 name: deviation(from_normal) -namespace: attribute is_a: PATO:0000068 ! qualitative [Term] id: PATO:0000070 name: presence -namespace: attribute is_a: PATO:0000068 ! qualitative [Term] id: PATO:0000071 name: relative_quantity -namespace: attribute is_a: PATO:0001226 ! quantitative [Term] id: PATO:0000072 name: quality -namespace: attribute is_obsolete: true [Term] id: PATO:0000073 name: relative_quality -namespace: attribute is_obsolete: true [Term] id: PATO:0000074 name: shattering -namespace: attribute is_obsolete: true [Term] id: PATO:0000075 name: threshability -namespace: attribute is_obsolete: true [Term] id: PATO:0000076 name: regulation -namespace: attribute is_obsolete: true [Term] id: PATO:0000077 name: response -namespace: attribute +def: "A quality inhering in a bearer by virtue of \nits reaction to a stimulus or an agent." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000078 -name: rhythym -namespace: attribute +name: rhythm is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000079 name: absolute rhythym -namespace: attribute is_obsolete: true [Term] id: PATO:0000080 name: amplitude -namespace: attribute -def: "The size of the maximum displacement from the 'normal' position, when periodic motion is taking place" [PATO:gg] -is_a: PATO:0000078 ! rhythym +def: "A physical quality inhering in a bearer by \nvirtue of the size of its maximum displacement from the 'normal' position, when periodic motion is taking place" [: "http://thesaurus.maths.org/"] +is_a: PATO:0000078 ! rhythm is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000081 name: period -namespace: attribute -is_a: PATO:0000078 ! rhythym +is_a: PATO:0000078 ! rhythm is_a: PATO:0000165 ! time [Term] id: PATO:0000082 name: persistence -namespace: attribute -is_a: PATO:0000078 ! rhythym +is_a: PATO:0000078 ! rhythm [Term] id: PATO:0000083 name: phase -namespace: attribute -is_a: PATO:0000078 ! rhythym +is_a: PATO:0000078 ! rhythm [Term] id: PATO:0000084 name: relative rhythym -namespace: attribute is_obsolete: true [Term] id: PATO:0000085 name: sensitivity -namespace: attribute -is_a: PATO:0001237 ! monadic quality of continuant +def: "A relational quality inhering in an entity by virtue of its capacity to respond to stimulation." [XX:<new dbxref>] +is_a: PATO:0001238 ! relational quality of continuant [Term] id: PATO:0000086 name: absolute sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000087 name: disease sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000088 name: absolute disease sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000089 name: relative disease sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000090 name: relative sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000091 name: stress sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000092 name: abiotic stress sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000093 name: chemical sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000094 name: drug sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000095 name: absolute drug sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000096 name: relative drug sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000097 name: herbicide sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000098 name: insecticide sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000099 name: plant growth hormone sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000100 name: soil composition sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000101 name: soil nutrient sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000102 name: macronutrient sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000103 name: micronutrient sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000104 name: osmotic response sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000105 name: p h sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000106 name: acid sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000107 name: alkali sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000108 name: salt sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000109 name: water sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000110 name: drought sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000111 name: flooding sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000112 name: humidity sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000113 name: radiation sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000114 name: temperature sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000115 name: absolute temperature sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000116 name: relative temperature sensitivity -namespace: attribute is_obsolete: true [Term] id: PATO:0000117 name: size -namespace: attribute is_a: PATO:0000051 ! morphology [Term] id: PATO:0000118 name: absolute size -namespace: attribute is_obsolete: true [Term] id: PATO:0000119 name: height -namespace: attribute -def: "The vertical dimension of extension." [XX:<new dbxref>] +def: "A physical quality which is equal to the vertical dimension of extension." [PATO GVG:] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000120 name: absolute height -namespace: attribute is_obsolete: true [Term] id: PATO:0000121 name: relative height -namespace: attribute is_obsolete: true [Term] id: PATO:0000122 name: length -namespace: attribute -def: "The distance between two points." [XX:<new dbxref>] +def: "A physical quality which is equal to the distance between two points." [PATO GVG:] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000123 name: absolute length -namespace: attribute is_obsolete: true [Term] id: PATO:0000124 name: relative length -namespace: attribute is_obsolete: true [Term] id: PATO:0000125 name: mass -namespace: attribute -def: "The amount of matter in an object." [XX:<new dbxref>] +def: "A physical quality that inheres in a bearer in proportion to the amount of matter it contains." [PATO GVG:] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000126 name: absolute mass -namespace: attribute is_obsolete: true [Term] id: PATO:0000127 name: relative mass -namespace: attribute is_obsolete: true [Term] id: PATO:0000128 name: weight -namespace: attribute -def: "The size of the force which gravity exerts on a particular object. " [XX:<new dbxref>] +def: "A quality inhering in an object with mass near a gravitational body." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] is_a: PATO:0001035 ! force [Term] id: PATO:0000129 name: absolute weight -namespace: attribute is_obsolete: true [Term] id: PATO:0000130 name: relative weight -namespace: attribute is_obsolete: true [Term] id: PATO:0000131 name: relative size -namespace: attribute is_obsolete: true [Term] id: PATO:0000132 name: spatial -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000133 name: angle -namespace: attribute -def: "The measure of a change in direction." [XX:<new dbxref>] +def: "A physical quality inhering in a figure or space formed by the junction of two lines or planes." [Wikipedia :Wikipedia "http://www.wikipedia.org/"] is_a: PATO:0000132 ! spatial is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000134 name: absolute_angle -namespace: attribute is_obsolete: true [Term] id: PATO:0000135 name: relative_angle -namespace: attribute is_obsolete: true [Term] id: PATO:0000136 name: closure -namespace: attribute is_a: PATO:0000132 ! spatial [Term] id: PATO:0000137 name: orientation -namespace: attribute +def: "A quality of an object in which its \nlocation is defined by the angle between two axes, or an axis and another object" [XX:<new dbxref>] is_a: PATO:0000132 ! spatial [Term] id: PATO:0000138 name: absolute orientation -namespace: attribute is_obsolete: true [Term] id: PATO:0000139 name: relative orientation -namespace: attribute is_obsolete: true [Term] id: PATO:0000140 name: placement -namespace: attribute -def: "The spatial property of the way in which something is placed" [PATO:gg] +def: "A spatial quality of the way in which something is placed" [PATO:gg] is_a: PATO:0000132 ! spatial [Term] id: PATO:0000141 name: structure -namespace: attribute +def: "A morphology quality inhering in a bearer by virtue of the relative position, shape, arrangements and connectivity of an organism's various parts; the pattern underlying its form.\n" [PATO GVG:] is_a: PATO:0000051 ! morphology [Term] id: PATO:0000142 name: substance -namespace: attribute is_obsolete: true [Term] id: PATO:0000143 name: addictive substance -namespace: attribute is_obsolete: true [Term] id: PATO:0000144 name: solid substance -namespace: attribute is_obsolete: true [Term] id: PATO:0000145 name: liquid substance -namespace: attribute is_obsolete: true [Term] id: PATO:0000146 name: temperature -namespace: attribute -def: "The physical quality of the thermal energy of a system." [gg:] +def: "A physical quality of the thermal energy of a system." [PATO GVG:] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000147 name: absolute temperature -namespace: attribute is_obsolete: true [Term] id: PATO:0000148 name: body temperature -namespace: attribute is_obsolete: true [Term] id: PATO:0000149 name: relative temperature -namespace: attribute is_obsolete: true [Term] id: PATO:0000150 name: texture -namespace: attribute +def: "A morphology quality inhering in a bearer by virtue of the relative size and distribution of its surface elements or the representation or invention of the appearance of its surface. \n" [PATO GVG:] is_a: PATO:0000051 ! morphology [Term] id: PATO:0000151 name: relative texture -namespace: attribute is_obsolete: true [Term] id: PATO:0000152 name: threshold -namespace: attribute +def: "A quality inhering in a bearer by virtue of its sensitivity towards a fixed location or value where a change is observed; upper limit." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000153 name: absolute threshold -namespace: attribute is_obsolete: true [Term] id: PATO:0000154 name: pain threshold -namespace: attribute is_obsolete: true [Term] id: PATO:0000155 name: relative threshold -namespace: attribute is_obsolete: true [Term] id: PATO:0000156 name: temporal -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000157 name: absolute temporal -namespace: attribute is_obsolete: true [Term] id: PATO:0000158 name: incidence -namespace: attribute is_a: PATO:0000156 ! temporal [Term] id: PATO:0000159 name: absolute incidence -namespace: attribute is_obsolete: true [Term] id: PATO:0000160 name: relative incidence -namespace: attribute is_obsolete: true [Term] id: PATO:0000161 name: rate -namespace: attribute is_a: PATO:0000156 ! temporal [Term] id: PATO:0000162 name: absolute rate -namespace: attribute is_obsolete: true [Term] id: PATO:0000163 name: relative rate -namespace: attribute is_obsolete: true [Term] id: PATO:0000164 name: relative temporal -namespace: attribute is_obsolete: true [Term] id: PATO:0000165 name: time -namespace: attribute +def: "A quality in which events occur in sequence" [XX:<new dbxref>] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000166 name: absolute time -namespace: attribute is_obsolete: true [Term] id: PATO:0000167 name: bouts -namespace: attribute is_a: PATO:0000165 ! time [Term] id: PATO:0000168 name: relative time -namespace: attribute is_obsolete: true [Term] id: PATO:0000169 name: viability -namespace: attribute +def: "A quality inhering in a bearer or a population by virtue of the bearer's ability or inability to survive and develop normally or the number of surviving individuals in a given population." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000170 name: yield -namespace: attribute is_obsolete: true [Term] id: PATO:0000171 name: absolute yield -namespace: attribute is_obsolete: true [Term] id: PATO:0000172 name: relative yield -namespace: attribute is_obsolete: true [Term] id: PATO:0000173 name: function -namespace: attribute is_obsolete: true [Term] id: PATO:0000174 name: autonomic function -namespace: attribute is_obsolete: true [Term] id: PATO:0000175 name: behavioral function -namespace: attribute is_obsolete: true [Term] id: PATO:0000176 name: metabolic function -namespace: attribute is_obsolete: true [Term] id: PATO:0000177 name: physiological function -namespace: attribute is_obsolete: true [Term] id: PATO:0000178 name: relative function -namespace: attribute is_obsolete: true [Term] id: PATO:0000179 name: body position -namespace: attribute is_obsolete: true [Term] id: PATO:0000180 name: body tone -namespace: attribute is_obsolete: true [Term] id: PATO:0000181 name: piloerection -namespace: attribute is_obsolete: true [Term] id: PATO:0000182 name: abdominal tone -namespace: attribute is_obsolete: true [Term] id: PATO:0000183 name: limb tone -namespace: attribute is_obsolete: true [Term] id: PATO:0000184 name: arousal -namespace: attribute is_obsolete: true [Term] id: PATO:0000185 name: balance -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000186 name: behavioral quality -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000187 name: consumption -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000188 name: coordination -namespace: attribute -def: "The quality of having or lacking skilful and effective interation of movemment." [gg:] +def: "A quality of having or lacking skilful and effective interaction of movement." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000189 name: discrimination -namespace: attribute -def: "The quality of perceiving differences between two or more stimuli." [XX:<new dbxref>] +def: "A quality of perceiving differences between two or more stimuli." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000190 name: gait -namespace: attribute is_obsolete: true [Term] id: PATO:0000191 name: learning_and memory -namespace: attribute is_obsolete: true [Term] id: PATO:0000192 name: locomotor_activity -namespace: attribute is_obsolete: true [Term] id: PATO:0000193 name: mating -namespace: attribute is_obsolete: true [Term] id: PATO:0000194 name: spontaneous_activity -namespace: attribute is_obsolete: true [Term] id: PATO:0000195 name: startle response -namespace: attribute is_obsolete: true [Term] id: PATO:0000196 name: vocalization -namespace: attribute is_obsolete: true [Term] id: PATO:0000197 name: transfer_arousal -namespace: attribute is_obsolete: true [Term] id: PATO:0000198 name: absolute consumption -namespace: attribute is_obsolete: true [Term] id: PATO:0000199 name: relative consumption -namespace: attribute is_obsolete: true [Term] id: PATO:0000200 name: learning -namespace: attribute is_obsolete: true [Term] id: PATO:0000201 name: memory -namespace: attribute is_obsolete: true [Term] id: PATO:0000202 name: long term memory -namespace: attribute is_obsolete: true [Term] id: PATO:0000203 name: short term memory -namespace: attribute is_obsolete: true [Term] id: PATO:0000204 name: absolute locomotor_activity -namespace: attribute is_obsolete: true [Term] id: PATO:0000205 name: relative locomotor_activity -namespace: attribute is_obsolete: true [Term] id: PATO:0000206 name: enzyme function -namespace: attribute is_obsolete: true [Term] id: PATO:0000207 name: circulatory function -namespace: attribute is_obsolete: true [Term] id: PATO:0000208 name: defensive function -namespace: attribute is_obsolete: true [Term] id: PATO:0000209 name: digestive function -namespace: attribute is_obsolete: true [Term] id: PATO:0000210 name: excretory function -namespace: attribute is_obsolete: true [Term] id: PATO:0000211 name: muscle function -namespace: attribute is_obsolete: true [Term] id: PATO:0000212 name: neural function -namespace: attribute is_obsolete: true [Term] id: PATO:0000213 name: neurobehavioral function -namespace: attribute is_obsolete: true [Term] id: PATO:0000214 name: reproductive function -namespace: attribute is_obsolete: true [Term] id: PATO:0000215 name: respiratory function -namespace: attribute is_obsolete: true [Term] id: PATO:0000216 name: heart rate -namespace: attribute is_obsolete: true [Term] id: PATO:0000217 name: immune function -namespace: attribute is_obsolete: true [Term] id: PATO:0000218 name: repair function -namespace: attribute is_obsolete: true [Term] id: PATO:0000219 name: healing -namespace: attribute is_obsolete: true [Term] id: PATO:0000220 name: regeneration -namespace: attribute is_obsolete: true [Term] id: PATO:0000221 name: urination -namespace: attribute is_obsolete: true [Term] id: PATO:0000222 name: muscle elevation -namespace: attribute is_obsolete: true [Term] id: PATO:0000223 name: muscle strength -namespace: attribute is_obsolete: true [Term] id: PATO:0000224 name: motor function -namespace: attribute is_obsolete: true [Term] id: PATO:0000225 name: sensory function -namespace: attribute is_obsolete: true [Term] id: PATO:0000226 name: tactile response -namespace: attribute is_obsolete: true [Term] id: PATO:0000227 name: motor performance -namespace: attribute is_obsolete: true [Term] id: PATO:0000228 name: auditory -namespace: attribute is_obsolete: true [Term] id: PATO:0000229 name: olfactory -namespace: attribute is_obsolete: true [Term] id: PATO:0000230 name: proprioreception -namespace: attribute is_obsolete: true [Term] id: PATO:0000231 name: reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000232 name: taste -namespace: attribute is_obsolete: true [Term] id: PATO:0000233 name: touch -namespace: attribute is_obsolete: true [Term] id: PATO:0000234 name: visual -namespace: attribute is_obsolete: true [Term] id: PATO:0000235 name: odor_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000236 name: odor type -namespace: attribute is_obsolete: true [Term] id: PATO:0000237 name: absolute odor_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000238 name: relative odor_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000239 name: blinking reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000240 name: contact righting reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000241 name: corneal reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000242 name: flinch reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000243 name: lordosis reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000244 name: ocular reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000245 name: pinna reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000246 name: postural reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000247 name: proboscis extension reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000248 name: pupillary reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000249 name: righting reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000250 name: spinal reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000251 name: startle reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000252 name: suckling reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000253 name: swallowing reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000254 name: vibrissae reflex -namespace: attribute is_obsolete: true [Term] id: PATO:0000255 name: taste_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000256 name: taste type -namespace: attribute is_obsolete: true [Term] id: PATO:0000257 name: absolute taste_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000258 name: relative taste_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000259 name: visual_ability -namespace: attribute is_obsolete: true [Term] id: PATO:0000260 name: visual_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000261 name: maturity -namespace: attribute is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000262 name: visual placing -namespace: attribute is_obsolete: true [Term] id: PATO:0000263 name: visual threshold -namespace: attribute is_obsolete: true [Term] id: PATO:0000264 name: absolute visual_ability -namespace: attribute is_obsolete: true [Term] id: PATO:0000265 name: relative visual_ability -namespace: attribute is_obsolete: true [Term] id: PATO:0000266 name: absolute visual_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000267 name: relative visual_acuity -namespace: attribute is_obsolete: true [Term] id: PATO:0000268 name: absolute visual threshold -namespace: attribute is_obsolete: true [Term] id: PATO:0000269 name: relative visual threshold -namespace: attribute is_obsolete: true [Term] id: PATO:0000270 name: defecation -namespace: attribute is_obsolete: true [Term] id: PATO:0000271 name: prepulse inhibition -namespace: attribute is_obsolete: true [Term] id: PATO:0000272 name: relative neurobehavioral function -namespace: attribute is_obsolete: true [Term] id: PATO:0000273 name: fecundity -namespace: attribute is_obsolete: true [Term] id: PATO:0000274 name: fertility -namespace: attribute -def: "The quality of initiating, sustaining, or supporting reproduction." [XX:<new dbxref>] +def: "A quality of initiating, sustaining, or supporting reproduction." [PATO GVG:] is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000275 name: gestational period -namespace: attribute is_obsolete: true [Term] id: PATO:0000276 name: litter size -namespace: attribute is_obsolete: true [Term] id: PATO:0000277 name: female fertility -namespace: attribute -def: "The quality of female of initiating, sustaining, or supporting reproduction." [XX:<new dbxref>] +def: "A fertility quality of the female of initiating, sustaining, or supporting reproduction." [PATO GVG:] is_a: PATO:0000274 ! fertility [Term] id: PATO:0000278 name: hybrid fertility -namespace: attribute is_obsolete: true [Term] id: PATO:0000279 name: male fertility -namespace: attribute -def: "The quality of male of initiating, sustaining, or supporting reproduction." [XX:<new dbxref>] +def: "A fertility quality of the male of initiating, sustaining, or supporting reproduction." [PATO GVG:] is_a: PATO:0000274 ! fertility [Term] id: PATO:0000280 name: backcross fertility -namespace: attribute is_obsolete: true [Term] id: PATO:0000281 name: cytoplasmic sterility -namespace: attribute is_obsolete: true [Term] id: PATO:0000282 name: f1 fertility -namespace: attribute is_obsolete: true [Term] id: PATO:0000283 name: f2 fertility -namespace: attribute is_obsolete: true [Term] id: PATO:0000284 name: germ line dependent fertility -namespace: attribute is_obsolete: true [Term] id: PATO:0000285 name: soma dependent fertility -namespace: attribute is_obsolete: true [Term] id: PATO:0000286 name: cytoplasmic male sterility -namespace: attribute is_obsolete: true [Term] id: PATO:0000287 name: absolute litter size -namespace: attribute is_obsolete: true [Term] id: PATO:0000288 name: relative litter size -namespace: attribute is_obsolete: true [Term] id: PATO:0000289 name: respiratory rate -namespace: attribute is_obsolete: true [Term] id: PATO:0000290 name: absolute respiratory rate -namespace: attribute is_obsolete: true [Term] id: PATO:0000291 name: relative respiratory rate -namespace: attribute is_obsolete: true [Term] id: PATO:0000292 name: mobility value -namespace: attribute is_obsolete: true [Term] id: PATO:0000293 name: absolute activity value -namespace: attribute is_obsolete: true [Term] id: PATO:0000294 name: process value -namespace: attribute is_obsolete: true [Term] id: PATO:0000295 name: relative activity value -namespace: attribute is_obsolete: true [Term] id: PATO:0000296 name: speed value -namespace: attribute is_obsolete: true [Term] id: PATO:0000297 -name: arrested value -namespace: attribute -is_obsolete: true +name: arrested +def: "A duration in which the end point is shorted before natural end point (prematurely finishing)." [XX:<new dbxref>] +related_synonym: "incomplete" [] +is_a: PATO:0001309 ! duration [Term] id: PATO:0000298 name: not arrested value -namespace: attribute is_obsolete: true [Term] id: PATO:0000299 name: mobile -namespace: attribute -def: "The quality of being incapable to move freely." [XX:<new dbxref>] +def: "A mobility quality of being incapable to move freely." [PATO GVG:] is_a: PATO:0000004 ! mobility [Term] id: PATO:0000300 name: immobile -namespace: attribute -def: "The quality of being capable to move freely." [XX:<new dbxref>] +def: "A mobility quality of being capable to move freely." [PATO GVG:] is_a: PATO:0000004 ! mobility [Term] id: PATO:0000301 name: absolute speed value -namespace: attribute is_obsolete: true [Term] id: PATO:0000302 name: relative speed value -namespace: attribute is_obsolete: true [Term] id: PATO:0000303 name: fast speed -namespace: attribute -def: "A speed which is relative high." [XX:<new dbxref>] -is_a: PATO:0000008 ! speed +def: "A speed which is relative high." [PATO GVG:] +is_a: PATO:0000008 ! speed/velocity [Term] id: PATO:0000304 name: slow speed -namespace: attribute def: "A speed which is relative low." [XX:<new dbxref>] -is_a: PATO:0000008 ! speed +is_a: PATO:0000008 ! speed/velocity [Term] id: PATO:0000305 name: age value -namespace: attribute is_obsolete: true [Term] id: PATO:0000306 name: absolute age value -namespace: attribute is_obsolete: true [Term] id: PATO:0000307 name: relative age value -namespace: attribute is_obsolete: true [Term] id: PATO:0000308 name: old -namespace: attribute is_a: PATO:0000011 ! age [Term] id: PATO:0000309 name: young -namespace: attribute is_a: PATO:0000011 ! age [Term] id: PATO:0000310 name: color value -namespace: attribute is_obsolete: true [Term] id: PATO:0000311 name: color hue value -namespace: attribute is_obsolete: true [Term] id: PATO:0000312 name: color intensity value -namespace: attribute is_obsolete: true [Term] id: PATO:0000313 name: color saturation value -namespace: attribute is_obsolete: true [Term] id: PATO:0000314 name: flourescence value -namespace: attribute is_obsolete: true [Term] id: PATO:0000315 name: color pattern value -namespace: attribute is_obsolete: true [Term] id: PATO:0000316 name: relative color value -namespace: attribute is_obsolete: true [Term] id: PATO:0000317 name: black -namespace: attribute -def: "Producing or reflecting comparatively little light and having no predominant hue." [Dictionary:http://dictionary.reference.com/] +def: "A color that lacks any hues as parts." [XX:<new dbxref>] is_a: PATO:0000014 ! color [Term] id: PATO:0000318 name: blue -namespace: attribute -def: "A hue of that portion of the visible spectrum lying between green and indigo, evoked in the human observer by radiant energy with wavelengths of approximately 420 to 490 nanometers;" [Dictionary:http://dictionary.reference.com/] +def: "A hue of that portion of the visible spectrum lying between green and indigo, evoked in the human observer by radiant energy with wavelengths of approximately 420 to 490 nanometers;" [Dictionary:http\://dictionary.reference.com/] is_a: PATO:0000014 ! color [Term] id: PATO:0000319 name: cyan -namespace: attribute is_a: PATO:0000014 ! color [Term] id: PATO:0000320 name: green -namespace: attribute -def: "A hue of that portion of the visible spectrum lying between yellow and blue, evoked in the human observer by radiant energy with wavelengths of approximately 490 to 570 nanometers;" [Dictionary:http://dictionary.reference.com/] +def: "A hue of that portion of the visible spectrum lying between yellow and blue, evoked in the human observer by radiant energy with wavelengths of approximately 490 to 570 nanometers;" [Dictionary:http\://dictionary.reference.com/] is_a: PATO:0000014 ! color [Term] id: PATO:0000321 name: magenta -namespace: attribute is_a: PATO:0000322 ! red [Term] id: PATO:0000322 name: red -namespace: attribute -def: "A hue of the long-wave end of the visible spectrum, evoked in the human observer by radiant energy with wavelengths of approximately 630 to 750 nanometers;" [Dictionary:http://dictionary.reference.com/] +def: "A hue of the long-wave end of the visible spectrum, evoked in the human observer by radiant energy with wavelengths of approximately 630 to 750 nanometers;" [Dictionary:http\://dictionary.reference.com/] is_a: PATO:0000014 ! color [Term] id: PATO:0000323 name: white -namespace: attribute -def: "An achromatic color of maximum lightness; the color of objects that reflect nearly all light of all visible wavelengths;" [Dictionary:http://dictionary.reference.com/] +def: "An achromatic color of maximum lightness; the color of objects that reflect nearly all light of all visible wavelengths;" [Dictionary:http\://dictionary.reference.com/] is_a: PATO:0000014 ! color [Term] id: PATO:0000324 name: yellow -namespace: attribute -def: "A hue of that portion of the visible spectrum lying between orange and green, evoked in the human observer by radiant energy with wavelengths of approximately 570 to 590 nanometers" [Dictionary:http://dictionary.reference.com/] +def: "A hue of that portion of the visible spectrum lying between orange and green, evoked in the human observer by radiant energy with wavelengths of approximately 570 to 590 nanometers" [Dictionary:http\://dictionary.reference.com/] is_a: PATO:0000014 ! color [Term] id: PATO:0000325 name: bright -namespace: attribute is_obsolete: true [Term] id: PATO:0000326 name: dim -namespace: attribute is_obsolete: true [Term] id: PATO:0000327 name: dark -namespace: attribute -is_obsolete: true +is_a: PATO:0000016 ! color brightness [Term] id: PATO:0000328 name: pale -namespace: attribute -is_obsolete: true +related_synonym: "dull" [] +is_a: PATO:0000017 ! color saturation [Term] id: PATO:0000329 name: blotchy -namespace: attribute is_obsolete: true [Term] id: PATO:0000330 name: irregular -namespace: attribute +def: "A physical quality inhering in a bearer by \nvirtue of lacking pattern." [PATO GVG:] is_a: PATO:0000060 ! pattern [Term] id: PATO:0000331 name: discolored -namespace: attribute is_a: PATO:0000020 ! relative color [Term] id: PATO:0000332 name: pigmented -namespace: attribute is_obsolete: true [Term] id: PATO:0000333 name: spotted -namespace: attribute is_obsolete: true [Term] id: PATO:0000334 name: unpigmented -namespace: attribute is_obsolete: true [Term] id: PATO:0000335 name: variegated -namespace: attribute related_synonym: "mottled (sensu Drosophila)" [] is_obsolete: true [Term] id: PATO:0000336 name: colored -namespace: attribute is_a: PATO:0000020 ! relative color [Term] id: PATO:0000337 name: colorless -namespace: attribute is_a: PATO:0000020 ! relative color [Term] id: PATO:0000338 name: compatability value -namespace: attribute is_obsolete: true [Term] id: PATO:0000339 name: gametophytic compatability value -namespace: attribute is_obsolete: true [Term] id: PATO:0000340 name: relative compatability value -namespace: attribute is_obsolete: true [Term] id: PATO:0000341 name: sporophytic compatability value -namespace: attribute is_obsolete: true [Term] id: PATO:0000342 name: gametophyte compatible value -namespace: attribute is_obsolete: true [Term] id: PATO:0000343 name: gametophyte incompatible value -namespace: attribute is_obsolete: true [Term] id: PATO:0000344 name: compatible -namespace: attribute -def: "The quality of being capable of harmonious coexistence." [gg:] +def: "A compatibility quality of being capable of harmonious coexistence." [PATO GVG:] is_a: PATO:0000021 ! compatibility [Term] id: PATO:0000345 name: incompatible -namespace: attribute -def: "The quality of being incapable of harmonious coexistence." [gg:] +def: "A compatibility quality of being incapable of harmonious coexistence." [PATO GVG:] is_a: PATO:0000021 ! compatibility [Term] id: PATO:0000346 name: sporophyte compatible value -namespace: attribute is_obsolete: true [Term] id: PATO:0000347 name: sporophyte incompatible value -namespace: attribute is_obsolete: true [Term] id: PATO:0000348 name: composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000349 name: carbohydrate composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000350 name: electrolyte composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000351 name: macromolecular composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000352 name: metabolite composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000353 name: secondary product composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000354 name: protein composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000355 name: enzyme composition value -namespace: attribute is_obsolete: true [Term] id: PATO:0000356 name: concentration value -namespace: attribute is_obsolete: true [Term] id: PATO:0000357 name: protein concentration value -namespace: attribute is_obsolete: true [Term] id: PATO:0000358 name: sugar concentration value -namespace: attribute is_obsolete: true [Term] id: PATO:0000359 name: water content value -namespace: attribute is_obsolete: true [Term] id: PATO:0000360 name: consistency value -namespace: attribute is_obsolete: true [Term] id: PATO:0000361 name: gel consistency value -namespace: attribute is_obsolete: true [Term] id: PATO:0000362 name: direction value -namespace: attribute is_obsolete: true [Term] id: PATO:0000363 name: away -namespace: attribute is_obsolete: true [Term] id: PATO:0000364 name: bi-directional -namespace: attribute is_obsolete: true [Term] id: PATO:0000365 name: down -namespace: attribute +def: "A direction from a higher to a lower point." [PATO GVG:] is_a: PATO:0000039 ! direction [Term] id: PATO:0000366 name: left -namespace: attribute +def: "A direction that is similar to the direction of an object to the nor... [truncated message content] |
From: <mg...@us...> - 2006-11-22 23:38:33
|
Revision: 221 http://svn.sourceforge.net/obo/?rev=221&view=rev Author: mgibson Date: 2006-11-22 15:38:29 -0800 (Wed, 22 Nov 2006) Log Message: ----------- redid layout & tweeked for all the new fields Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java phenote/trunk/src/java/phenote/gui/TermInfo.java phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java phenote/trunk/src/java/phenote/gui/field/FieldPanel.java phenote/trunk/src/java/phenote/main/Phenote.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-11-22 20:43:59 UTC (rev 220) +++ phenote/trunk/build.xml 2006-11-22 23:38:29 UTC (rev 221) @@ -389,7 +389,7 @@ </target> - +<!-- need to test if PHENOTE_VERSION is defined - possible?? --> <target name="webstart"> <copy todir="phenote-webstart"> <fileset file="doc/phenote-website/*.html"/> @@ -403,6 +403,12 @@ </copy> </target> + <target name="webstart-just-phenote-jar"> + <signjar jar="${lib}/phenote.jar" keystore="plumpkey" alias="signFiles" + storepass="plumper" keypass="plumper"/> + <copy file="${lib}/phenote.jar" + todir="phenote-webstart/${env.PHENOTE_VERSION}/jars"/> + </target> </project> Modified: phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2006-11-22 20:43:59 UTC (rev 220) +++ phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2006-11-22 23:38:29 UTC (rev 221) @@ -67,8 +67,8 @@ private void init() { setLayout(new GridLayout(2,1)); // row,col - setPreferredSize(new Dimension(400,800)); - setMinimumSize(new Dimension(400,500)); + setPreferredSize(new Dimension(1800,800)); + setMinimumSize(new Dimension(1400,630)); characterTableModel = new CharacterTableModel(); charJTable = new JTable(characterTableModel); Modified: phenote/trunk/src/java/phenote/gui/TermInfo.java =================================================================== --- phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-11-22 20:43:59 UTC (rev 220) +++ phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-11-22 23:38:29 UTC (rev 221) @@ -58,8 +58,9 @@ public JComponent getComponent() { JPanel termInfoPanel = new JPanel(new BorderLayout(0,0)); // hgap,vgap - termInfoPanel.setPreferredSize(new Dimension(600,700)); - termInfoPanel.setMinimumSize(new Dimension(350,500)); + termInfoPanel.setPreferredSize(new Dimension(700,100)); + termInfoPanel.setMinimumSize(new Dimension(380,100)); + //termInfoPanel.setMaximumSize(new Dimension(380,400)); if (DO_HTML) { JEditorPane editorPane = new JEditorPane(); editorPane.setContentType("text/html"); // sets up HTMLEditorKit Modified: phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java 2006-11-22 20:43:59 UTC (rev 220) +++ phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java 2006-11-22 23:38:29 UTC (rev 221) @@ -73,11 +73,11 @@ // this will probably throw errors if non metal look & feel is used setUI(new MetalListComboUI()); setEditable(true); - setPreferredSize(new Dimension(390,22)); - setMaximumSize(new Dimension(390,22)); + setPreferredSize(new Dimension(390,20)); + setMaximumSize(new Dimension(390,20)); // this is super critical - fixes bug where layout goes to hell if string are long // in completion - dont ask me why???? - setMinimumSize(new Dimension(390,22)); + setMinimumSize(new Dimension(390,20)); AutoTextFieldEditor autoTextFieldEditor = new AutoTextFieldEditor(); this.setEditor(autoTextFieldEditor); // dont know why by setting fonts this seem to get worse not better in terms of Modified: phenote/trunk/src/java/phenote/gui/field/FieldPanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/FieldPanel.java 2006-11-22 20:43:59 UTC (rev 220) +++ phenote/trunk/src/java/phenote/gui/field/FieldPanel.java 2006-11-22 23:38:29 UTC (rev 221) @@ -3,6 +3,7 @@ import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.Container; +import java.awt.Dimension; import java.awt.GridBagConstraints; import java.awt.GridBagLayout; import java.util.ArrayList; @@ -29,7 +30,7 @@ * TermPanel holds all the fields for the terms - Genotype, Entity/Anatomy, QUALITY. * Can be populated by hand (Genotype), or selection of instance in completion list. rename FieldPanel or CharFieldPanel? - also has SearchParamPanel. + also has SearchParamPanel(?). */ public class FieldPanel extends JPanel { @@ -46,7 +47,11 @@ } // false for post comp panel public FieldPanel(boolean doAllOntologies) { + //this.setPreferredSize(new Dimension(800,750)); + // should figure depth from # of fields really + this.setMinimumSize(new Dimension(690,490)); fieldPanel = new JPanel(new GridBagLayout()); + // panel inside of panel - i think is a leftover no reason now add(fieldPanel); // default flow layout? if (doAllOntologies) initAllOntologies(); @@ -128,7 +133,7 @@ private GridBagConstraints makeFieldConstraint() { int x = 2;//ontologyChooserPresent ? 2 : 1; int width = 1;//ontologyChooserPresent ? 1 : 2; // ??? - return GridBagUtil.makeWidthConstraint(x,gridbagRow++,1,3,width); + return GridBagUtil.makeWidthConstraint(x,gridbagRow++,1,2,width); } // put button at end of regular row? or beginning of pc row? Modified: phenote/trunk/src/java/phenote/main/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/main/Phenote.java 2006-11-22 20:43:59 UTC (rev 220) +++ phenote/trunk/src/java/phenote/main/Phenote.java 2006-11-22 23:38:29 UTC (rev 221) @@ -165,7 +165,7 @@ frame = new JFrame("Phenote "+PhenoteVersion.versionString()); frame.getContentPane().add(makeMainPanel()); MenuManager.createMenuManager(frame); - frame.setPreferredSize(new Dimension(1100,650)); + frame.setPreferredSize(new Dimension(1100,700)); if (standalone) // if stand alone exit java on window close frame.addWindowListener(new WindowExit()); frame.pack(); @@ -186,27 +186,32 @@ private JPanel makeMainPanel() { JPanel mainPanel = new JPanel(new GridBagLayout()); // ?? - JPanel termAndTablePanel = new JPanel(); - BoxLayout bl = new BoxLayout(termAndTablePanel,BoxLayout.Y_AXIS); - termAndTablePanel.setLayout(bl); + //JPanel termAndTablePanel = new JPanel(); + JPanel upperPanel = new JPanel(); + //BoxLayout bl = new BoxLayout(termAndTablePanel,BoxLayout.Y_AXIS); + BoxLayout bl = new BoxLayout(upperPanel,BoxLayout.X_AXIS); + upperPanel.setLayout(bl); - //termAndInstancePanel.add(makeTermPanel()); fieldPanel = new FieldPanel(); - termAndTablePanel.add(fieldPanel); + upperPanel.add(fieldPanel); - characterTablePanel = new CharacterTablePanel(); //fieldPanel); - // eventually switch to event listener - no explicit connection... - //fieldPanel.setCharacterTablePanel(characterTablePanel); - termAndTablePanel.add(characterTablePanel); - GridBagConstraints gbc = GridBagUtil.makeConstraint(0,0,5,5); - mainPanel.add(termAndTablePanel,gbc); termInfo = new TermInfo(); //fieldPanel); - ++gbc.gridx; // ?? - gbc.anchor = GridBagConstraints.NORTHWEST; - mainPanel.add(termInfo.getComponent(),gbc); + upperPanel.add(termInfo.getComponent()); + //++gbc.gridx; // ?? + //gbc.anchor = GridBagConstraints.NORTHWEST; // ?? + //mainPanel.add(termInfo.getComponent(),gbc); + + GridBagConstraints gbc = GridBagUtil.makeConstraint(0,0,5,5); + mainPanel.add(upperPanel,gbc); + + characterTablePanel = new CharacterTablePanel(); + //termAndTablePanel.add(characterTablePanel); + ++gbc.gridy; // ? + mainPanel.add(characterTablePanel,gbc); + return mainPanel; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-12-13 22:38:35
|
Revision: 251 http://svn.sourceforge.net/obo/?rev=251&view=rev Author: mgibson Date: 2006-12-13 14:38:32 -0800 (Wed, 13 Dec 2006) Log Message: ----------- some initial code for getting graph viewer setup from uvics shrimp visuals. theres now 2 notions of selection mouse over selection and just regular selection. mouse over selection (in auto comp) doesnt cause graphic to redisplay as that would be too much. also some fixes for loading from pheno syntax broken for generic datamodel - still needs more work well phenote now has a gajillion jars - gee whiz Modified Paths: -------------- phenote/trunk/conf/initial-flybase.cfg phenote/trunk/conf/initial-zfin.cfg phenote/trunk/doc/phenote-website/phenote.html phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java phenote/trunk/src/java/phenote/datamodel/Character.java phenote/trunk/src/java/phenote/datamodel/CharacterI.java phenote/trunk/src/java/phenote/datamodel/Ontology.java phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java phenote/trunk/src/java/phenote/gui/TermInfo.java phenote/trunk/src/java/phenote/gui/field/TermCompList.java phenote/trunk/src/java/phenote/gui/selection/SelectionManager.java phenote/trunk/src/java/phenote/gui/selection/TermSelectionEvent.java phenote/trunk/src/java/phenote/main/Phenote.java phenote/trunk/src/web/javascript/phenote-state.js Added Paths: ----------- phenote/trunk/jars/layouts.jar phenote/trunk/jars/shrimp.jar phenote/trunk/jars/treemap.jar phenote/trunk/src/java/phenote/gui/ShrimpDag.java Modified: phenote/trunk/conf/initial-flybase.cfg =================================================================== --- phenote/trunk/conf/initial-flybase.cfg 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/conf/initial-flybase.cfg 2006-12-13 22:38:32 UTC (rev 251) @@ -1,5 +1,5 @@ -<phenote-configuration version="0.8" xmlns="phenote/config/xml"> +<phenote-configuration version="0.8" xmlns="phenote/config/xml" noNamespaceSchemaLocation="phenote-config.xsd"> <dataadapter name="phenosyntax"/> <dataadapter name="phenoxml"/> Modified: phenote/trunk/conf/initial-zfin.cfg =================================================================== --- phenote/trunk/conf/initial-zfin.cfg 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/conf/initial-zfin.cfg 2006-12-13 22:38:32 UTC (rev 251) @@ -1,4 +1,4 @@ -<phenote-configuration version="0.8" xmlns="phenote/config/xml"> +<phenote-configuration version="0.8" xmlns="phenote/config/xml" xmlns:xsi="http://www.w3.org/1999/XMLSchema/instance" schemaLocation="phenote-config.xsd"> <dataadapter name="phenosyntax"/> <dataadapter name="phenoxml"/> @@ -9,7 +9,7 @@ <field name="Genotype" type="free_text"/> - <field name="Genetic Context" file="context.obo"/> + <field name="Genetic Context" file="context.obo" /> <field name="Entity"> <postcomp relationship-ontology="relationship.obo"/> Modified: phenote/trunk/doc/phenote-website/phenote.html =================================================================== --- phenote/trunk/doc/phenote-website/phenote.html 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/doc/phenote-website/phenote.html 2006-12-13 22:38:32 UTC (rev 251) @@ -35,7 +35,7 @@ <a href="http://reaper.lbl.gov/phenote/html/ncbo.html">Webby Phenote(components used by Zfin)</a><br> <br> -Webby phenote is a collaboration with Sohel Merchant at DichtyBase. +Webby phenote is a collaboration with Sohel Merchant at dictyBase. Here is what they have done:<br> <br> <a Added: phenote/trunk/jars/layouts.jar =================================================================== (Binary files differ) Property changes on: phenote/trunk/jars/layouts.jar ___________________________________________________________________ Name: svn:executable + * Name: svn:mime-type + application/octet-stream Added: phenote/trunk/jars/shrimp.jar =================================================================== (Binary files differ) Property changes on: phenote/trunk/jars/shrimp.jar ___________________________________________________________________ Name: svn:executable + * Name: svn:mime-type + application/octet-stream Added: phenote/trunk/jars/treemap.jar =================================================================== (Binary files differ) Property changes on: phenote/trunk/jars/treemap.jar ___________________________________________________________________ Name: svn:executable + * Name: svn:mime-type + application/octet-stream Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/config/Config.java 2006-12-13 22:38:32 UTC (rev 251) @@ -228,6 +228,7 @@ System.out.println("config file: "+configUrl); PhenoteConfigurationDocument pcd = PhenoteConfigurationDocument.Factory.parse(configUrl);//configFile); + pcd.validate(); //??? PhenoteConfiguration pc = pcd.getPhenoteConfiguration(); Modified: phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java 2006-12-13 22:38:32 UTC (rev 251) @@ -53,7 +53,8 @@ // Genotype - not strictly part of pheno syntax but lets face it we need it // i would say its an omission from syntax //sb.append(" GT=").append(character.getGenotype()); - sb.append(" GT=").append(character.getValueString("Genotype")); + if (character.hasValue("Genotype")) + sb.append(" GT=").append(character.getValueString("Genotype")); if (character.hasValue("Genetic Context")) sb.append(" GC=").append(makeValue(character.getTerm("Genetic Context"))); @@ -61,6 +62,8 @@ throw new BadCharException("Error: character has no entity, ignoring"); //sb.append(" E=").append(makeValue(character.getEntity())); sb.append(" E=").append(makeValue(character.getTerm("Entity"))); + + // if (character.hasValue(CharFieldEnum.STAGE)) //if (character.getQuality() == null) if (!character.hasValue("Quality")) Modified: phenote/trunk/src/java/phenote/datamodel/Character.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/Character.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/datamodel/Character.java 2006-12-13 22:38:32 UTC (rev 251) @@ -61,8 +61,13 @@ // be some sort of somthing to indicate "empty" value? return getValue(cf) != null; // && !getValue(cf).equals(""); } - public boolean hasValue(String fieldName) throws Exception { - return hasValue(getCharFieldForName(fieldName)); + public boolean hasValue(String fieldName) { + try { + return hasValue(getCharFieldForName(fieldName)); + } + catch (Exception e) { // throws exception if doesnt have + return false; + } } private CharField getCharFieldForName(String fieldName) throws Exception { Modified: phenote/trunk/src/java/phenote/datamodel/CharacterI.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-12-13 22:38:32 UTC (rev 251) @@ -11,6 +11,24 @@ misspelling would end up in a char field */ public interface CharacterI { + /** generic fields!!! */ + public void setValue(CharField cf, CharFieldValue cfv); // ?? + public CharFieldValue getValue(CharField cf); + // should make an exception for this + public String getValueString(String fieldName) throws Exception; // yuck + public OBOClass getTerm(String fieldName) throws Exception; + // public void setTerm(String field, OBOClass term); + // needed for protege plugin + // public void setTerm(String field, String id) throws OboException; + public boolean hasValue(CharField cf); + public boolean hasValue(String fieldName) throws Exception; + + public CharacterI cloneCharacter(); + public boolean equals(CharacterI c); + public boolean hasNoContent(); + + + // pase! delete! public String getEntityName(); public String getQualityName(); // OBOClass? public String getGeneticContextName(); @@ -29,18 +47,4 @@ public void setEntity(OBOClass e); public void setQuality(OBOClass p); public void setGeneticContext(OBOClass gc); - - - /** generic fields!!! */ - public void setValue(CharField cf, CharFieldValue cfv); // ?? - public CharFieldValue getValue(CharField cf); - // should make an exception for this - public String getValueString(String fieldName) throws Exception; // yuck - public OBOClass getTerm(String field) throws Exception; - public boolean hasValue(CharField cf); - public boolean hasValue(String fieldName) throws Exception; - - public CharacterI cloneCharacter(); - public boolean equals(CharacterI c); - public boolean hasNoContent(); -} + } Modified: phenote/trunk/src/java/phenote/datamodel/Ontology.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/Ontology.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/datamodel/Ontology.java 2006-12-13 22:38:32 UTC (rev 251) @@ -125,7 +125,7 @@ } - private OBOSession getOboSession() { return oboSession; } + public OBOSession getOboSession() { return oboSession; } public List<OBOClass> getSortedTerms(Set terms) { List<OBOClass> sortedTerms = new ArrayList<OBOClass>(); Modified: phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2006-12-13 22:38:32 UTC (rev 251) @@ -50,6 +50,7 @@ private JButton deleteButton; private JButton undoButton; private JButton commitButton; + private JButton graphWindow; private JScrollBar verticalScrollBar; private boolean scrollToNewLastRowOnRepaint = false; private boolean ignoreSelectionChange = false; @@ -102,6 +103,8 @@ // should we only add if have data adapter - or disable at least? // should this go in a menu? commitButton = addButton(SAVE_STRING,al,buttonPanel); + buttonPanel.add(Box.createRigidArea(new Dimension(20,0))); + graphWindow = addButton("Graph",al,buttonPanel); add(buttonPanel); @@ -254,6 +257,10 @@ EditManager.inst().undo(); } + else if (e.getActionCommand().equals("Graph")) { + ShrimpDag.inst().display(); + } + // IF DELETED LAST ROW, then need to make a new blank one (sandbox mode) if (!hasRows() && SANDBOX_MODE) { //fieldPanel.clear(); // SelectionManager.clearCharacterSelection() Added: phenote/trunk/src/java/phenote/gui/ShrimpDag.java =================================================================== --- phenote/trunk/src/java/phenote/gui/ShrimpDag.java (rev 0) +++ phenote/trunk/src/java/phenote/gui/ShrimpDag.java 2006-12-13 22:38:32 UTC (rev 251) @@ -0,0 +1,85 @@ +package phenote.gui; + +//import javax.swing.JFrame; + +import org.geneontology.oboedit.datamodel.OBOSession; + +//import ca.uvic.csr.shrimp.gui.QueryView.QueryView; +import ca.uvic.csr.shrimp.gui.QueryView.OBOViewer; +import ca.uvic.csr.shrimp.gui.QueryView.QueryView; + +import phenote.gui.selection.SelectionManager; +import phenote.gui.selection.TermSelectionEvent; +import phenote.gui.selection.TermSelectionListener; + +import phenote.datamodel.Ontology; +import phenote.datamodel.OntologyManager; + +class ShrimpDag { + + //private JFrame window; + private OBOViewer oboViewer; + private static ShrimpDag singleton; + + public static ShrimpDag inst() { + if (singleton == null) singleton = new ShrimpDag(); + return singleton; + } + + private ShrimpDag() { + //window = new JFrame("Shrimp ontology viewer"); + //window.pack(); + //window.setVisible(true); + init(); + } + + //public void display() {} + + /** send obo sessions to shrimp so it can set them up in its datamodel*/ + public void initOntologies() { + // do this in a separate thread! no need to hold up phenote with this + for (Ontology o : OntologyManager.inst().getAllOntologies()) { + // oboViewer.loadOboSession(o.getOboSession()); + } + } + + private void init() { + //initShrimp(); + SelectionManager.inst().addTermSelectionListener(new ShrimpSelectionListener()); + } + public void display() { + + //queryView = new QueryView(); false - show query view? + boolean showQueryPanel = true; + oboViewer = + new OBOViewer("Shrimp ontology viewer",getOboSession(),showQueryPanel); + } + + private OBOSession getOboSession() { + // just hard wire to go for now + try { + Ontology o = OntologyManager.inst().getOntologyForName("ZF"); + return o.getOboSession(); + } catch (phenote.datamodel.OntologyException e) { + System.out.println("no ontol for dag"); + return null; + } + } + + private QueryView getQueryView() { + return oboViewer.getQueryView(); + } + + private class ShrimpSelectionListener implements TermSelectionListener { + + public boolean termSelected(TermSelectionEvent e) { + if (e.isMouseOverEvent()) return false; + String term = e.getOboClass().getName(); + boolean animate = true; + getQueryView().query(term, animate); + return true; + } + + } + +} \ No newline at end of file Modified: phenote/trunk/src/java/phenote/gui/TermInfo.java =================================================================== --- phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-12-13 22:38:32 UTC (rev 251) @@ -119,6 +119,7 @@ /** Listen for selection from phenote (mouse over completion list) */ private class InfoTermSelectionListener implements TermSelectionListener { public boolean termSelected(TermSelectionEvent e) { + if (!e.isMouseOverEvent()) return false; setTextFromOboClass(e.getOboClass()); // This sets who now listens to use term button clicks (only 1 listener) setUseTermListener(e.getUseTermListener()); @@ -186,6 +187,8 @@ try { OBOClass term = OntologyManager.inst().getOboClass(id); // ex setTextFromOboClass(term); + // send out term selection (non mouse over) for DAG view + SelectionManager.inst().selectTerm(TermInfo.this, term); } catch (TermNotFoundException ex) { return; } } Modified: phenote/trunk/src/java/phenote/gui/field/TermCompList.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/TermCompList.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/gui/field/TermCompList.java 2006-12-13 22:38:32 UTC (rev 251) @@ -54,6 +54,8 @@ if doesnt validate throw ex */ protected void setCurrentValidItem() throws OboException { setOboClass(getSelectedOboClass()); //this will set text to oboclass + // send out selection event that is NOT a mouse over event (for DAG view) + SelectionManager.inst().selectTerm(this, getSelectedOboClass()); } protected String getCurrentTermRelName() { @@ -174,7 +176,7 @@ CompletionTerm ct = (CompletionTerm)selectedValue; OBOClass oboClass = ct.getOboClass(); Object src = TermCompList.this; - getSelectionManager().selectTerm(src,oboClass,getUseTermListener()); + getSelectionManager().selectMouseOverTerm(src,oboClass,getUseTermListener()); //setTextFromOboClass(oboClass); } } // end of CompletionListListener inner class Modified: phenote/trunk/src/java/phenote/gui/selection/SelectionManager.java =================================================================== --- phenote/trunk/src/java/phenote/gui/selection/SelectionManager.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/gui/selection/SelectionManager.java 2006-12-13 22:38:32 UTC (rev 251) @@ -35,17 +35,29 @@ // void addCharacterSelectionListener(CharacterSelectionListener l) {} - public void selectTerm(Object source, OBOClass oboClass,UseTermListener l) { - TermSelectionEvent e = makeTermEvent(source,oboClass,l); + public void selectMouseOverTerm(Object source, OBOClass oboClass,UseTermListener l) { + boolean isMouseOver = true; + TermSelectionEvent e = makeTermEvent(source,oboClass,l,isMouseOver); + fireSelect(e); + } + + public void selectTerm(Object source,OBOClass oboClass) { + boolean isMouseOver = false; + TermSelectionEvent e = makeTermEvent(source,oboClass,null,isMouseOver); + fireSelect(e); + } + + private void fireSelect(TermSelectionEvent e) { Iterator<TermSelectionListener> it = termListenerList.iterator(); while(it.hasNext()) - it.next().termSelected(e); + it.next().termSelected(e); } - + + // void selectTerm(String termName) {} ??? - private TermSelectionEvent makeTermEvent(Object src, OBOClass oc,UseTermListener l) { - return new TermSelectionEvent(src,oc,l); + private TermSelectionEvent makeTermEvent(Object src, OBOClass oc,UseTermListener l,boolean mouse) { + return new TermSelectionEvent(src,oc,l,mouse); } public CharacterI getFirstSelectedCharacter() { Modified: phenote/trunk/src/java/phenote/gui/selection/TermSelectionEvent.java =================================================================== --- phenote/trunk/src/java/phenote/gui/selection/TermSelectionEvent.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/gui/selection/TermSelectionEvent.java 2006-12-13 22:38:32 UTC (rev 251) @@ -8,14 +8,18 @@ private OBOClass oboClass; private UseTermListener useTermListener; + private boolean isMouseOverEvent; - TermSelectionEvent(Object source, OBOClass oboClass, UseTermListener utl) { + TermSelectionEvent(Object source, OBOClass oboClass, UseTermListener utl,boolean isMouse) { super(source); this.oboClass = oboClass; useTermListener = utl; + isMouseOverEvent = isMouse; } public OBOClass getOboClass() { return oboClass; } public UseTermListener getUseTermListener() { return useTermListener; } + + public boolean isMouseOverEvent() { return isMouseOverEvent; } } Modified: phenote/trunk/src/java/phenote/main/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/main/Phenote.java 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/java/phenote/main/Phenote.java 2006-12-13 22:38:32 UTC (rev 251) @@ -81,7 +81,9 @@ public void initOntologies() { //OntologyDataAdapter oda = new OntologyDataAdapter(); // singleton? // loads up OntologyManager - non intuitive? - OntologyDataAdapter.initialize(); + OntologyDataAdapter.initialize(); + // if (config.useShrimpDagViewer()) + // ShrimpDag.inst().initOntologies(); } private void loadFromCommandLine() { Modified: phenote/trunk/src/web/javascript/phenote-state.js =================================================================== --- phenote/trunk/src/web/javascript/phenote-state.js 2006-12-13 18:04:05 UTC (rev 250) +++ phenote/trunk/src/web/javascript/phenote-state.js 2006-12-13 22:38:32 UTC (rev 251) @@ -35,7 +35,7 @@ updateTermInfo : function (term) { var pars = term.params; - var myAjax = new Ajax.Updater('termInfo', url, {method: 'get', parameters: pars } ); + var myAjax = new Ajax.Updater('termInfo', this.termInfoUrl, {method: 'get', parameters: pars } ); this.setCurrentTermInfoTerm(term); }, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-12-19 18:08:01
|
Revision: 257 http://svn.sourceforge.net/obo/?rev=257&view=rev Author: mgibson Date: 2006-12-19 10:08:00 -0800 (Tue, 19 Dec 2006) Log Message: ----------- got pheno syntax adapter read working again working with new generic datamodel - the syntax tags are actually configurable in the config file now - im not sure what to do with stage relationships yet - for now just hardwired in dataadapter to "during" - in future either use obo instances or clone obo classes or put a relationship in char field value? not sure yet but nothing urgent Character now has setValue(CharField,String) and looks up string in ontology throws TermNotFoundEx if string not found Modified Paths: -------------- phenote/trunk/jars/phenoteconfigbeans.jar phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/config/FieldConfig.java phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java phenote/trunk/src/java/phenote/datamodel/CharField.java phenote/trunk/src/java/phenote/datamodel/Character.java phenote/trunk/src/java/phenote/datamodel/CharacterI.java phenote/trunk/src/java/phenote/datamodel/Ontology.java phenote/trunk/src/java/phenote/datamodel/OntologyManager.java phenote/trunk/src/java/phenote/gui/TermInfo.java Modified: phenote/trunk/jars/phenoteconfigbeans.jar =================================================================== (Binary files differ) Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/config/Config.java 2006-12-19 18:08:00 UTC (rev 257) @@ -31,6 +31,7 @@ import phenote.config.xml.LogDocument.Log; import phenote.util.FileUtil; +import phenote.datamodel.CharField; import phenote.datamodel.CharFieldEnum; import phenote.dataadapter.DataAdapterI; import phenote.dataadapter.fly.FlybaseDataAdapter; @@ -215,6 +216,21 @@ return fieldList; } + /** kinda silly to return list?? so there are 2 fields for "Tag" which perhaps is silly + but thats whats happening so need to deal with it */ + public List<CharField> getCharFieldsForSyntaxAbbrev(String abb) throws ConfigException { + // cache in hash?? + List<CharField> fields = new ArrayList<CharField>(2); + for (FieldConfig fc : getFieldConfigList()) { + if (fc.hasSyntaxAbbrev(abb) || fc.hasLabel(abb)) // abbrev or label + fields.add(fc.getCharField()); + //return fc.getCharField(); + } + if (fields.isEmpty()) + throw new ConfigException("No Field configured with syntax abbrev "+abb); + return fields; + } + /** should this just be a part of fieldConfigList? and main window would filter it out when making up fields? rel is for post comp gui - or maybe FieldConfig should have isPostComp, getPostCompRelFile - yes! */ @@ -296,7 +312,7 @@ String name = field.getName().getStringValue(); //toString(); // has to be a valid value - no longer true for generic free types FieldConfig fc; - try { + try { // phase this out!! CharFieldEnum cfe = CharFieldEnum.getCharFieldEnum(name); //if (cfe == null) ??? fc = new FieldConfig(cfe,name); @@ -304,6 +320,10 @@ catch (Exception e) { // no char field enum for name - new generic! fc = new FieldConfig(name); } + + if (field.getSyntaxAbbrev() != null) { + fc.setSyntaxAbbrev(field.getSyntaxAbbrev().getStringValue()); + } // POST COMP, relationship ontol if (field.getPostcomp() != null) { Modified: phenote/trunk/src/java/phenote/config/FieldConfig.java =================================================================== --- phenote/trunk/src/java/phenote/config/FieldConfig.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/config/FieldConfig.java 2006-12-19 18:08:00 UTC (rev 257) @@ -3,16 +3,19 @@ import java.util.ArrayList; import java.util.List; -import phenote.datamodel.CharFieldEnum; +import phenote.datamodel.CharField; +import phenote.datamodel.CharFieldEnum; // phase out public class FieldConfig { - private CharFieldEnum charFieldEnum; + private CharFieldEnum charFieldEnum; // phase out + private CharField charField; private String label; // Entity field can have multiple ontologies private List<OntologyConfig> ontologyConfigList; private boolean isPostComp; private OntologyConfig postCompRelOntCfg; + private String syntaxAbbrev; // FieldConfig(CharFieldEnum c,OntologyConfig o) { // charFieldEnum = c; @@ -39,6 +42,7 @@ // --> getName? public String getLabel() { return label; } + boolean hasLabel(String label) { return label.equals(this.label); } //private void setOntologyFile(String f){getOntologyConfig().setOntologyFile(f);} public boolean hasOntologies() { @@ -86,4 +90,13 @@ public OntologyConfig getPostCompRelOntCfg() { return postCompRelOntCfg; } + + void setSyntaxAbbrev(String syn) { + this.syntaxAbbrev = syn; + } + //void String getSyntaxAbbrev() { return syntaxAbbrev; } + boolean hasSyntaxAbbrev(String abb) { return abb.equals(syntaxAbbrev); } + + public void setCharField(CharField cf) { charField = cf; } + CharField getCharField() { return charField; } } Modified: phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2006-12-19 18:08:00 UTC (rev 257) @@ -71,9 +71,8 @@ // CharFieldEnum fce = fieldConfig.getCharFieldEnum(); // cf = new CharField(fce); // } -// else { cf = new CharField(fieldConfig.getLabel()); -// } + fieldConfig.setCharField(cf); // ONTOLOGIES if (fieldConfig.hasOntologies()) { Modified: phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/dataadapter/fly/FlyCharacter.java 2006-12-19 18:08:00 UTC (rev 257) @@ -5,7 +5,7 @@ import phenote.datamodel.CharacterI; import phenote.datamodel.Character; import phenote.datamodel.OntologyManager; -import phenote.datamodel.OntologyManager.TermNotFoundException; +import phenote.datamodel.TermNotFoundException; public class FlyCharacter implements FlyCharacterI { Modified: phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/dataadapter/phenosyntax/PhenoSyntaxChar.java 2006-12-19 18:08:00 UTC (rev 257) @@ -1,5 +1,6 @@ package phenote.dataadapter.phenosyntax; +import java.util.List; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -8,7 +9,11 @@ import phenote.datamodel.Character; import phenote.datamodel.CharacterI; +import phenote.datamodel.CharField; import phenote.datamodel.OntologyManager; +import phenote.datamodel.TermNotFoundException; +import phenote.config.Config; +import phenote.config.ConfigException; /** A phenotype character thats basically a dataadapter object for datamodel CharacterI. It can make a phenosyntax string from a CharacterI and make @@ -83,29 +88,11 @@ } private String makeValue(OBOClass term) { - // return idPrefixAndName(term); // michael wants ids... - //return term.getID(); // id & commented out name for readability return term.getID() + " /*" + term.getName() + "*/"; } -// /** Merges id prefix and name, so for id GO:1234 with name "growth" returns -// "GO:growth", which is readable and computable & syn acceptable - pase - doing ids*/ -// private String idPrefixAndName(OBOClass term) { -// return getIdPrefix(term)+term.getName(); -// } - -// /** for GO:12345 returns GO: - with colon! - pase - doing ids */ -// private String getIdPrefix(OBOClass term) { -// if (term == null) return ""; // shouldnt happen -// String id = term.getID(); -// int colonIndex = id.indexOf(":"); -// return id.substring(0,colonIndex+1); // +1 retain colon -// } - - - // READ /** Parse syntax line into character */ @@ -151,34 +138,68 @@ private void addTagValToChar(String tag, String value) { if (value.equals("")) { - System.out.println("No value given for "+tag); + log().error("No value given for "+tag); return; } OntologyManager om = OntologyManager.inst(); - + try { - if (tag.equals("PUB")) - character.setPub(value); - else if (tag.equals("GT")) - character.setGenotype(value); - else if (tag.equals("GC")) - character.setGeneticContext(om.getOboClassWithExcep(value)); // throws ex - else if (tag.equals("E")) - character.setEntity(om.getTermOrPostComp(value)); - else if (tag.equals("Q")) - character.setQuality(om.getOboClassWithExcep(value)); - else // throw exception? or let rest of char go through? - System.out.println("pheno syntax tag "+tag+" not recognized (value "+value+")"); + List<CharField> fields = Config.inst().getCharFieldsForSyntaxAbbrev(tag);//Ex + for (CharField cf : fields) { + if (cf.getName().equals("Stage")) { + // todo - a general relationship extracter? + value = extractStageHack(value); // for now - fix for real later + } + try { + // set String -> for obo class automatically find term + character.setValue(cf,value); // throws TermNotFoundEx + return; // if no ex thrown were done + } + catch (TermNotFoundException e) {} // do nothing - try next char field + } } - catch (OntologyManager.TermNotFoundException e) { - log().error("Term not found for tag "+tag+" value "+value+" in loaded " - +"ontologies - check syntax with ontology files."); - return; - } + catch (ConfigException e) { log().error(e.getMessage()); } // field not found + //catch (TermNotFoundException e) { + System.out.println("PhSynCh term not found "+value); + //log().error(e.getMessage()); + log().error("Term not found "+value); // list char field? + //} + +// try { +// if (tag.equals("PUB")) +// character.setPub(value); +// else if (tag.equals("GT")) +// character.setGenotype(value); +// else if (tag.equals("GC")) +// character.setGeneticContext(om.getOboClassWithExcep(value)); // throws ex +// else if (tag.equals("E")) +// character.setEntity(om.getTermOrPostComp(value)); +// else if (tag.equals("Q")) +// character.setQuality(om.getOboClassWithExcep(value)); +// else // throw exception? or let rest of char go through? +// System.out.println("pheno syntax tag "+tag+" not recognized (value "+value+")"); +// } +// catch (OntologyManager.TermNotFoundException e) { +// log().error("Term not found for tag "+tag+" value "+value+" in loaded " +// +"ontologies - check syntax with ontology files."); +// return; +// } } + /** Stages come with rel - eg during(adult) - for now just assuming its during and ripping + off - in future need to read in rel, and store as relationship between Instances + (not OBOClasses!) - big refactor but go for it! + this extracts the "adult" in above example out of "during(adult)" + or alternatively just record relationship in CharFieldValue? */ + private String extractStageHack(String stageWithRel) { + Pattern p = Pattern.compile("during\\(([^\\)]+)\\)"); + Matcher m = p.matcher(stageWithRel); + if (m.matches()) + return m.group(1); + return stageWithRel; + } CharacterI getCharacter() { return character; } Modified: phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/dataadapter/phenoxml/PhenoXmlAdapter.java 2006-12-19 18:08:00 UTC (rev 257) @@ -30,7 +30,7 @@ import phenote.datamodel.CharacterListI; import phenote.datamodel.CharacterList; import phenote.datamodel.OntologyManager; -import phenote.datamodel.OntologyManager.TermNotFoundException; +import phenote.datamodel.TermNotFoundException; import phenote.dataadapter.CharacterListManager; import phenote.dataadapter.DataAdapterI; Modified: phenote/trunk/src/java/phenote/datamodel/CharField.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/datamodel/CharField.java 2006-12-19 18:08:00 UTC (rev 257) @@ -5,8 +5,7 @@ import org.geneontology.oboedit.datamodel.OBOClass; -// or just Field? or CharField? eventually separate class? -// associates enum & ontologies +// or just Field? or CharField? // CharField doesnt handle instance data, just specifies what ontologies are // associated with what parts of the generic character // CharFieldValue handles instance data @@ -111,6 +110,25 @@ public Ontology getPostCompRelOntol() { return postCompRelOntol; } + /** if free text returns string charfieldValue, for ontology field valueString is + id and searches ontologies for id, throws ontologyException if not found */ + public CharFieldValue makeValue(Character c, String valueString) + throws TermNotFoundException { + if (!hasOntologies()) + return new CharFieldValue(valueString,c,this); + else { + OBOClass oboClass=null; + for (Ontology ont : ontologyList) { + try { oboClass = ont.getOboClass(valueString); } + catch (TermNotFoundException e) {} // move on to next ontology + } + if (oboClass != null) + return new CharFieldValue(oboClass,c,this); + else + throw new TermNotFoundException(valueString+" not found in ontologies for "+this); + } + } + public String toString() { return "CharField: "+getName(); } } Modified: phenote/trunk/src/java/phenote/datamodel/Character.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/Character.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/datamodel/Character.java 2006-12-19 18:08:00 UTC (rev 257) @@ -13,15 +13,14 @@ public class Character implements CharacterI, Cloneable { // List<CharFieldValue> charFields??? or List<CharField> -// private String entity=""; -// private String quality=""; -// private String geneticContext=""; + // phase these out... private String pub; private String genotype=""; // eventually Genotype class // OboClass? OntologyTerm?... private OBOClass entity; // CharFieldValue??? private OBOClass quality; private OBOClass geneticContext; + // new generic data structure private HashMap<CharField,CharFieldValue> charFieldToValue = new HashMap<CharField,CharFieldValue>(); @@ -30,6 +29,12 @@ charFieldToValue.put(cf,cfv); //System.out.println("Char setVal "+cf+" val "+cfv); } + + public void setValue(CharField cf, String s) throws TermNotFoundException { + CharFieldValue cfv = cf.makeValue(this,s); + setValue(cf,cfv); + } + /** generic getter */ public CharFieldValue getValue(CharField cf) { CharFieldValue cfv = charFieldToValue.get(cf); Modified: phenote/trunk/src/java/phenote/datamodel/CharacterI.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/datamodel/CharacterI.java 2006-12-19 18:08:00 UTC (rev 257) @@ -13,6 +13,7 @@ /** generic fields!!! */ public void setValue(CharField cf, CharFieldValue cfv); // ?? + public void setValue(CharField cf, String valueString) throws TermNotFoundException; public CharFieldValue getValue(CharField cf); // should make an exception for this public String getValueString(String fieldName) throws Exception; // yuck Modified: phenote/trunk/src/java/phenote/datamodel/Ontology.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/Ontology.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/datamodel/Ontology.java 2006-12-19 18:08:00 UTC (rev 257) @@ -68,7 +68,7 @@ } private void filterLists() { - //if (!haveFilter() && !hasSlim()) return; // from config + //if (!haveFilter() && !hasSlim()) return; // froboSession.getTerm(id)om config if (doFiltering()) sortedTerms = filterList(sortedTerms); } @@ -78,17 +78,23 @@ /** returns null if dont have class for id, throws OntologyException if id is not found */ - public OBOClass getOboClass(String id) throws OntologyException { - OBOClass oc = oboSession.getTerm(id); - if (oc == null) throw new OntologyException(id +" id not found in ontology "+name); - return oc; + public OBOClass getOboClass(String id) throws TermNotFoundException { + // this aint right - if its a slim should only search slim + //OBOClass oc = oboSession.getTerm(id); + for (OBOClass term : sortedTerms) { + if (term.getID().equals(id)) + return term; + } + //if (term == null) + throw new TermNotFoundException(id +" id not found in ontology "+name); + //return oc; } /** Returns true if ontology holds obo class */ boolean hasOboClass(OBOClass oboClass) { // if this is too slow can do optimizations with prefixes try {getOboClass(oboClass.getID()); } - catch (OntologyException e) { return false; } + catch (TermNotFoundException e) { return false; } return true; // no exception - it has it } Modified: phenote/trunk/src/java/phenote/datamodel/OntologyManager.java =================================================================== --- phenote/trunk/src/java/phenote/datamodel/OntologyManager.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/datamodel/OntologyManager.java 2006-12-19 18:08:00 UTC (rev 257) @@ -100,11 +100,11 @@ for (Ontology o : getAllOntologies()) { //Ontology o = iter.next(); try { oboClass = o.getOboClass(id); } - catch (OntologyException e) { continue; } + catch (TermNotFoundException e) { continue; } if (oboClass != null) return oboClass; } - //return null; // not found - null -- ex? + // not sure if we need both onotlogy exception & termnotfoundEx ?? redundant? throw new TermNotFoundException("ID "+id+" not found in loaded ontologies"); } @@ -123,9 +123,6 @@ return term; } - public class TermNotFoundException extends Exception { - private TermNotFoundException(String m) { super(m); } - } private boolean isPostComp(String id) { if (id == null) return false; Modified: phenote/trunk/src/java/phenote/gui/TermInfo.java =================================================================== --- phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-12-19 17:31:06 UTC (rev 256) +++ phenote/trunk/src/java/phenote/gui/TermInfo.java 2006-12-19 18:08:00 UTC (rev 257) @@ -31,7 +31,7 @@ import phenote.datamodel.CharacterI; import phenote.datamodel.CharFieldEnum; import phenote.datamodel.OntologyManager; -import phenote.datamodel.OntologyManager.TermNotFoundException; +import phenote.datamodel.TermNotFoundException; import phenote.edit.EditManager; import phenote.edit.UpdateTransaction; import phenote.util.HtmlUtil; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2006-12-22 15:47:28
|
Revision: 265 http://svn.sourceforge.net/obo/?rev=265&view=rev Author: mgibson Date: 2006-12-22 07:47:24 -0800 (Fri, 22 Dec 2006) Log Message: ----------- changed default config in Config to flybase.cfg from initial-flybase.cfg Modified Paths: -------------- phenote/trunk/phenote phenote/trunk/src/java/phenote/config/Config.java Modified: phenote/trunk/phenote =================================================================== --- phenote/trunk/phenote 2006-12-21 00:27:27 UTC (rev 264) +++ phenote/trunk/phenote 2006-12-22 15:47:24 UTC (rev 265) @@ -1,3 +1,3 @@ #!/bin/sh -java -Xmx200M -classpath classfiles:jars/oboedit.jar:jars/org.geneontology.jar:jars/BrowserLauncher2-10rc4.jar:jars/junit-4.0.jar:jars/tomcat-servlet.jar:jars/xbean.jar:jars/jsr173_1.0_api.jar:jars/phenoxmlbeans.jar:jars/phenoteconfigbeans.jar:jars/log4j-1.2.13.jar:jars/te-common.jar phenote.main.Phenote $@ +java -Xmx300M -classpath classfiles:jars/oboedit.jar:jars/org.geneontology.jar:jars/BrowserLauncher2-10rc4.jar:jars/junit-4.0.jar:jars/tomcat-servlet.jar:jars/xbean.jar:jars/jsr173_1.0_api.jar:jars/phenoxmlbeans.jar:jars/phenoteconfigbeans.jar:jars/log4j-1.2.13.jar:jars/te-common.jar phenote.main.Phenote $@ Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2006-12-21 00:27:27 UTC (rev 264) +++ phenote/trunk/src/java/phenote/config/Config.java 2006-12-22 15:47:24 UTC (rev 265) @@ -40,7 +40,7 @@ public class Config { - public final static String DEFAULT_CONFIG_FILE = "/initial-flybase.cfg"; + public final static String DEFAULT_CONFIG_FILE = "flybase.cfg"; private static Config singleton = new Config(); private String configFile = DEFAULT_CONFIG_FILE; //private String patoFile = "attribute_and_values.obo"; // default value This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2007-01-04 19:10:32
|
Revision: 267 http://svn.sourceforge.net/obo/?rev=267&view=rev Author: mgibson Date: 2007-01-04 11:10:26 -0800 (Thu, 04 Jan 2007) Log Message: ----------- got phenote working with the latest shrimp dag viewer - still a bunch of issues to work out but its coming along - not ready yet for curators to check out i think Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/jars/layouts.jar phenote/trunk/jars/shrimp.jar phenote/trunk/phenote phenote/trunk/src/java/phenote/gui/ShrimpDag.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2006-12-22 18:24:19 UTC (rev 266) +++ phenote/trunk/build.xml 2007-01-04 19:10:26 UTC (rev 267) @@ -74,7 +74,7 @@ <!-- runs off classfiles not jar, todo: run-jar --> <target name="run" depends="compile"> - <java classname="phenote.main.Phenote" fork="yes" jvmargs="-Xmx120M"> + <java classname="phenote.main.Phenote" fork="yes" jvmargs="-Xmx400M"> <!-- arg value="-c configfilehereventually"/ --> <classpath> <pathelement path="${classfiles}"/> Modified: phenote/trunk/jars/layouts.jar =================================================================== (Binary files differ) Modified: phenote/trunk/jars/shrimp.jar =================================================================== (Binary files differ) Modified: phenote/trunk/phenote =================================================================== --- phenote/trunk/phenote 2006-12-22 18:24:19 UTC (rev 266) +++ phenote/trunk/phenote 2007-01-04 19:10:26 UTC (rev 267) @@ -1,3 +1,13 @@ #!/bin/sh -java -Xmx300M -classpath classfiles:jars/oboedit.jar:jars/org.geneontology.jar:jars/BrowserLauncher2-10rc4.jar:jars/junit-4.0.jar:jars/tomcat-servlet.jar:jars/xbean.jar:jars/jsr173_1.0_api.jar:jars/phenoxmlbeans.jar:jars/phenoteconfigbeans.jar:jars/log4j-1.2.13.jar:jars/te-common.jar phenote.main.Phenote $@ +PHENOTE_CLASSPATH=classfiles +for file in jars/*.jar; do + if [ $file != jars/phenote.jar ]; then + #echo "Adding ${file} to CLASSPATH" + PHENOTE_CLASSPATH=${PHENOTE_CLASSPATH}:${file}; + fi; +done + +java -Xmx300M -classpath ${PHENOTE_CLASSPATH} phenote.main.Phenote $@ + +##java -Xmx300M -classpath classfiles:jars/oboedit.jar:jars/org.geneontology.jar:jars/BrowserLauncher2-10rc4.jar:jars/junit-4.0.jar:jars/tomcat-servlet.jar:jars/xbean.jar:jars/jsr173_1.0_api.jar:jars/phenoxmlbeans.jar:jars/phenoteconfigbeans.jar:jars/log4j-1.2.13.jar:jars/te-common.jar phenote.main.Phenote $@ Modified: phenote/trunk/src/java/phenote/gui/ShrimpDag.java =================================================================== --- phenote/trunk/src/java/phenote/gui/ShrimpDag.java 2006-12-22 18:24:19 UTC (rev 266) +++ phenote/trunk/src/java/phenote/gui/ShrimpDag.java 2007-01-04 19:10:26 UTC (rev 267) @@ -1,7 +1,9 @@ package phenote.gui; -//import javax.swing.JFrame; +import java.awt.Component; +import javax.swing.JFrame; + import org.geneontology.oboedit.datamodel.OBOSession; //import ca.uvic.csr.shrimp.gui.QueryView.QueryView; @@ -27,9 +29,9 @@ } private ShrimpDag() { - //window = new JFrame("Shrimp ontology viewer"); - //window.pack(); - //window.setVisible(true); + //window = new JFrame("Shrimp ontology viewer"); + //window.pack(); + //window.setVisible(true); init(); } @@ -46,13 +48,24 @@ private void init() { //initShrimp(); SelectionManager.inst().addTermSelectionListener(new ShrimpSelectionListener()); + //initOntologies(); } public void display() { //queryView = new QueryView(); false - show query view? boolean showQueryPanel = true; - oboViewer = - new OBOViewer("Shrimp ontology viewer",getOboSession(),showQueryPanel); + oboViewer = new OBOViewer(showQueryPanel); + //new OBOViewer("Shrimp ontology viewer",getOboSession(),showQueryPanel); + oboViewer.loadOBOSession(getOboSession()); // change this! + + JFrame frame = new JFrame("Shrimp DAG view"); + //frame.setDefaultCloseOperation(java.awt.WindowListener.DISPOSE_ON_CLOSE); + frame.getContentPane().add(oboViewer.getView()); + frame.pack(); + frame.setSize(600, 600); + frame.setLocation(400, 200); + frame.setVisible(true); + } private OBOSession getOboSession() { @@ -76,10 +89,11 @@ if (e.isMouseOverEvent()) return false; String term = e.getOboClass().getName(); boolean animate = true; - getQueryView().query(term, animate); + //getQueryView().query(term, animate); + oboViewer.query(getOboSession(),e.getOboClass(),animate); return true; } } -} \ No newline at end of file +} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2007-01-05 22:26:06
|
Revision: 272 http://svn.sourceforge.net/obo/?rev=272&view=rev Author: mgibson Date: 2007-01-05 14:26:06 -0800 (Fri, 05 Jan 2007) Log Message: ----------- put in config flag uvic-graph enable="true" to enable/disable uvic graphics Modified Paths: -------------- phenote/trunk/conf/flybase.cfg phenote/trunk/conf/phenote-config.rnc phenote/trunk/conf/phenote-config.xsd phenote/trunk/conf/zfin-standalone.cfg phenote/trunk/jars/phenoteconfigbeans.jar phenote/trunk/src/java/phenote/config/Config.java phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java Modified: phenote/trunk/conf/flybase.cfg =================================================================== --- phenote/trunk/conf/flybase.cfg 2007-01-05 20:45:27 UTC (rev 271) +++ phenote/trunk/conf/flybase.cfg 2007-01-05 22:26:06 UTC (rev 272) @@ -6,6 +6,8 @@ <log config-file="conf/log4j-standalone.xml" /> + <uvic-graph enable="false"/> + <field name="Pub" syntax-abbrev="PUB"/> <field name="Genotype" syntax-abbrev="GT" type="free_text"/> Modified: phenote/trunk/conf/phenote-config.rnc =================================================================== --- phenote/trunk/conf/phenote-config.rnc 2007-01-05 20:45:27 UTC (rev 271) +++ phenote/trunk/conf/phenote-config.rnc 2007-01-05 22:26:06 UTC (rev 272) @@ -6,6 +6,7 @@ attribute version { xsd:float }, log, dataadapter*, + uvic-graph, field* } @@ -28,6 +29,8 @@ attribute config-file { text } } +uvic-graph = element uvic-graph { attribute enable { xsd:boolean } } + field = element field { ##attribute name { "Pub" | "Genotype" | "Genetic Context" | "Entity" | "Quality" }, Modified: phenote/trunk/conf/phenote-config.xsd =================================================================== --- phenote/trunk/conf/phenote-config.xsd 2007-01-05 20:45:27 UTC (rev 271) +++ phenote/trunk/conf/phenote-config.xsd 2007-01-05 22:26:06 UTC (rev 272) @@ -5,6 +5,7 @@ <xs:sequence> <xs:element ref="x:log"/> <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:dataadapter"/> + <xs:element ref="x:uvic-graph"/> <xs:element minOccurs="0" maxOccurs="unbounded" ref="x:field"/> </xs:sequence> <xs:attribute name="version" use="required" type="xs:float"/> @@ -30,6 +31,11 @@ <xs:attribute name="config-file" use="required"/> </xs:complexType> </xs:element> + <xs:element name="uvic-graph"> + <xs:complexType> + <xs:attribute name="enable" use="required" type="xs:boolean"/> + </xs:complexType> + </xs:element> <xs:element name="field"> <xs:complexType> <xs:sequence> Modified: phenote/trunk/conf/zfin-standalone.cfg =================================================================== --- phenote/trunk/conf/zfin-standalone.cfg 2007-01-05 20:45:27 UTC (rev 271) +++ phenote/trunk/conf/zfin-standalone.cfg 2007-01-05 22:26:06 UTC (rev 272) @@ -5,6 +5,8 @@ <log config-file="conf/log4j-standalone.xml"/> + <uvic-graph enable="true"/> + <field name="Pub" syntax-abbrev="PUB"/> <field name="Genotype" syntax-abbrev="GT" type="free_text"/> Modified: phenote/trunk/jars/phenoteconfigbeans.jar =================================================================== (Binary files differ) Modified: phenote/trunk/src/java/phenote/config/Config.java =================================================================== --- phenote/trunk/src/java/phenote/config/Config.java 2007-01-05 20:45:27 UTC (rev 271) +++ phenote/trunk/src/java/phenote/config/Config.java 2007-01-05 22:26:06 UTC (rev 272) @@ -29,6 +29,7 @@ import phenote.config.xml.FieldDocument.Field; import phenote.config.xml.OntologyDocument.Ontology; import phenote.config.xml.LogDocument.Log; +import phenote.config.xml.UvicGraphDocument.UvicGraph; import phenote.util.FileUtil; import phenote.datamodel.CharField; @@ -56,6 +57,7 @@ //private boolean checkForNewOntologies = false; //private int newOntologyCheckMinutes = 10; private String logConfigFile = "conf/log4j.xml"; // default log config file + private boolean uvicGraphEnabled = false; // default false for now /** singleton */ private Config() { @@ -169,30 +171,13 @@ // /** How many minutes between checks for new ontologies */ // public int getOntologyCheckMinutes() { return newOntologyCheckMinutes; } + /** config flag for enabling uvic shrimp dag graph */ + public boolean uvicGraphIsEnabled() { return uvicGraphEnabled; } + public URL getLogConfigUrl() throws FileNotFoundException { return FileUtil.findUrl(logConfigFile); } - private FieldConfig getLumpConfig() { - // name = Taxonmony, file = BTO.obo... - return lumpConfig; - } - - public boolean hasLumpField() { - return true; // config this - ctol may not have lumps... for now true - } - - public boolean hasLumpOntology() { - if (!hasLumpField()) - return false; - return lumpConfig.hasOntology(); - } - - public OntologyConfig getLumpOntologyConfig() { - if (!hasLumpField()) return null; - return lumpConfig.getOntologyConfig(); - } - public int getNumberOfFields() { return getFieldConfigList().size(); } @@ -270,6 +255,11 @@ addDataAdapterFromString(name); } + // GRAPH + UvicGraph gr = pc.getUvicGraph(); + if (gr != null) + uvicGraphEnabled = gr.getEnable(); + // FIELDS Field[] fields = pc.getFieldArray(); for (Field f : fields) { Modified: phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2007-01-05 20:45:27 UTC (rev 271) +++ phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2007-01-05 22:26:06 UTC (rev 272) @@ -104,7 +104,8 @@ // should this go in a menu? commitButton = addButton(SAVE_STRING,al,buttonPanel); buttonPanel.add(Box.createRigidArea(new Dimension(20,0))); - graphWindow = addButton("Graph",al,buttonPanel); + if (Config.inst().uvicGraphIsEnabled()) + graphWindow = addButton("Graph",al,buttonPanel); add(buttonPanel); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2007-01-11 21:15:40
|
Revision: 282 http://svn.sourceforge.net/obo/?rev=282&view=rev Author: mgibson Date: 2007-01-11 13:11:32 -0800 (Thu, 11 Jan 2007) Log Message: ----------- fixed ant mistakes Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/conf/flybase.cfg phenote/trunk/conf/human.cfg Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2007-01-11 21:01:52 UTC (rev 281) +++ phenote/trunk/build.xml 2007-01-11 21:11:32 UTC (rev 282) @@ -376,19 +376,11 @@ <!-- todo do all jars not just phenote - take out -signed --> <!-- depends on sym link phenote-webstart and env var PHENOTE_VERSION --> <!-- target name="build-webstart" depends="build-sign-jars,webstart"/ --> - <target name="build-webstart" depends="build-all,jar,webstart,sign-webstart-jars"/ > + <target name="build-webstart" depends="build-all,jar,webstart,sign-webstart-jars"/> - <target name="build-sign-jars" depends="build-all,jar,sign-jars"/> + <!-- target name="build-sign-jars" depends="build-all,jar,sign-jars"/ --> - <target name="sign-jars-svn-jar-dir-take-this-out-perhaps"> - <signjar keystore="plumpkey" alias="signFiles" - storepass="plumper" keypass="plumper"> - <fileset dir="${lib}"> - <include name="*.jar"/> - </fileset> - </signjar> - </target> <target name="sign-jars-svn-jar-dir-take-this-out-perhaps"> Modified: phenote/trunk/conf/flybase.cfg =================================================================== --- phenote/trunk/conf/flybase.cfg 2007-01-11 21:01:52 UTC (rev 281) +++ phenote/trunk/conf/flybase.cfg 2007-01-11 21:11:32 UTC (rev 282) @@ -1,5 +1,5 @@ -<phenote-configuration version="0.8" xmlns="phenote/config/xml" noNamespaceSchemaLocation="phenote-config.xsd"> +<phenote-configuration version="1.0" xmlns="phenote/config/xml" noNamespaceSchemaLocation="phenote-config.xsd"> <dataadapter name="phenosyntax"/> <dataadapter name="phenoxml"/> Modified: phenote/trunk/conf/human.cfg =================================================================== --- phenote/trunk/conf/human.cfg 2007-01-11 21:01:52 UTC (rev 281) +++ phenote/trunk/conf/human.cfg 2007-01-11 21:11:32 UTC (rev 282) @@ -1,5 +1,5 @@ -<phenote-configuration version="0.9" xmlns="phenote/config/xml"> +<phenote-configuration version="1.0" xmlns="phenote/config/xml"> <dataadapter name="phenosyntax"/> <dataadapter name="phenoxml"/> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2007-01-11 21:49:45
|
Revision: 280 http://svn.sourceforge.net/obo/?rev=280&view=rev Author: mgibson Date: 2007-01-11 12:59:18 -0800 (Thu, 11 Jan 2007) Log Message: ----------- ant doing signing of webstart jars instead of svn jars Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/src/java/phenote/gui/TermInfo.java Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2007-01-10 21:50:31 UTC (rev 279) +++ phenote/trunk/build.xml 2007-01-11 20:59:18 UTC (rev 280) @@ -375,11 +375,13 @@ <!-- todo do all jars not just phenote - take out -signed --> <!-- depends on sym link phenote-webstart and env var PHENOTE_VERSION --> - <target name="build-webstart" depends="build-sign-jars,webstart"/> + <!-- target name="build-webstart" depends="build-sign-jars,webstart"/ --> + <target name="build-webstart" depends="build-all,jar,webstart,sign-webstart-jars"/ > <target name="build-sign-jars" depends="build-all,jar,sign-jars"/> - <target name="sign-jars"> + + <target name="sign-jars-svn-jar-dir-take-this-out-perhaps"> <signjar keystore="plumpkey" alias="signFiles" storepass="plumper" keypass="plumper"> <fileset dir="${lib}"> @@ -388,6 +390,16 @@ </signjar> </target> + + <target name="sign-jars-svn-jar-dir-take-this-out-perhaps"> + <signjar keystore="plumpkey" alias="signFiles" + storepass="plumper" keypass="plumper"> + <fileset dir="${lib}"> + <include name="*.jar"/> + </fileset> + </signjar> + </target> + <!-- need to test if PHENOTE_VERSION is defined - possible?? --> <target name="webstart"> @@ -403,6 +415,15 @@ </copy> </target> + <target name="sign-webstart-jars"> + <signjar keystore="plumpkey" alias="signFiles" + storepass="plumper" keypass="plumper"> + <fileset dir="phenote-webstart/${env.PHENOTE_VERSION}/jars"> + <include name="*.jar"/> + </fileset> + </signjar> + </target> + <target name="webstart-just-phenote-jar" depends="build-all,jar"> <signjar jar="${lib}/phenote.jar" keystore="plumpkey" alias="signFiles" storepass="plumper" keypass="plumper"/> Modified: phenote/trunk/src/java/phenote/gui/TermInfo.java =================================================================== --- phenote/trunk/src/java/phenote/gui/TermInfo.java 2007-01-10 21:50:31 UTC (rev 279) +++ phenote/trunk/src/java/phenote/gui/TermInfo.java 2007-01-11 20:59:18 UTC (rev 280) @@ -216,59 +216,3 @@ // //previousOboClass = currentOboClass; // } // JEditorPane allows for html formatting - bold... but doesnt do word wrap - bummer! - // as far as i can tell - // would have to explicitly put <br> in text. can also do hyperlinks! - // for now just doing JTextArea - // do this more generically? some sort of controller? -// CompletionListListener l = new CompletionListListener(); -// termPanel.getEntityComboBox().addCompletionListListener(l); -// termPanel.getPatoComboBox().addCompletionListListener(l); -// if (termPanel.hasLumpComboBox()) -// termPanel.getLumpComboBox().addCompletionListListener(l); - - // ..... BrowserLauncher2? webstart BasicService? config browser... - // somehow distinguish local links from non local?? - // look for localhost? - - // set up localhost servlet? or just pick out text from url? - // hmmmmm...... -// private boolean isPhenoteLink(HyperlinkEvent e) { -// return e.getURL() == null && e.getDescription().startsWith(PHENOTE_LINK_PREFIX); -// } - -// String desc = e.getDescription(); -// if (desc == null || desc.equals("")) return; -// String id = getIdFromDescription(desc); - -// private String getIdFromDescription(String desc) { -// return desc.substring(PHENOTE_LINK_PREFIX.length()); -// } - -// /** Listens for completion list selection (via moouse over) and populates -// term info with term selected -- this is pase - replaced by -// TermSelectionEvent/Listener */ -// private class CompletionListListener implements ListSelectionListener { -// public void valueChanged(ListSelectionEvent e) { -// //int index = e.getFirstIndex(); -// Object source = e.getSource(); -// // hate to cast but it is handy here... and it is in fact a JList -// //System.out.println("TI got sel - src: "+source.getClass()+" list? "+(source instanceof javax.swing.JList)); -// if (!(source instanceof JList)) { -// System.out.println("source of combo box mouse over is not JList "+ -// source.getClass()); -// return; -// } -// JList jList = (JList)source; -// Object selectedValue = jList.getSelectedValue(); -// if (selectedValue == null) -// return; -// //System.out.println("sel val "+selectedValue.getClass()+" name "+selectedValue); -// // the selected item should be an OBOClass -// if (!(selectedValue instanceof OBOClass)) { -// System.out.println("selected completion term is not obo class " -// +selectedValue.getClass()); -// return; -// } -// OBOClass oboClass = (OBOClass)selectedValue; -// setTextFromOboClass(oboClass); -// } -// } // end of CompletionListListener inner class This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2007-01-12 20:06:28
|
Revision: 287 http://svn.sourceforge.net/obo/?rev=287&view=rev Author: mgibson Date: 2007-01-12 12:06:28 -0800 (Fri, 12 Jan 2007) Log Message: ----------- hmmm Modified Paths: -------------- phenote/trunk/build.xml phenote/trunk/doc/phenote-website/phenote-human.jnlp Modified: phenote/trunk/build.xml =================================================================== --- phenote/trunk/build.xml 2007-01-12 19:55:16 UTC (rev 286) +++ phenote/trunk/build.xml 2007-01-12 20:06:28 UTC (rev 287) @@ -396,20 +396,25 @@ <!-- need to test if PHENOTE_VERSION is defined - possible?? --> - <target name="webstart"> + <target name="webstart" depends="copy-jnlps"> <echo message="Env Var PHENOTE VERSION is set to ${env.PHENOTE_VERSION}" /> <copy todir="phenote-webstart"> <fileset file="doc/phenote-website/*.html"/> </copy> <mkdir dir="phenote-webstart/${env.PHENOTE_VERSION}"/> - <copy todir="phenote-webstart/${env.PHENOTE_VERSION}"> - <fileset file="doc/phenote-website/*.jnlp"/> - </copy> <copy todir="phenote-webstart/${env.PHENOTE_VERSION}/jars"> <fileset file="${lib}/*.jar"/> </copy> </target> + <target name="copy-jnlps"> + <echo message="Env Var PHENOTE VERSION is set to ${env.PHENOTE_VERSION}" /> + <copy todir="phenote-webstart/${env.PHENOTE_VERSION}"> + <fileset file="doc/phenote-website/*.jnlp"/> + </copy> + </target> + + <target name="sign-webstart-jars"> <signjar keystore="plumpkey" alias="signFiles" storepass="plumper" keypass="plumper"> @@ -420,10 +425,10 @@ </target> <target name="webstart-just-phenote-jar" depends="build-all,jar"> - <signjar jar="${lib}/phenote.jar" keystore="plumpkey" alias="signFiles" - storepass="plumper" keypass="plumper"/> <copy file="${lib}/phenote.jar" todir="phenote-webstart/${env.PHENOTE_VERSION}/jars"/> + <signjar jar="phenote-webstart/${env.PHENOTE_VERSION}/jars/phenote.jar" keystore="plumpkey" alias="signFiles" + storepass="plumper" keypass="plumper"/> </target> Modified: phenote/trunk/doc/phenote-website/phenote-human.jnlp =================================================================== --- phenote/trunk/doc/phenote-website/phenote-human.jnlp 2007-01-12 19:55:16 UTC (rev 286) +++ phenote/trunk/doc/phenote-website/phenote-human.jnlp 2007-01-12 20:06:28 UTC (rev 287) @@ -34,8 +34,8 @@ <jar href="jars/phenoteconfigbeans.jar" /> <jar href="jars/tomcat-servlet.jar" /> <jar href="jars/xbean.jar" /> - <jar href="jars/te-common.jar" /> - <jar href="jars/log4j-1.2.13.jar" /> + <jar href="jars/te-common.jar" /> + <jar href="jars/log4j-1.2.13.jar" /> </resources> <application-desc main-class="phenote.main.Phenote"> <argument>-c</argument> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mg...@us...> - 2007-01-16 21:25:47
|
Revision: 292 http://svn.sourceforge.net/obo/?rev=292&view=rev Author: mgibson Date: 2007-01-16 13:24:30 -0800 (Tue, 16 Jan 2007) Log Message: ----------- dichty -> dicty Modified Paths: -------------- phenote/trunk/doc/phenote-website/phenote.html phenote/trunk/src/java/phenote/main/PhenoteVersion.java Modified: phenote/trunk/doc/phenote-website/phenote.html =================================================================== --- phenote/trunk/doc/phenote-website/phenote.html 2007-01-16 20:53:57 UTC (rev 291) +++ phenote/trunk/doc/phenote-website/phenote.html 2007-01-16 21:24:30 UTC (rev 292) @@ -2,194 +2,276 @@ <html> <head> + + <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type"> + + <title>Phenote</title> </head> <body> + <h1 style="text-align: left;"><span style="font-weight: bold;"></span>Phenote<br> + </h1> + <br> + Phenote is a tool to annotate phenotypes using the Entity Quality paradigm. It takes advantage of ontologies. It uses term completion to allow curators quick access to the ontology terms they want to use. <br> + <br> + <a href="1.0/phenote-flybase.jnlp">Phenote 1.0 for fly</a><br> + <br> + <a href="1.0/phenote-zfin.jnlp">Phenote 1.0 for zfin</a><br> + <br> + <a href="1.0/phenote-zfin.jnlp"></a><a href="1.0/phenote-human.jnlp">Phenote 1.0 for human</a><br> + <br> + To be clear the above webstart links for zfin & fly were made via configuration not hard wired code. Thus one could in theory configure phenote for ones own purposes.<br> + <br> + Recent addditions include the ability to add any field you like, post compose terms, bulk update, undo, spring framework, and synonyms now are shown in the completion list.<br> + <br> + Zebrafish requires components of phenote(to plug into their non-public website), not a full web app. Here is a proof of concept of some of those components:<br> + <br> + <a href="http://reaper.lbl.gov/phenote/html/ncbo.html">Webby Phenote(components used by Zfin)</a><br> + <br> + Webby phenote is a collaboration with Sohel Merchant at dictyBase. Here is what they have done:<br> + <br> -<a href="http://165.124.152.194/db/cgi-bin/dictyBase/curation/phenotypeCuration.pl">DichtyBase + +<a href="http://165.124.152.194/db/cgi-bin/dictyBase/curation/phenotypeCuration.pl">DictyBase webby phenote</a><br> + <br> + <br> + I am doing these releases to get feedback. Please report any bugs (ideally through the <a href="https://sourceforge.net/tracker/?group_id=76834&atid=887913">bug tracker</a>) and let me know what you think (mg...@fr...).<br> + <br> + <h4>Phenote links:<br> + </h4> + <a href="https://lists.sourceforge.net/lists/listinfo/obo-phenote">Phenote email list</a><br> + <a href="https://sourceforge.net/tracker/?group_id=76834&atid=887913">Phenote bug tracker</a><br> + <a href="https://lists.sourceforge.net/lists/listinfo/obo-phenote-bug-tracker">Bug tracker email list</a><br> + <a href="https://sourceforge.net/svn/?group_id=76834">Phenote source code (obo sourceforge svn)</a><br> + <a href="https://lists.sourceforge.net/lists/listinfo/obo-svn-commit">Phenote svn commit email list</a><br> -<a href="http://wiki.dictybase.org/dictywiki/index.php/Phenotype_Curation_Tool_Documentation#Usage">Dichty + +<a href="http://wiki.dictybase.org/dictywiki/index.php/Phenotype_Curation_Tool_Documentation#Usage">Dicty webby phenote wiki developer docs</a><br> + <a href="http://www.bioontology.org/wiki-internal/index.php/Phenotype_Annotation_Tool">Phenote ncbo internal wiki (ncbo folk only)</a><br> + <br> + <a href="phenote-release-notes.html">Phenote Release Notes and old webstart releases</a><br> + <br> + If the Phenote webstart link fails to do anything, then there are probably problems with webstart and/or java(has to be jdk 1.5). Take a look at my <a href="webstart-troubleshooting.html">webstart troubleshooting</a><br> + page.<br> + <br> + Click here for <a href="phenote-java-requirements.html">phenote java requirements</a><br> + <br> + <br> + <br> + Old releases: <br> + <br> + <a href="0.9/phenote-flybase.jnlp">Phenote 0.9 for fly</a><br> + <a href="0.9/phenote-zfin.jnlp">Phenote (standalone) 0.9 for zfin</a><br> + <br> + <a href="0.8/phenote-flybase.jnlp">Phenote 0.8 for fly.</a><br> + <a href="0.8/phenote-zfin.jnlp">Phenote (standalone) 0.8 for zfin</a><br> + <br> + <a href="0.7/phenote-flybase.jnlp">Phenote 0.7 for fly.</a><br> + <a href="0.7/phenote-zfin.jnlp">Phenote (standalone) 0.7 for zfin</a><br> + <br> + <a href="0.6/phenote-flybase.jnlp">Phenote 0.6 with fly anatomy</a><br> + <br> + <a href="0.6/phenote-zfin.jnlp">Phenote 0.6 with zebrafish anatomy</a><br> + <br> + <a href="0.5/phenote-flybase.jnlp">Phenote 0.5 webstart for FlyBase</a><br> + <br> + <a href="0.5/phenote-zfin.jnlp">Phenote 0.5 webstart for ZFIN</a><br> + <br> + <a href="0.4/phenote-flybase.jnlp">Phenote 0.4 webstart for FlyBase</a><br> + <br> + <a href="0.4/phenote-zfin.jnlp">Phenote 0.4 webstart for ZFIN</a><br> + <br> + <a href="0.3.1/phenote-webstart.jnlp">Phenote for CToL group (0.3.1)</a> (a special release for the CToL group that uses fish taxonomy)<br> + <br> + <a href="0.3/phenote-webstart.jnlp">Phenote 0.3</a><br> + <br> + <a href="0.2/phenote-webstart.jnlp">Phenote 0.2</a><br> + <br> + <a href="0.1/phenote-webstart.jnlp">Phenote 0.1</a><br> + <br> + <br> + </body> </html> Modified: phenote/trunk/src/java/phenote/main/PhenoteVersion.java =================================================================== --- phenote/trunk/src/java/phenote/main/PhenoteVersion.java 2007-01-16 20:53:57 UTC (rev 291) +++ phenote/trunk/src/java/phenote/main/PhenoteVersion.java 2007-01-16 21:24:30 UTC (rev 292) @@ -6,7 +6,7 @@ //private static final float MAJOR_VERSION_NUM = 0.8f; //private static final float SUB_VERSION_NUM = .3f; - private static final String VERSION = "1.0.1 dev"; // ?? + private static final String VERSION = "1.0.2 dev"; // ?? // type is "dev" or "release" //private static final String type = " dev"; // "release" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ba...@us...> - 2007-01-22 19:23:45
|
Revision: 303 http://svn.sourceforge.net/obo/?rev=303&view=rev Author: balhoff Date: 2007-01-22 11:23:37 -0800 (Mon, 22 Jan 2007) Log Message: ----------- Added file adapter for exporting phenotypes to a NEXUS file. This requires the use of PATO with attribute and value slims. The adapter does not import NEXUS files. Modified Paths: -------------- phenote/trunk/obo-files/quality.obo phenote/trunk/src/java/phenote/config/Config.java Added Paths: ----------- phenote/trunk/src/java/phenote/dataadapter/nexus/ phenote/trunk/src/java/phenote/dataadapter/nexus/NEXUSAdapter.java Modified: phenote/trunk/obo-files/quality.obo =================================================================== --- phenote/trunk/obo-files/quality.obo 2007-01-20 03:18:08 UTC (rev 302) +++ phenote/trunk/obo-files/quality.obo 2007-01-22 19:23:37 UTC (rev 303) @@ -1,10 +1,13 @@ format-version: 1.0 -date: 28:11:2006 13:58 +date: 22:01:2007 16:16 saved-by: George Gkoutos -auto-generated-by: OBO-Edit 1.002 +auto-generated-by: OBO-Edit 1.100-beta16 +subsetdef: abnormal_slim "Abnormal/normal slim" subsetdef: absent_slim "Absent/present slim" -subsetdef: abnormal_slim "Abnormal/normal slim" +subsetdef: attribute_slim "Attribute slim" +subsetdef: value_slim "Value slim" default-namespace: quality +namespace-id-rule: * ID:$sequence(7,0,2147483647)$ [Term] id: PATO:0000000 @@ -14,7 +17,8 @@ [Term] id: PATO:0000001 name: quality -def: "A dependent entity that\ninheres in a bearer by virtue of how the bearer is related to other entities." [PATO :GVG] +def: "A dependent entity that inheres in a bearer by virtue of how the bearer is related to other entities." [PATO :GVG] +subset: attribute_slim [Term] id: PATO:0000002 @@ -30,6 +34,7 @@ id: PATO:0000004 name: mobility def: "A quality of moving freely." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -51,6 +56,7 @@ id: PATO:0000008 name: speed/velocity def: "A physical quality inhering in an object by virtue of the rate of change of its position." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -66,6 +72,7 @@ [Term] id: PATO:0000011 name: age +subset: attribute_slim is_a: PATO:0000165 ! time [Term] @@ -82,46 +89,54 @@ id: PATO:0000014 name: color def: "A composite chromatic quality composed of hue, saturation and intensity parts." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000015 name: color hue def: "a chromatic scalar-circular quality inhering in an object that manifests in an observer by virtue of the dominant wavelength of the visible light; may be subject to fiat divisions, typically into 7 or 8 spectra" [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000016 name: color brightness def: "A scalar optical quality which obtains by the bearer producing the effects of light emittance in an observer." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001300 ! optical quality [Term] id: PATO:0000017 name: color saturation def: "a scalar chromatic quality that manifests by virtue of the range of wavelengths in perceived light." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000018 name: fluorescence def: "Luminosity in which the bearer emits longer wavelength light following the absorption of shorter wavelength radiation; fluorescence is common with aromatic compounds with several rings joined together." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0001296 ! luminosity [Term] id: PATO:0000019 name: color pattern -is_obsolete: true +subset: attribute_slim +is_a: PATO:0001301 ! chromatic property [Term] id: PATO:0000020 name: relative color +subset: attribute_slim is_a: PATO:0001300 ! optical quality [Term] id: PATO:0000021 name: compatibility def: "A quality of having or lacking the ability harmonious coexistence." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -142,7 +157,9 @@ [Term] id: PATO:0000025 name: composition -def: "A monadic quality of continuant inhering in an object by virtue of the quantities or relative ratios of subparts of the inhering entity; for example calcium composition (which may inhere in bone), haemoglobin composition (which may inhere in blood)" [PATO :GVG] +def: "A monadic quality of continuant inhering in an object by virtue of the quantities or relative ratios of subparts of the inhering entity." [PATO :GVG] +comment: For example calcium composition (which may inhere in bone), haemoglobin composition (which may inhere in blood). +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -184,6 +201,7 @@ id: PATO:0000033 name: concentration def: "A physical quality inhering in a substance by \nvirtue of the amount of it there is mixed with another substance." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -205,6 +223,7 @@ id: PATO:0000037 name: consistency def: "A physical quality that inheres in a continuant by\nvirtue of density, firmness, or viscosity." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -216,12 +235,14 @@ id: PATO:0000039 name: direction def: "The orientation of a line in space." [: "http://thesaurus.maths.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000040 name: distance def: "The extent of space between two objects or places." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -238,12 +259,14 @@ id: PATO:0000043 name: flavor def: "A relational quality inhering in an object or the molecules of an object, in which the molecules are perceived by a taste and odorant receptors." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001238 ! relational quality of continuant [Term] id: PATO:0000044 name: frequency def: "A physical quality which inhers to the bearer by virtue of the number of repetitive actions in a particular time." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -260,41 +283,48 @@ id: PATO:0000047 name: biological sex def: "A monadic quality of continuant inhering in an organism by virtue of its ability to undergo sexual reproduction in order to differentiate the individuals or types involved." [MGED:MGED] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000048 name: hardness def: "A physical quality inhering in a bearer as the constant of proportionality of the force on its elastic body to its body's extension." [: "http://thesaurus.maths.org/"] +subset: attribute_slim related_synonym: "stiffness" [] is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000049 name: intensity +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000050 name: life span def: "A time quality which is the expected maximum age." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0000165 ! time [Term] id: PATO:0000051 name: morphology def: "A quality inhering in the bearer by virtue of its size, shape and structure" [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000052 name: shape -def: "A morphology quality inhering in a bearer by virtue of the ratios of distances between its features (points, edges, surfaces and also holes etc). " [PATO :GVG] +def: "A morphology quality inhering in a bearer by virtue of the ratios of distances between its features (points, edges, surfaces and also holes etc)." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000051 ! morphology [Term] id: PATO:0000053 name: count +subset: attribute_slim is_a: PATO:0001226 ! quantitative [Term] @@ -310,28 +340,33 @@ [Term] id: PATO:0000056 name: nutritional +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000057 name: occurrence +subset: attribute_slim is_a: PATO:0001226 ! quantitative [Term] id: PATO:0000058 name: odor -def: "A relational quality inhering in an object by virtue of the molecules being are aerially dispersed and perceived by an odorant receptor. " [XX:<new dbxref>] +def: "A relational quality inhering in an object by virtue of the molecules being are aerially dispersed and perceived by an odorant receptor." [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001238 ! relational quality of continuant [Term] id: PATO:0000059 name: parental type +subset: attribute_slim is_a: PATO:0000047 ! biological sex [Term] id: PATO:0000060 name: pattern def: "A monadic quality of continuant defined by the mathematic properties of the relative position of subparts" [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -342,7 +377,8 @@ [Term] id: PATO:0000062 name: sleep pattern -is_a: PATO:0000186 ! behavioral quality +subset: attribute_slim +is_a: PATO:0001530 ! behavioral quality of occurent [Term] id: PATO:0000063 @@ -363,6 +399,7 @@ id: PATO:0000066 name: pilosity def: "A quality of having hair." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -373,21 +410,25 @@ [Term] id: PATO:0000068 name: qualitative +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000069 name: deviation(from_normal) +subset: attribute_slim is_a: PATO:0000068 ! qualitative [Term] id: PATO:0000070 name: presence +subset: attribute_slim is_a: PATO:0000068 ! qualitative [Term] id: PATO:0000071 name: relative_quantity +subset: attribute_slim is_a: PATO:0001226 ! quantitative [Term] @@ -419,12 +460,14 @@ id: PATO:0000077 name: response def: "A quality inhering in a bearer by virtue of \nits reaction to a stimulus or an agent." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000078 name: rhythm -is_a: PATO:0001237 ! monadic quality of continuant +subset: attribute_slim +is_a: PATO:0001239 ! monadic quality of occurrent [Term] id: PATO:0000079 @@ -434,24 +477,26 @@ [Term] id: PATO:0000080 name: amplitude -def: "A physical quality inhering in a bearer by \nvirtue of the size of its maximum displacement from the 'normal' position, when periodic motion is taking place" [: "http://thesaurus.maths.org/"] -is_a: PATO:0000078 ! rhythm -is_a: PATO:0001018 ! physical quality +def: "A physical monadic quality of occurrent quality inhering in a bearer by virtue of the size of its maximum displacement from the 'normal' position, when periodic motion is taking place." [thesaurus.maths:thesaurus.maths "http://thesaurus.maths.org/"] +subset: attribute_slim +is_a: PATO:0001239 ! monadic quality of occurrent [Term] id: PATO:0000081 name: period -is_a: PATO:0000078 ! rhythm +subset: attribute_slim is_a: PATO:0000165 ! time [Term] id: PATO:0000082 name: persistence +subset: attribute_slim is_a: PATO:0000078 ! rhythm [Term] id: PATO:0000083 name: phase +subset: attribute_slim is_a: PATO:0000078 ! rhythm [Term] @@ -463,6 +508,7 @@ id: PATO:0000085 name: sensitivity def: "A relational quality of continuant inhering in an entity by virtue of its propensity to respond to stimulation." [PATO:GVG] +subset: attribute_slim is_a: PATO:0001238 ! relational quality of continuant [Term] @@ -623,7 +669,8 @@ [Term] id: PATO:0000117 name: size -def: "A morphology quality inhering in a bearer by virtue of its physical magnitude. " [WordNet :WordNet "wordnet.princeton.edu/"] +def: "A morphology quality inhering in a bearer by virtue of its physical magnitude." [WordNet :WordNet "wordnet.princeton.edu/"] +subset: attribute_slim is_a: PATO:0000051 ! morphology [Term] @@ -635,6 +682,7 @@ id: PATO:0000119 name: height def: "A physical quality which is equal to the vertical dimension of extension." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -651,6 +699,7 @@ id: PATO:0000122 name: length def: "A physical quality which is equal to the distance between two points." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -667,6 +716,7 @@ id: PATO:0000125 name: mass def: "A physical quality that inheres in a bearer in proportion to the amount of matter it contains." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -683,6 +733,7 @@ id: PATO:0000128 name: weight def: "A quality inhering in an object with mass near a gravitational body." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001035 ! force [Term] @@ -703,14 +754,15 @@ [Term] id: PATO:0000132 name: spatial +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000133 name: angle def: "A physical quality inhering in a figure or space formed by the junction of two lines or planes." [Wikipedia :Wikipedia "http://www.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0000132 ! spatial -is_a: PATO:0001018 ! physical quality [Term] id: PATO:0000134 @@ -725,12 +777,14 @@ [Term] id: PATO:0000136 name: closure +subset: attribute_slim is_a: PATO:0000132 ! spatial [Term] id: PATO:0000137 name: orientation def: "A quality of an object in which its \nlocation is defined by the angle between two axes, or an axis and another object" [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0000132 ! spatial [Term] @@ -747,12 +801,14 @@ id: PATO:0000140 name: placement def: "A spatial quality of the way in which something is placed" [PATO:gg] +subset: attribute_slim is_a: PATO:0000132 ! spatial [Term] id: PATO:0000141 name: structure -def: "A morphology quality inhering in a bearer by virtue of the relative position, shape, arrangements and connectivity of an organism's various parts; the pattern underlying its form.\n" [PATO :GVG] +def: "A morphology quality inhering in a bearer by virtue of the relative position, shape, arrangements and connectivity of an organism's various parts; the pattern underlying its form." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000051 ! morphology [Term] @@ -779,6 +835,7 @@ id: PATO:0000146 name: temperature def: "A physical quality of the thermal energy of a system." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -799,7 +856,8 @@ [Term] id: PATO:0000150 name: texture -def: "A morphology quality inhering in a bearer by virtue of the relative size and distribution of its surface elements or the representation or invention of the appearance of its surface. \n" [PATO :GVG] +def: "A morphology quality inhering in a bearer by virtue of the relative size and distribution of its surface elements or the representation or invention of the appearance of its surface." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000051 ! morphology [Term] @@ -811,6 +869,7 @@ id: PATO:0000152 name: threshold def: "A quality inhering in a bearer by virtue of its sensitivity towards a fixed location or value where a change is observed; upper limit." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -831,7 +890,8 @@ [Term] id: PATO:0000156 name: temporal -is_a: PATO:0001237 ! monadic quality of continuant +subset: attribute_slim +is_a: PATO:0001239 ! monadic quality of occurrent [Term] id: PATO:0000157 @@ -841,6 +901,7 @@ [Term] id: PATO:0000158 name: incidence +subset: attribute_slim is_a: PATO:0000156 ! temporal [Term] @@ -856,6 +917,7 @@ [Term] id: PATO:0000161 name: rate +subset: attribute_slim is_a: PATO:0000156 ! temporal [Term] @@ -877,6 +939,7 @@ id: PATO:0000165 name: time def: "A quality in which events occur in sequence" [XX:<new dbxref>] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -887,6 +950,7 @@ [Term] id: PATO:0000167 name: bouts +subset: attribute_slim is_a: PATO:0000165 ! time [Term] @@ -898,6 +962,7 @@ id: PATO:0000169 name: viability def: "A quality inhering in a bearer or a population by virtue of the bearer's ability or inability to survive and develop normally or the number of surviving individuals in a given population." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -978,28 +1043,33 @@ [Term] id: PATO:0000185 name: balance -is_a: PATO:0001237 ! monadic quality of continuant +subset: attribute_slim +is_a: PATO:0001530 ! behavioral quality of occurent [Term] id: PATO:0000186 name: behavioral quality +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0000187 name: consumption -is_a: PATO:0001237 ! monadic quality of continuant +subset: attribute_slim +is_a: PATO:0001240 ! relational quality of occurrent [Term] id: PATO:0000188 name: coordination def: "A quality of having or lacking skilful and effective interaction of movement." [PATO :GVG] -is_a: PATO:0001237 ! monadic quality of continuant +subset: attribute_slim +is_a: PATO:0001530 ! behavioral quality of occurent [Term] id: PATO:0000189 name: discrimination def: "A quality of perceiving differences between two or more stimuli." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -1360,6 +1430,7 @@ [Term] id: PATO:0000261 name: maturity +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] @@ -1420,12 +1491,14 @@ [Term] id: PATO:0000273 name: fecundity -is_obsolete: true +subset: attribute_slim +is_a: PATO:0001434 ! reproductive quality [Term] id: PATO:0000274 name: fertility def: "A quality of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001434 ! reproductive quality [Term] @@ -1435,13 +1508,16 @@ [Term] id: PATO:0000276 -name: litter size -is_obsolete: true +name: brood size +subset: attribute_slim +related_synonym: "litter size" [] +is_a: PATO:0001496 ! brood quality [Term] id: PATO:0000277 name: female fertility def: "A fertility quality of the female of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000274 ! fertility [Term] @@ -1453,6 +1529,7 @@ id: PATO:0000279 name: male fertility def: "A fertility quality of the male of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000274 ! fertility [Term] @@ -1544,6 +1621,7 @@ id: PATO:0000297 name: arrested def: "A duration in which the end point is shorted before natural end point (prematurely finishing)." [XX:<new dbxref>] +subset: value_slim related_synonym: "incomplete" [] is_a: PATO:0001309 ! duration @@ -1556,12 +1634,15 @@ id: PATO:0000299 name: mobile def: "A mobility quality of being incapable to move freely." [PATO :GVG] +subset: value_slim is_a: PATO:0000004 ! mobility [Term] id: PATO:0000300 name: immobile def: "A mobility quality of being capable to move freely." [PATO :GVG] +subset: value_slim +related_synonym: "fixed" [] is_a: PATO:0000004 ! mobility [Term] @@ -1578,12 +1659,14 @@ id: PATO:0000303 name: fast speed def: "A speed which is relative high." [PATO :GVG] +subset: value_slim is_a: PATO:0000008 ! speed/velocity [Term] id: PATO:0000304 name: slow speed def: "A speed which is relative low." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0000008 ! speed/velocity [Term] @@ -1604,11 +1687,13 @@ [Term] id: PATO:0000308 name: old +subset: value_slim is_a: PATO:0000011 ! age [Term] id: PATO:0000309 name: young +subset: value_slim is_a: PATO:0000011 ! age [Term] @@ -1650,46 +1735,54 @@ id: PATO:0000317 name: black def: "A color that lacks any hues as parts." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000318 name: blue -def: "A color hue with low wavelength of that portion of the visible spectrum lying between green and indigo, evoked in the human observer by radiant energy with wavelengths of approximately 420 to 490 nanometers;" [Dictionary:http\://dictionary.reference.com/] +def: "A color hue with low wavelength of that portion of the visible spectrum lying between green and indigo, evoked in the human observer by radiant energy with wavelengths of approximately 420 to 490 nanometers." [Dictionary:http\://dictionary.reference.com/] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000319 name: cyan +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000320 name: green def: "A color hue with medium-low wavelength of that portion of the visible spectrum lying between yellow and blue, evoked in the human observer by radiant energy with wavelengths of approximately 490 to 570 nanometers;" [Dictionary:http\://dictionary.reference.com/] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000321 name: magenta +subset: value_slim is_a: PATO:0000322 ! red [Term] id: PATO:0000322 name: red def: "A color hue with high wavelength of the long-wave end of the visible spectrum, evoked in the human observer by radiant energy with wavelengths of approximately 630 to 750 nanometers;" [Dictionary:http\://dictionary.reference.com/] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000323 name: white def: "An achromatic color of maximum lightness; the color of objects that reflect nearly all light of all visible wavelengths;" [Dictionary:http\://dictionary.reference.com/] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000324 name: yellow def: "A color hue with medium wavelength of that portion of the visible spectrum lying between orange and green, evoked in the human observer by radiant energy with wavelengths of approximately 570 to 590 nanometers" [Dictionary:http\://dictionary.reference.com/] +subset: value_slim is_a: PATO:0000014 ! color [Term] @@ -1705,11 +1798,13 @@ [Term] id: PATO:0000327 name: dark +subset: value_slim is_a: PATO:0000016 ! color brightness [Term] id: PATO:0000328 name: pale +subset: value_slim related_synonym: "dull" [] is_a: PATO:0000017 ! color saturation @@ -1722,11 +1817,13 @@ id: PATO:0000330 name: irregular def: "A physical quality inhering in a bearer by virtue of lacking pattern." [PATO :GVG] +subset: value_slim is_a: PATO:0000060 ! pattern [Term] id: PATO:0000331 name: discolored +subset: value_slim is_a: PATO:0000020 ! relative color [Term] @@ -1753,11 +1850,13 @@ [Term] id: PATO:0000336 name: colored +subset: value_slim is_a: PATO:0000020 ! relative color [Term] id: PATO:0000337 name: colorless +subset: value_slim is_a: PATO:0000020 ! relative color [Term] @@ -1794,12 +1893,14 @@ id: PATO:0000344 name: compatible def: "A compatibility quality of being capable of harmonious coexistence." [PATO :GVG] +subset: value_slim is_a: PATO:0000021 ! compatibility [Term] id: PATO:0000345 name: incompatible def: "A compatibility quality of being incapable of harmonious coexistence." [PATO :GVG] +subset: value_slim is_a: PATO:0000021 ! compatibility [Term] @@ -1901,18 +2002,21 @@ id: PATO:0000365 name: down def: "A direction from a higher to a lower point." [PATO :GVG] +subset: value_slim is_a: PATO:0000039 ! direction [Term] id: PATO:0000366 name: left def: "A direction that is similar to the direction of an object to the north when it faces east." [PATO :GVG] +subset: value_slim is_a: PATO:0000039 ! direction [Term] id: PATO:0000367 name: right def: "A direction that is similar to the direction of an object to the north when it faces west." [PATO :GVG] +subset: value_slim is_a: PATO:0000039 ! direction [Term] @@ -1929,6 +2033,7 @@ id: PATO:0000370 name: up def: "A direction from a lower to a higher point." [PATO :GVG] +subset: value_slim is_a: PATO:0000039 ! direction [Term] @@ -1950,12 +2055,14 @@ id: PATO:0000374 name: long distance def: "A distance which is greater relative to the normal or average." [PATO :GVG] +subset: value_slim is_a: PATO:0000040 ! distance [Term] id: PATO:0000375 name: short distance def: "A distance which is lesser relative to the normal or average." [PATO :GVG] +subset: value_slim is_a: PATO:0000040 ! distance [Term] @@ -1982,12 +2089,14 @@ id: PATO:0000380 name: frequent def: "A frequency which is relative high." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0000044 ! frequency [Term] id: PATO:0000381 name: infrequent def: "A frequency which is relative low." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0000044 ! frequency [Term] @@ -1999,12 +2108,14 @@ id: PATO:0000383 name: female def: "A biological sex quality inhering in an individual that only produces gametes that can be fertilised by male gamates." [MGED:MGED] +subset: value_slim is_a: PATO:0000047 ! biological sex [Term] id: PATO:0000384 name: male def: "A biological sex quality inhering in an individual whose sex organs contain only male gametes." [MGED:MGED] +subset: value_slim is_a: PATO:0000047 ! biological sex [Term] @@ -2016,12 +2127,14 @@ id: PATO:0000386 name: hard def: "A hardness quality of being rigid and resistant to pressure." [PATO :GVG] +subset: value_slim is_a: PATO:0000048 ! hardness [Term] id: PATO:0000387 name: soft -def: "A hardness quality of giving little resistance to pressure " [PATO :GVG] +def: "A hardness quality of giving little resistance to pressure" [PATO :GVG] +subset: value_slim is_a: PATO:0000048 ! hardness [Term] @@ -2057,16 +2170,19 @@ [Term] id: PATO:0000394 name: mild +subset: value_slim is_a: PATO:0000049 ! intensity [Term] id: PATO:0000395 name: moderate +subset: value_slim is_a: PATO:0000049 ! intensity [Term] id: PATO:0000396 name: severe +subset: value_slim is_a: PATO:0000049 ! intensity [Term] @@ -2097,27 +2213,33 @@ [Term] id: PATO:0000402 name: branched +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000403 name: cleft +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000404 name: coiled +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000405 name: curled -def: "A shape quality of having parallel chains in undulate fashion on the border." [XX:<new dbxref>] +def: "A shape quality of having parallel chains in undulate fashion on the border." [PATO:] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000406 name: curved +def: "A shape quality inhering in a bearer by virtue of having or marked by a curve or smoothly rounded bend" [WordNet :WordNet "http://wordnet.princeton.edu/"] +subset: value_slim related_synonym: "curled" [] is_a: PATO:0000052 ! shape @@ -2125,46 +2247,55 @@ id: PATO:0000407 name: flat def: "A shape lacking depth." [PATO :GVG] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000408 name: globular +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000409 name: oblate +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000410 name: pinnate +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000411 name: round +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000412 name: shrunken +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000413 name: square +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000414 name: unbranched +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000415 name: uncoiled +subset: value_slim is_a: PATO:0000052 ! shape [Term] @@ -2185,11 +2316,13 @@ [Term] id: PATO:0000419 name: decreased number +subset: value_slim is_a: PATO:0000053 ! count [Term] id: PATO:0000420 name: increased number +subset: value_slim is_a: PATO:0000053 ! count [Term] @@ -2200,11 +2333,13 @@ [Term] id: PATO:0000422 name: auxotroph +subset: value_slim is_a: PATO:0000056 ! nutritional [Term] id: PATO:0000423 name: prototroph +subset: value_slim is_a: PATO:0000056 ! nutritional [Term] @@ -2220,21 +2355,25 @@ [Term] id: PATO:0000426 name: interrupted +subset: value_slim is_a: PATO:0000057 ! occurrence [Term] id: PATO:0000427 name: recurrent +subset: value_slim is_a: PATO:0000057 ! occurrence [Term] id: PATO:0000428 name: sporadic +subset: value_slim is_a: PATO:0000057 ! occurrence [Term] id: PATO:0000429 name: uninterrupted +subset: value_slim is_a: PATO:0000057 ! occurrence [Term] @@ -2255,11 +2394,13 @@ [Term] id: PATO:0000433 name: paternal +subset: value_slim is_a: PATO:0000059 ! parental type [Term] id: PATO:0000434 name: maternal +subset: value_slim is_a: PATO:0000059 ! parental type [Term] @@ -2281,7 +2422,9 @@ id: PATO:0000438 name: invariant def: "The state of not having or exhibiting variation." [Dictionary:http\://dictionary.reference.com/] +subset: value_slim related_synonym: "constant" [] +exact_synonym: "uniform" [] is_a: PATO:0001303 ! variability [Term] @@ -2293,21 +2436,25 @@ id: PATO:0000440 name: regular def: "A physical quality inhering in a bearer by virtue of having pattern." [PATO :GVG] +subset: value_slim is_a: PATO:0000060 ! pattern [Term] id: PATO:0000441 name: repetitive +subset: value_slim is_a: PATO:0000057 ! occurrence [Term] id: PATO:0000442 name: insomnia +subset: value_slim is_a: PATO:0000062 ! sleep pattern [Term] id: PATO:0000443 name: narcolepsy +subset: value_slim is_a: PATO:0000062 ! sleep pattern [Term] @@ -2359,17 +2506,20 @@ id: PATO:0000453 name: glabrous def: "A pilosity quality of having no hairs, projections, or pubescence" [PATO :GVG] +subset: value_slim is_a: PATO:0000066 ! pilosity [Term] id: PATO:0000454 name: hairy def: "A pilosity quality of being covered with hair or hairlike projections" [PATO :GVG] +subset: value_slim is_a: PATO:0000066 ! pilosity [Term] id: PATO:0000455 name: pubescent +subset: value_slim is_a: PATO:0000261 ! maturity [Term] @@ -2395,33 +2545,38 @@ [Term] id: PATO:0000460 name: abnormal +subset: abnormal_slim +subset: value_slim related_synonym: "aberrant" [] related_synonym: "atypical" [] related_synonym: "defective" [] is_a: PATO:0000069 ! deviation(from_normal) -subset: abnormal_slim [Term] id: PATO:0000461 name: normal +subset: abnormal_slim +subset: value_slim related_synonym: "average" [] is_a: PATO:0000069 ! deviation(from_normal) -subset: abnormal_slim [Term] id: PATO:0000462 name: absent +subset: absent_slim +subset: value_slim is_a: PATO:0000070 ! presence -subset: absent_slim [Term] id: PATO:0000463 name: conspicuous +subset: value_slim is_a: PATO:0000070 ! presence [Term] id: PATO:0000464 name: inconspicuous +subset: value_slim is_a: PATO:0000070 ! presence [Term] @@ -2437,12 +2592,15 @@ [Term] id: PATO:0000467 name: present +subset: absent_slim +subset: value_slim is_a: PATO:0000070 ! presence -subset: absent_slim [Term] id: PATO:0000468 name: decreased +subset: value_slim +related_synonym: "reduced" [] is_a: PATO:0000071 ! relative_quantity [Term] @@ -2453,6 +2611,7 @@ [Term] id: PATO:0000470 name: increased +subset: value_slim is_a: PATO:0000071 ! relative_quantity [Term] @@ -2539,12 +2698,14 @@ id: PATO:0000487 name: responsive def: "A quality inhering in a bearer by virtue of \nthe presence of its reaction to a stimulus or an agent." [PATO :GVG] +subset: value_slim is_a: PATO:0000077 ! response [Term] id: PATO:0000488 name: unresponsive def: "A quality inhering in a bearer by virtue of \nthe lack of its reaction to a stimulus or an agent." [PATO :GVG] +subset: value_slim is_a: PATO:0000077 ! response [Term] @@ -2595,44 +2756,51 @@ [Term] id: PATO:0000498 name: prolonged period +subset: value_slim is_a: PATO:0000081 ! period [Term] id: PATO:0000499 name: shortened period +subset: value_slim is_a: PATO:0000081 ! period [Term] id: PATO:0000500 name: advanced +subset: value_slim is_a: PATO:0000083 ! phase [Term] id: PATO:0000501 name: dark phase +subset: value_slim is_a: PATO:0000083 ! phase [Term] id: PATO:0000502 name: delayed -def: "A duration in which process ends before natural\nstart point." [XX:<new dbxref>] +def: "A duration in which process ends before natural start point." [PATO:GVG] +subset: value_slim related_synonym: "late" [] -is_a: PATO:0000083 ! phase is_a: PATO:0001309 ! duration [Term] id: PATO:0000503 name: light phase +subset: value_slim is_a: PATO:0000083 ! phase [Term] id: PATO:0000504 name: arrhythmic +subset: value_slim is_a: PATO:0000078 ! rhythm [Term] id: PATO:0000505 name: rhythmic +subset: value_slim is_a: PATO:0000078 ! rhythm [Term] @@ -2674,6 +2842,7 @@ id: PATO:0000513 name: insensitive def: "A quality of lacking sensitivity." [XX:<new dbxref>] +subset: value_slim related_synonym: "resistant" [] is_a: PATO:0000085 ! sensitivity @@ -2686,12 +2855,14 @@ id: PATO:0000515 name: tolerant def: "A resistance quality inhering in a bearer by virtue of its ability to tolarete or being insensitive to a stimulus." [PATO :GVG] +subset: value_slim is_a: PATO:0001046 ! resistance [Term] id: PATO:0000516 name: sensitive def: "A quality of having sensitivity." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0000085 ! sensitivity [Term] @@ -2961,12 +3132,14 @@ id: PATO:0000569 name: short height def: "A height which is relative high." [PATO :GVG] +subset: value_slim is_a: PATO:0000119 ! height [Term] id: PATO:0000570 name: tall height def: "A height which is relative small." [PATO :GVG] +subset: value_slim is_a: PATO:0000119 ! height [Term] @@ -2983,12 +3156,14 @@ id: PATO:0000573 name: long length def: "A length which is relative large." [XX:<new dbxref>] +subset: value_slim is_a: PATO:0000122 ! length [Term] id: PATO:0000574 name: short length def: "A length which is relative small." [XX:<new dbxref>] +subset: value_slim related_synonym: "shortened" [] related_synonym: "stubby" [] is_a: PATO:0000122 ! length @@ -3012,12 +3187,14 @@ id: PATO:0000578 name: large mass def: "A mass which is relative large." [PATO :GVG] +subset: value_slim is_a: PATO:0000125 ! mass [Term] id: PATO:0000579 name: small mass def: "A mass which is relative small." [PATO :GVG] +subset: value_slim is_a: PATO:0000125 ! mass [Term] @@ -3034,32 +3211,35 @@ id: PATO:0000582 name: heavy def: "A weight which is relative high." [PATO :GVG] +subset: value_slim is_a: PATO:0000128 ! weight [Term] id: PATO:0000583 name: light weight def: "A weight which is relative low." [PATO :GVG] +subset: value_slim is_a: PATO:0000128 ! weight [Term] id: PATO:0000584 name: hypertrophic def: "A size quality inhering in a bearer by virtue of its exhibiting hypertrophy (enlargement or overgrowth of an organ or part of the body due to increased size of the constituent cells)." [MedTerms:MedTerms "www.medterms.com/"] +subset: value_slim is_a: PATO:0000117 ! size -is_a: PATO:0000141 ! structure [Term] id: PATO:0000585 name: hypotrophic def: "A size quality inhering in a bearer by virtue of the progressive degeneration of an organ or tissue caused by loss of cells." [The free dictionary:The free dictionary "www.thefreedictionary.com/"] +subset: value_slim is_a: PATO:0000117 ! size -is_a: PATO:0000141 ! structure [Term] id: PATO:0000586 name: large size def: "A size which is greater relative to the normal or average." [PATO :GVG] +subset: value_slim related_synonym: "big" [] related_synonym: "enlarged" [] related_synonym: "great" [] @@ -3069,12 +3249,14 @@ id: PATO:0000587 name: small size def: "A size which is lesser relative to the normal or average." [PATO :GVG] +subset: value_slim related_synonym: "tiny" [] is_a: PATO:0000117 ! size [Term] id: PATO:0000588 name: vestigial +subset: value_slim is_a: PATO:0000117 ! size [Term] @@ -3091,12 +3273,14 @@ id: PATO:0000591 name: thick def: "A thickness which is relative low" [PATO :GVG] +subset: value_slim is_a: PATO:0000915 ! thickness [Term] id: PATO:0000592 name: thin def: "A thickness which is relative low" [PATO :GVG] +subset: value_slim is_a: PATO:0000915 ! thickness [Term] @@ -3113,12 +3297,14 @@ id: PATO:0000595 name: large volume def: "A volume which is relative high." [PATO :GVG] +subset: value_slim is_a: PATO:0000918 ! volume [Term] id: PATO:0000596 name: small volume def: "A volume which is relative low." [PATO :GVG] +subset: value_slim is_a: PATO:0000918 ! volume [Term] @@ -3135,12 +3321,14 @@ id: PATO:0000599 name: narrow def: "A width which is relative small." [PATO :GVG] +subset: value_slim is_a: PATO:0000921 ! width [Term] id: PATO:0000600 name: wide def: "A width which is relative large." [PATO :GVG] +subset: value_slim is_a: PATO:0000921 ! width [Term] @@ -3183,17 +3371,20 @@ [Term] id: PATO:0000608 name: closed +subset: value_slim related_synonym: "blocked" [] is_a: PATO:0000136 ! closure [Term] id: PATO:0000609 name: closure incomplete +subset: value_slim is_a: PATO:0000136 ! closure [Term] id: PATO:0000610 name: open +subset: value_slim is_a: PATO:0000136 ! closure [Term] @@ -3209,69 +3400,81 @@ [Term] id: PATO:0000613 name: disoriented +subset: value_slim is_a: PATO:0000137 ! orientation [Term] id: PATO:0000614 name: oriented +subset: value_slim is_a: PATO:0000137 ! orientation [Term] id: PATO:0000615 name: anterioralized +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000616 name: asymmetrical def: "A symmetry quality inhering in a bearer by virtue of lacking symmetry." [PATO :GVG] +subset: value_slim is_a: PATO:0000965 ! symmetry [Term] id: PATO:0000617 name: bent +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000618 name: bilateral +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000619 name: crowded +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000620 name: dorsalized +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000621 name: ectopic +subset: value_slim is_a: PATO:0000140 ! placement -is_a: PATO:0000141 ! structure [Term] id: PATO:0000622 name: erect +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000623 name: exserted +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000624 name: inserted +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000625 name: inverted def: "to be completely turned about in position or direction" [PATO :GVG] +subset: value_slim exact_synonym: "backward" [] exact_synonym: "reversed" [] is_a: PATO:0000140 ! placement @@ -3279,57 +3482,68 @@ [Term] id: PATO:0000626 name: lateralized +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000627 name: localised +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000628 name: mislocalised +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000629 name: misrouted +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000630 name: posterioralized +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000631 name: prostrate +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000632 name: symmetrical def: "A symmetry quality inhering in a bearer by virtue of having symmetry." [PATO :GVG] +subset: value_slim is_a: PATO:0000965 ! symmetry [Term] id: PATO:0000633 name: uncrowded +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000634 name: unilateral +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000635 name: unlocalised +subset: value_slim is_a: PATO:0000140 ! placement [Term] id: PATO:0000636 name: ventralized +subset: value_slim is_a: PATO:0000140 ! placement [Term] @@ -3340,16 +3554,19 @@ [Term] id: PATO:0000638 name: apoptotic +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000639 name: degenerate +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000640 name: dysplastic +subset: value_slim is_a: PATO:0000141 ! structure [Term] @@ -3360,52 +3577,62 @@ [Term] id: PATO:0000642 name: fused +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000643 name: herniated +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000644 name: hyperplastic +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000645 name: hypoplastic +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000646 name: malformed +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000647 name: necrotic -def: "A viability quality inhering in a bearer by virtue of unprogrammed cell death. " [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +def: "A viability quality inhering in a bearer by virtue of unprogrammed cell death." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: value_slim is_a: PATO:0000169 ! viability [Term] id: PATO:0000648 name: obstructed +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000649 name: perforated +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000650 name: supernumerary +subset: value_slim is_a: PATO:0000053 ! count [Term] id: PATO:0000651 name: unfused +subset: value_slim is_a: PATO:0000141 ! structure [Term] @@ -3476,6 +3703,7 @@ [Term] id: PATO:0000665 name: light +subset: value_slim is_a: PATO:0000016 ! color brightness [Term] @@ -3537,12 +3765,14 @@ id: PATO:0000677 name: cold def: "A temperature which is relative low" [gg:] +subset: value_slim is_a: PATO:0000146 ! temperature [Term] id: PATO:0000678 name: hot def: "A temperature which is relative high." [gg:] +subset: value_slim is_a: PATO:0000146 ! temperature [Term] @@ -3593,16 +3823,19 @@ [Term] id: PATO:0000688 name: asynchronous +subset: value_slim is_a: PATO:0000156 ! temporal [Term] id: PATO:0000689 name: continuous +subset: value_slim is_a: PATO:0000156 ! temporal [Term] id: PATO:0000690 name: discontinuous +subset: value_slim is_a: PATO:0000156 ! temporal [Term] @@ -3613,6 +3846,7 @@ [Term] id: PATO:0000692 name: heterochronic +subset: value_slim is_a: PATO:0000156 ! temporal [Term] @@ -3623,13 +3857,15 @@ [Term] id: PATO:0000694 name: premature -def: "A duration in which the process starts before natural start point. " [XX:<new dbxref>] +def: "A duration in which the process starts before natural start point." [XX:<new dbxref>] +subset: value_slim related_synonym: "early" [] is_a: PATO:0001309 ! duration [Term] id: PATO:0000695 name: synchronous +subset: value_slim is_a: PATO:0000156 ! temporal [Term] @@ -3655,13 +3891,15 @@ [Term] id: PATO:0000700 name: rough -def: "A texture quality inhering in a bearer by virtue of its irregular surface.\n" [PATO :GVG] +def: "A texture quality inhering in a bearer by virtue of its irregular surface." [PATO :GVG] +subset: value_slim is_a: PATO:0000150 ! texture [Term] id: PATO:0000701 name: smooth def: "A texture quality inhering in a bearer by virtue of pocessing a surface free of roughness or irregularities." [PATO :GVG] +subset: value_slim is_a: PATO:0000150 ! texture [Term] @@ -3687,21 +3925,25 @@ [Term] id: PATO:0000706 name: increased threshold +subset: value_slim is_a: PATO:0000152 ! threshold [Term] id: PATO:0000707 name: low threshold +subset: value_slim is_a: PATO:0000152 ! threshold [Term] id: PATO:0000708 name: decreased threshold +subset: value_slim is_a: PATO:0000152 ! threshold [Term] id: PATO:0000709 name: high threshold +subset: value_slim is_a: PATO:0000152 ! threshold [Term] @@ -3732,11 +3974,13 @@ [Term] id: PATO:0000715 name: fast +subset: value_slim is_a: PATO:0000165 ! time [Term] id: PATO:0000716 name: slow +subset: value_slim is_a: PATO:0000165 ! time [Term] @@ -3748,12 +3992,14 @@ id: PATO:0000718 name: lethal (sensu genetics) def: "A viability quality inhering in a bearer or a population by virtue of the bearer's inability to survive and develop normally or the long term survival inability of a given population." [PATO :GVG] +subset: value_slim is_a: PATO:0000169 ! viability [Term] id: PATO:0000719 name: viable def: "A viability quality inhering in a bearer or a population by virtue of the bearer's ability to survive and develop normally or the long term survival ability of a given population." [PATO :GVG] +subset: value_slim is_a: PATO:0000169 ! viability [Term] @@ -3944,41 +4190,49 @@ [Term] id: PATO:0000757 name: balanced +subset: value_slim is_a: PATO:0000185 ! balance [Term] id: PATO:0000758 name: unbalanced +subset: value_slim is_a: PATO:0000185 ! balance [Term] id: PATO:0000759 name: bang sensitive +subset: value_slim is_a: PATO:0000186 ! behavioral quality [Term] id: PATO:0000760 name: hyperactive -is_a: PATO:0000186 ! behavioral quality +subset: value_slim +is_a: PATO:0001530 ! behavioral quality of occurent [Term] id: PATO:0000761 name: hypoactive -is_a: PATO:0000186 ! behavioral quality +subset: value_slim +is_a: PATO:0001530 ! behavioral quality of occurent [Term] id: PATO:0000762 name: impaired +subset: value_slim is_a: PATO:0000186 ! behavioral quality [Term] id: PATO:0000763 name: paralysed +subset: value_slim is_a: PATO:0000186 ! behavioral quality [Term] id: PATO:0000764 name: passive +subset: value_slim is_a: PATO:0000186 ! behavioral quality [Term] @@ -3995,42 +4249,49 @@ id: PATO:0000767 name: increased consumption def: "A consumption which is relative high." [PATO :GVG] +subset: value_slim is_a: PATO:0000187 ! consumption [Term] id: PATO:0000768 name: decreased consumption def: "A consumption which is relative low." [PATO :GVG] +subset: value_slim is_a: PATO:0000187 ! consumption [Term] id: PATO:0000769 name: coordinated def: "A coordination quality of having skilful and effective interaction of movement." [PATO :GVG] +subset: value_slim is_a: PATO:0000188 ! coordination [Term] id: PATO:0000770 name: uncoordinated def: "A coordination quality of lacking skilful and effective interaction of movement." [PATO :GVG] +subset: value_slim is_a: PATO:0000188 ! coordination [Term] id: PATO:0000771 name: aversion def: "A preference quality of disliking a perceived stimulus." [PATO :GVG] +subset: value_slim is_a: PATO:0000773 ! preference [Term] id: PATO:0000772 name: indifference def: "A preference quality of having no preference to a perceived stimulus." [PATO :GVG] +subset: value_slim is_a: PATO:0000773 ! preference [Term] id: PATO:0000773 name: preference def: "A discrimination quality of liking a perceived stimulus." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000189 ! discrimination [Term] @@ -4607,6 +4868,7 @@ id: PATO:0000888 name: female fertile def: "A female fertility quality of being capable of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: value_slim is_a: PATO:0000277 ! female fertility [Term] @@ -4618,6 +4880,7 @@ id: PATO:0000890 name: male sterile def: "A male fertility quality of being incapable of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: value_slim related_synonym: "male infertile" [] is_a: PATO:0000279 ! male fertility @@ -4625,12 +4888,14 @@ id: PATO:0000891 name: male fertile def: "A male fertility quality of being capable of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: value_slim is_a: PATO:0000279 ! male fertility [Term] id: PATO:0000892 name: female sterile def: "A female fertility quality of being incapable of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: value_slim related_synonym: "female infertile" [] is_a: PATO:0000277 ! female fertility @@ -4730,12 +4995,16 @@ [Term] id: PATO:0000911 -name: slow rate +name: decreased rate +subset: value_slim +exact_synonym: "slow rate" [] is_a: PATO:0000161 ! rate [Term] id: PATO:0000912 -name: fast rate +name: increased rate +subset: value_slim +exact_synonym: "fast rate" [] is_a: PATO:0000161 ! rate [Term] @@ -4752,6 +5021,7 @@ id: PATO:0000915 name: thickness def: "A physical quality which is equal to the dimension through an object as opposed to its length or width." [WordNet:WordNet "wordnet.princeton.edu/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -4768,6 +5038,7 @@ id: PATO:0000918 name: volume def: "A physical quality of the amount of 3-dimensional space an object occupies." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -4783,7 +5054,8 @@ [Term] id: PATO:0000921 name: width -def: "A physical quality which is equal to the distance from one side of an object to another side which is opposite. \n\n" [PATO :GVG] +def: "A physical quality which is equal to the distance from one side of an object to another side which is opposite." [PATO :GVG] +subset: attribute_slim related_synonym: "breadth" [] is_a: PATO:0001018 ! physical quality @@ -4860,16 +5132,19 @@ [Term] id: PATO:0000936 name: truncated +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000937 name: disorganized +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000938 name: organized +subset: value_slim is_a: PATO:0000141 ! structure [Term] @@ -4885,98 +5160,115 @@ [Term] id: PATO:0000941 name: vacuolated +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000942 name: underdeveloped +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000943 name: overdeveloped +subset: value_slim is_a: PATO:0000141 ! structure [Term] id: PATO:0000944 name: pointed def: "A sharp or tapered end" [PATO :GVG] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000945 name: epinastic def: "A downward bending of leaves or other plant parts." [PATO:gg] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000946 name: oblong def: "Having a somewhat elongated form with approximately parallel sides" [PATO:gg] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000947 name: elliptic def: "Elliptic shape" [PATO:gg] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000948 name: heart shaped +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000949 name: fasciated def: "Abnormally flattened or coalesced." [PATO:gg] +subset: value_slim is_a: PATO:0000052 ! shape [Term] id: PATO:0000950 name: grey def: "A color that lacks saturation." [PATO :GVG] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000951 name: purple def: "A colour that falls about midway between red and blue in hue" [Dictionary:http\://dictionary.reference.com/] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000952 name: brown +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000953 name: orange def: "A color hue with high-medium wavelengththat of that portion of the visible spectrum lying between red and yellow, evoked in the human observer by radiant energy with wavelengths of approximately 585 to 620 nanometers" [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000954 name: pink def: "A composite color with parts\nhigh redness, low blueness, high brightness and low\nsaturation" [PATO :GVG] +subset: value_slim is_a: PATO:0000014 ! color [Term] id: PATO:0000955 name: fertile def: "A fertility quality of being capable of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: value_slim is_a: PATO:0000274 ! fertility [Term] id: PATO:0000956 name: sterile def: "A fertility quality of being incapable of initiating, sustaining, or supporting reproduction." [PATO :GVG] +subset: value_slim is_a: PATO:0000274 ! fertility [Term] id: PATO:0000957 name: opacity def: "An optical quality which obtains by virtue\nof the ability of the bearer to absorb visible light" [PATO:gg] +subset: attribute_slim is_a: PATO:0001300 ! optical quality [Term] @@ -5008,12 +5300,14 @@ id: PATO:0000963 name: opaque def: "Not clear; not transmitting or reflecting light or radiant energy" [PATO:gg] +subset: value_slim exact_synonym: "non-transparent" [] is_a: PATO:0000957 ! opacity [Term] id: PATO:0000964 name: transparent +subset: value_slim exact_synonym: "clear" [] is_a: PATO:0000957 ! opacity @@ -5021,6 +5315,7 @@ id: PATO:0000965 name: symmetry def: "A pattern quality of correspondence in size, shape, and relative position of parts on opposite sides of a dividing line or median plane or about a center or axis." [PATO :GVG] +subset: attribute_slim is_a: PATO:0000060 ! pattern [Term] @@ -5032,6 +5327,7 @@ id: PATO:0000967 name: undulate def: "Having a sinuate margin and rippled surface." [PATO:gg] +subset: value_slim is_a: PATO:0000052 ! shape [Term] @@ -5042,12 +5338,14 @@ [Term] id: PATO:0000969 name: dwarf +subset: value_slim is_a: PATO:0000117 ! size [Term] id: PATO:0000970 name: permeability def: "A structure quality of being cabapble of being permeated or pervaded by a liquid (as by osmosis or diffusion)." [Biology-online :Biology-online "http://www.biology-online.org/"] +subset: attribute_slim is_a: PATO:0000141 ! structure [Term] @@ -5063,7 +5361,8 @@ [Term] id: PATO:0000973 name: porosity -def: "A perneability quality of admitting the passage of gas or liquid through pores or interstices." [PATO:gg] +def: "A perneability quality of admitting the passage of gas or liquid through pores or interstices." [PATO:] +subset: attribute_slim is_a: PATO:0000970 ! permeability [Term] @@ -5110,24 +5409,28 @@ id: PATO:0000982 name: permeable def: "A quality of being capable to be permeated or pervaded by a liquid (as by osmosis or diffusion)." [Biology-online :Biology-online "http://www.biology-online.org/"] +subset: value_slim is_a: PATO:0000970 ! permeability [Term] id: PATO:0000983 name: impermeable def: "A permeability quality of being incapable of being permeated or pervaded by a liquid (as by osmosis or diffusion)." [Biology-online :Biology-online "http://www.biology-online.org/"] +subset: value_slim is_a: PATO:0000970 ! permeability [Term] id: PATO:0000984 name: porous def: "A quality of being capable of admitting the passage of gas or liquid through pores or interstices." [PATO:GVG] +subset: value_slim is_a: PATO:0000973 ! porosity [Term] id: PATO:0000985 name: nonporous def: "A quality of being incapable of admitting the passage of gas or liquid through pores or interstices." [PATO:GVG] +subset: value_slim is_a: PATO:0000973 ! porosity [Term] @@ -5164,6 +5467,7 @@ id: PATO:0000992 name: viscosity def: "A physical quality of fluids describing their internal resistance to flow" [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -5195,11 +5499,13 @@ id: PATO:0000998 name: viscous def: "A viscosity which relative high." [PATO :GVG] +subset: value_slim is_a: PATO:0000992 ! viscosity [Term] id: PATO:0000999 name: alternation +subset: value_slim is_a: PATO:0001226 ! quantitative [Term] @@ -5231,6 +5537,7 @@ id: PATO:0001005 name: latency def: "The time that elapses between a stimulus and the response to it" [PATO:gg] +subset: attribute_slim is_a: PATO:0000165 ! time [Term] @@ -5297,53 +5604,62 @@ id: PATO:0001018 name: physical quality def: "A quality that exists through action of continuants at the physical level of organisation" [PATO:GVG] +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0001019 name: density def: "A physical quality which inhers to the bearer by virtue of some influence exerted by its mass." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001020 name: damage +subset: attribute_slim is_a: PATO:0001237 ! monadic quality of continuant [Term] id: PATO:0001021 name: energy def: "A physical quality inhering in a bearer by virtue of its capacity to do work." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001022 name: impulse def: "A physical quality inhering in a bearer by virtue of the change in its momentum." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001023 name: momentum -def: "A physical quality inhering in a bearer by \nvirtue of its velocity multiplied by its mass\n" [PATO :GVG] +def: "A physical quality inhering in a bearer by \nvirtue of its velocity multiplied by its mass" [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001024 name: power def: "A physical quality inhering in a object by virtue of the rate of doing work." [Wikipedia:Wikipedia "http://en.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001025 name: pressure def: "A physical quality that inheres in a bearer in proportion to the amount of force per unit area it exerts." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001026 name: work def: "A physical quality which is equal to the energy transferred by a force to a moving object." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: attribute_slim exact_synonym: "W" [] is_a: PATO:0001018 ! physical quality @@ -5355,33 +5671,38 @@ [Term] id: PATO:0001028 name: acceleration -def: "A physical quality inhering in a bearer by \nvirtue of therate of change of its velocity in either speed or direction." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +def: "A physical quality inhering in a bearer by virtue of therate of change of its velocity in either speed or direction." [Wikipedia:Wikipedia "http://www.wikipedia.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001029 name: efficiency def: "A physical quality inhering in a bearer by \nvirtue of ratio of the output to the input." [WordNet :WordNet "wordnet.princeton.edu/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001030 name: flux def: "A physical quality that exists by virtue of the amount of flow per unit time." [PATO :GVG] -is_a: PATO:0001018 ! physical quality +subset: attribute_slim +is_a: PATO:0000156 ! temporal [Term] id: PATO:0001031 name: elasticity -def: "A physical quality inhering in a bearer by \nvirtue of the ratio of its extension to its original length. " [PATO :GVG] +def: "A physical quality inhering in a bearer by \nvirtue of the ratio of its extension to its original length." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001032 name: position def: "The particular portion of space occupied by a physical object." [XX:<new dbxref>] +subset: attribute_slim related_synonym: "location" [] -is_a: PATO:0001018 ! physical quality +is_a: PATO:0000132 ! spatial [Term] id: PATO:0001033 @@ -5392,12 +5713,14 @@ id: PATO:0001034 name: strain def: "A physical quality inhering in a bearer by \nvirtue of the relative change in its length or its volume when being stretched or squashed." [PATO :GVG] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] id: PATO:0001035 name: force def: "A physical quality inhering in a object affecting its acceleration." [: "http://thesaurus.maths.org/"] +subset: attribute_slim is_a: PATO:0001018 ! physical quality [Term] @@ -5438,6 +5761,7 @@ [Term] id: PATO:0001043 name: susceptibility +subset: attribute_slim is_a: PATO:0000085 ! sensitivity [Term] @@ -5454,6 +5778,7 @@ id: PATO:0001046 na... [truncated message content] |
From: <mg...@us...> - 2007-02-16 18:41:38
|
Revision: 371 http://svn.sourceforge.net/obo/?rev=371&view=rev Author: mgibson Date: 2007-02-16 10:41:38 -0800 (Fri, 16 Feb 2007) Log Message: ----------- fixed layout problem - when more fields were configged in - nicole.cfg - the free text fields would collapse - gee whiz - so put in a min size for free text - also switched over to grid bag layout in many places to get more control over layout - basically the simpler layout managers dont cut it once the gui gets complicated the field panel really needs to figure out its minimum size from number of fields it has - todo todo - and hopefully grid bag layout would respect that - not sure it would actually - hmmmmm - this sis good for now with weighted filling Modified Paths: -------------- phenote/trunk/phenote phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java phenote/trunk/src/java/phenote/gui/GridBagUtil.java phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java phenote/trunk/src/java/phenote/gui/field/CharFieldGui.java phenote/trunk/src/java/phenote/gui/field/FieldPanel.java phenote/trunk/src/java/phenote/gui/field/FreeTextField.java phenote/trunk/src/java/phenote/main/Phenote.java phenote/trunk/src/java/phenote/util/FileUtil.java Modified: phenote/trunk/phenote =================================================================== --- phenote/trunk/phenote 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/phenote 2007-02-16 18:41:38 UTC (rev 371) @@ -8,6 +8,6 @@ fi; done -java -Xmx700M -classpath ${PHENOTE_CLASSPATH} phenote.main.Phenote $@ +java -Xmx810M -classpath ${PHENOTE_CLASSPATH} phenote.main.Phenote $@ ##java -Xmx300M -classpath classfiles:jars/oboedit.jar:jars/org.geneontology.jar:jars/BrowserLauncher2-10rc4.jar:jars/junit-4.0.jar:jars/tomcat-servlet.jar:jars/xbean.jar:jars/jsr173_1.0_api.jar:jars/phenoxmlbeans.jar:jars/phenoteconfigbeans.jar:jars/log4j-1.2.13.jar:jars/te-common.jar phenote.main.Phenote $@ Modified: phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java =================================================================== --- phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/dataadapter/OntologyDataAdapter.java 2007-02-16 18:41:38 UTC (rev 371) @@ -179,7 +179,9 @@ // if ontCfg.hasSynchUrl() ? // URL synchUrl = ontCfg.getSynchUrl - startTimer("checking with repos... loading obo session "+filename); + long mem = Runtime.getRuntime().totalMemory()/1000000; + LOG.debug(url+" checking with repos... loading obo session mem "+mem+"\n"); + startTimer(url+" checked against repos... obo session loaded"); // printed at stopTime if (oc.hasReposUrl()) { try { URL reposUrl = oc.getReposUrl();//new URL("http://obo.cvs.sourceforge.net/*checkout*/obo/obo/ontology/evidence_code.obo"); @@ -195,6 +197,12 @@ loadOboSessionFromUrl(o,url,filename); stopTimer(); + mem = Runtime.getRuntime().totalMemory()/1000000; + System.out.println("mem after load "+mem+" max "+Runtime.getRuntime().maxMemory()/1000000); + //System.gc(); + //mem = Runtime.getRuntime().totalMemory()/1000000; + //System.out.println("\n\nmem after garbage collection "+mem+"\n"); + } /** url is either local file or repos url */ @@ -311,7 +319,9 @@ // } //stopTimer(); r.close(); + is.close(); // ?? w.close(); + fos.close(); // ?? } catch (IOException e) { throw new OntologyException(e); } } Modified: phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/gui/CharacterTablePanel.java 2007-02-16 18:41:38 UTC (rev 371) @@ -4,7 +4,9 @@ import java.util.List; import java.awt.Dimension; -import java.awt.GridLayout; +//import java.awt.GridLayout; +import java.awt.GridBagConstraints; +import java.awt.GridBagLayout; import java.awt.Point; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; @@ -67,9 +69,11 @@ } private void init() { - setLayout(new GridLayout(2,1)); // row,col + //setBorder(new javax.swing.border.LineBorder(java.awt.Color.RED)); debug + //setLayout(new GridLayout(2,1)); // row,col + setLayout(new GridBagLayout()); setPreferredSize(new Dimension(1800,800)); - setMinimumSize(new Dimension(1400,630)); + setMinimumSize(new Dimension(1400,630)); // 630 characterTableModel = new CharacterTableModel(); charJTable = new JTable(characterTableModel); @@ -85,12 +89,14 @@ // wierd - changes to scrollbar seem to happen on own thread? verticalScrollBar.getModel().addChangeListener(new ScrollChangeListener()); // width config? 150 * # of cols? set column width? column width config? - charJTable.setPreferredScrollableViewportSize(new Dimension(500, 150)); + charJTable.setPreferredScrollableViewportSize(new Dimension(500, 600));//150 - add(tableScroll); + GridBagConstraints gbc = GridBagUtil.makeFillingConstraint(0,0); + add(tableScroll,gbc); // add in buttons JPanel buttonPanel = new JPanel(); + //buttonPanel.setBorder(new javax.swing.border.LineBorder(java.awt.Color.BLUE)); ActionListener al = new ButtonActionListener(); @@ -107,7 +113,9 @@ if (Config.inst().uvicGraphIsEnabled()) graphWindow = addButton("Graph",al,buttonPanel); - add(buttonPanel); + // non filling + gbc = GridBagUtil.makeAnchorConstraint(0,1,GridBagConstraints.CENTER); + add(buttonPanel,gbc); EditManager.inst().addCharChangeListener(new TableCharChangeListener()); Modified: phenote/trunk/src/java/phenote/gui/GridBagUtil.java =================================================================== --- phenote/trunk/src/java/phenote/gui/GridBagUtil.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/gui/GridBagUtil.java 2007-02-16 18:41:38 UTC (rev 371) @@ -7,19 +7,41 @@ public class GridBagUtil { + public static GridBagConstraints makeConstraint(int x,int y) { + return makeConstraint(x,y,3,3,GridBagConstraints.WEST); + } + public static GridBagConstraints makeConstraint(int x,int y,int horizPad,int vertPad) { return makeConstraint(x,y,horizPad,vertPad,GridBagConstraints.WEST); } + + static GridBagConstraints makeAnchorConstraint(int x, int y, int anchor) { + return makeConstraint(x,y,3,3,anchor); + } + + // defaults wieghty to 0 and fill to 0 - not great defaults really + // well actually weighty means dont expand which is what you want for fields static GridBagConstraints makeConstraint(int x, int y, int horizPad, int vertPad, int anchor) { - return makeConstraint(x,y,1,1,0,horizPad,vertPad,0,anchor); + double weightY = 0; // 1?? + return makeConstraint(x,y,1,1,weightY,horizPad,vertPad,0,anchor); } public static GridBagConstraints makeWidthConstraint(int x, int y, int horPad, int verPad, int width) { - return makeConstraint(x,y,width,1,0,horPad,verPad,0,GridBagConstraints.WEST); + double weightY = 0; // 1???? + return makeConstraint(x,y,width,1,weightY,horPad,verPad,0,GridBagConstraints.WEST); } + /** Fils up vert & hor with weight 1 */ + public static GridBagConstraints makeFillingConstraint(int x, int y) { + double weightY = 1; + int fill = GridBagConstraints.BOTH; + int anchor = GridBagConstraints.WEST; + int pad = 3; // presumptious??? + return makeConstraint(x,y,1,1,weightY,pad,pad,fill,anchor); + } + private static GridBagConstraints makeConstraint(int x, int y, int width, int height, double weighty, int horizPad, int vertPad, Modified: phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/gui/field/AbstractAutoCompList.java 2007-02-16 18:41:38 UTC (rev 371) @@ -53,6 +53,7 @@ //private AutoTextFieldEditor autoTextFieldEditor; private AutoTextField autoTextField; private CharField charField; + //private CharFieldGui charFieldGui; // should it be ISA not HASA? ///** Whether differentia of a post composed term */ //private boolean isDifferentia = false; /** if false then model is not edited */ @@ -68,11 +69,13 @@ // this will probably throw errors if non metal look & feel is used setUI(new MetalListComboUI()); setEditable(true); - setPreferredSize(new Dimension(390,20)); - setMaximumSize(new Dimension(390,20)); + //charFieldGui = cfg; + setCharField(cf); + setPreferredSize(CharFieldGui.inputSize); //new Dimension(390,20)); + setMaximumSize(CharFieldGui.inputSize); //new Dimension(390,20)); // this is super critical - fixes bug where layout goes to hell if string are long // in completion - dont ask me why???? - setMinimumSize(new Dimension(390,20)); + setMinimumSize(CharFieldGui.inputSize); AutoTextFieldEditor autoTextFieldEditor = new AutoTextFieldEditor(); this.setEditor(autoTextFieldEditor); // dont know why by setting fonts this seem to get worse not better in terms of @@ -86,7 +89,6 @@ setFont(new Font("Monospaced",Font.PLAIN,10)); //setOntology(ontology); //searchParams = sp; // singleton access? part of ontology? - setCharField(cf); compListSearcher = s; //enableTermInfoListening(true); // default - hardwired in rel & term subclasses //addCompletionListListener(compList); Modified: phenote/trunk/src/java/phenote/gui/field/CharFieldGui.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/CharFieldGui.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/gui/field/CharFieldGui.java 2007-02-16 18:41:38 UTC (rev 371) @@ -5,6 +5,7 @@ import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.Container; +import java.awt.Dimension; import javax.swing.JButton; import javax.swing.JComboBox; import javax.swing.JLabel; @@ -53,6 +54,8 @@ private boolean addCompButton = true; /** if true then set gui but not model, for clearing on multi, default false */ private boolean updateGuiOnly = false; + static int fieldHeight = 17; + static Dimension inputSize = new Dimension(390,fieldHeight); // size of user input box CharFieldGui(CharField charField, FieldPanel tp) {/*Container parent,*/ Modified: phenote/trunk/src/java/phenote/gui/field/FieldPanel.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/FieldPanel.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/gui/field/FieldPanel.java 2007-02-16 18:41:38 UTC (rev 371) @@ -46,7 +46,7 @@ } private void initGui() { - // should figure y from # of fields really + // should figure y from # of fields really!!! yes!!! // width of ontology labels effects x this.setMinimumSize(new Dimension(730,490));//690,490)); //this.setPreferredSize(new Dimension(2000,750)); // irrelevant in box layout Modified: phenote/trunk/src/java/phenote/gui/field/FreeTextField.java =================================================================== --- phenote/trunk/src/java/phenote/gui/field/FreeTextField.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/gui/field/FreeTextField.java 2007-02-16 18:41:38 UTC (rev 371) @@ -30,7 +30,8 @@ //private void initTextField(String label) { FreeTextField(CharFieldGui cfg) { charFieldGui = cfg; - textField = new JTextField(25); + textField = new JTextField(35); + textField.setMinimumSize(CharFieldGui.inputSize); textField.setEditable(true); textField.getDocument().addDocumentListener(new TextFieldDocumentListener()); textField.addFocusListener(new FreeFocusListener()); Modified: phenote/trunk/src/java/phenote/main/Phenote.java =================================================================== --- phenote/trunk/src/java/phenote/main/Phenote.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/main/Phenote.java 2007-02-16 18:41:38 UTC (rev 371) @@ -125,62 +125,7 @@ } } -// /** for now just looking for '-c configFile.cfg', use command line package -// if we need to get more sophisticated -// so if user has personal config file should override this - however maybe -// there should be a distinction between initial config file and user made configs -// well really the initials are db/species specific - so could be -// --initialConfig zf|fb|obd - actually da heck with that with entity chooser just -// put all 3 ontologies in one which is then the default (unspecified on cmd line) -// and -c file.cfg will load/overwrite that cfg into .phenote/my-phenote.cfg -// (if it exists) - we can always add --init later if we need it -// -c overwrites, -i doesnt -i is for initial startup of phenote */ -// private void doCommandLineOld(String[] args) { -// String configFile = getConfigFileFromCommandLine(args); -// // if no config file specified then set default initial config file. this will be -// // overridden by a personal config file if it exists -// //if (configFile == null) configFile = Config.DEFAULT_CONFIG_FILE; stored in file -// try { -// if (isOverwriteConfigFile(args)) //causes wipeout move of app file to .phenote -// Config.inst().setOverwriteConfigFile(configFile); -// else if (isInitialConfigFile(args)) -// Config.inst().setInitialConfigFile(configFile); -// //else if update... -// else // no command line config file specified - use last one specified (cache) -// Config.inst().loadDefaultConfigFile(); -// } catch (ConfigException e) { -// //LOG.fatal("EXITING! Fatal error in config file: "+e.getMessage()); -// LOG.error("Error in config file! "+e.getMessage()); -// e.printStackTrace(); // log? -// //System.exit(1); // isnt this a bit extreme? -// System.out.println("Yikes! config exception "+e+" gonna try loading default" -// +" config"); -// try { Config.inst().loadDefaultConfigFile(); } -// catch (ConfigException ce) { -// System.out.println("bummer - even default config fails. we're hosed! "+ce); -// } -// } -// } -// // change to -m for merge?? - move to CommandLine! -// private boolean isInitialConfigFile(String args[]) { -// if (args == null || args.length < 2) return false; -// return args[0].equals("-i"); -// } -// private boolean isOverwriteConfigFile(String args[]) { -// if (args == null || args.length < 2) return false; -// return args[0].equals("-c"); -// } - -// private String getConfigFileFromCommandLine(String args[]) { -// // need 2 args -// if (args == null || args.length < 2) return null; -// //String firstArg = args[0]; -// if (!isInitialConfigFile(args) && !isOverwriteConfigFile(args)) return null; -// String configFile = args[1]; -// return configFile; -// } - public Frame getFrame() { return frame; } private void makeWindow() { @@ -225,12 +170,19 @@ //mainPanel.add(termInfo.getComponent(),gbc); - GridBagConstraints gbc = GridBagUtil.makeConstraint(0,0,5,5); + //GridBagConstraints gbc = GridBagUtil.makeConstraint(0,0,4,4); // x,y,hPad,vPad +// double weightY = 1; +// int fill = GridBagConstraints.BOTH; +// int anchor = GridBagConstraints.WEST; +// GridBagConstraints gbc = GridBagUtil.makeConstraint(0,0,1,1,weightY,4,4,fill,anchor); + GridBagConstraints gbc = GridBagUtil.makeFillingConstraint(0,0); + gbc.weighty = 10; mainPanel.add(upperPanel,gbc); characterTablePanel = new CharacterTablePanel(); //termAndTablePanel.add(characterTablePanel); ++gbc.gridy; // ? + gbc.weighty = 17; mainPanel.add(characterTablePanel,gbc); return mainPanel; @@ -247,6 +199,59 @@ } -// SearchPanel searchPanel = new SearchPanel(fieldPanel); -// mainPanel.add(searchPanel); -// fieldPanel.setSearchPanel(searchPanel); +// /** for now just looking for '-c configFile.cfg', use command line package +// if we need to get more sophisticated +// so if user has personal config file should override this - however maybe +// there should be a distinction between initial config file and user made configs +// well really the initials are db/species specific - so could be +// --initialConfig zf|fb|obd - actually da heck with that with entity chooser just +// put all 3 ontologies in one which is then the default (unspecified on cmd line) +// and -c file.cfg will load/overwrite that cfg into .phenote/my-phenote.cfg +// (if it exists) - we can always add --init later if we need it +// -c overwrites, -i doesnt -i is for initial startup of phenote */ +// private void doCommandLineOld(String[] args) { +// String configFile = getConfigFileFromCommandLine(args); +// // if no config file specified then set default initial config file. this will be +// // overridden by a personal config file if it exists +// //if (configFile == null) configFile = Config.DEFAULT_CONFIG_FILE; stored in file +// try { +// if (isOverwriteConfigFile(args)) //causes wipeout move of app file to .phenote +// Config.inst().setOverwriteConfigFile(configFile); +// else if (isInitialConfigFile(args)) +// Config.inst().setInitialConfigFile(configFile); +// //else if update... +// else // no command line config file specified - use last one specified (cache) +// Config.inst().loadDefaultConfigFile(); +// } catch (ConfigException e) { +// //LOG.fatal("EXITING! Fatal error in config file: "+e.getMessage()); +// LOG.error("Error in config file! "+e.getMessage()); +// e.printStackTrace(); // log? +// //System.exit(1); // isnt this a bit extreme? +// System.out.println("Yikes! config exception "+e+" gonna try loading default" +// +" config"); +// try { Config.inst().loadDefaultConfigFile(); } +// catch (ConfigException ce) { +// System.out.println("bummer - even default config fails. we're hosed! "+ce); +// } +// } +// } + +// // change to -m for merge?? - move to CommandLine! +// private boolean isInitialConfigFile(String args[]) { +// if (args == null || args.length < 2) return false; +// return args[0].equals("-i"); +// } +// private boolean isOverwriteConfigFile(String args[]) { +// if (args == null || args.length < 2) return false; +// return args[0].equals("-c"); +// } + +// private String getConfigFileFromCommandLine(String args[]) { +// // need 2 args +// if (args == null || args.length < 2) return null; +// //String firstArg = args[0]; +// if (!isInitialConfigFile(args) && !isOverwriteConfigFile(args)) return null; +// String configFile = args[1]; +// return configFile; +// } + Modified: phenote/trunk/src/java/phenote/util/FileUtil.java =================================================================== --- phenote/trunk/src/java/phenote/util/FileUtil.java 2007-02-14 23:49:17 UTC (rev 370) +++ phenote/trunk/src/java/phenote/util/FileUtil.java 2007-02-16 18:41:38 UTC (rev 371) @@ -81,8 +81,10 @@ public static URL findUrl(String filename) throws FileNotFoundException { List<URL> possibleUrls = getPossibleUrls(filename); - for (URL u : possibleUrls) + for (URL u : possibleUrls) { + //System.out.println(u+" url exists "+urlExists(u)); if (urlExists(u)) return u; + } System.out.println("Failed to find file "+filename); //LOG.error("Failed to find file "+filename); throw new FileNotFoundException(filename+" not found"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cmu...@us...> - 2007-03-03 01:48:53
|
Revision: 387 http://svn.sourceforge.net/obo/?rev=387&view=rev Author: cmungall Date: 2007-03-02 17:48:35 -0800 (Fri, 02 Mar 2007) Log Message: ----------- Modified Paths: -------------- phenote/trunk/conf/go-function-process.cfg Added Paths: ----------- phenote/trunk/conf/mp-xp.cfg phenote/trunk/doc/phenote-website/phenote-mp-xp.jnlp Modified: phenote/trunk/conf/go-function-process.cfg =================================================================== --- phenote/trunk/conf/go-function-process.cfg 2007-03-02 12:25:45 UTC (rev 386) +++ phenote/trunk/conf/go-function-process.cfg 2007-03-03 01:48:35 UTC (rev 387) @@ -10,10 +10,10 @@ <obo-repository url-dir="http://purl.org/obo/obo-all/"/> - <field name="T1" syntax-abbrev="T1"> + <field name="T1" syntax-abbrev="Term"> <ontology name="GO-BP" file="biological_process.obo" repos-subdir="biological_process" /> </field> - <field name="T2" syntax-abbrev="T2"> + <field name="T2" syntax-abbrev="Xref"> <ontology name="GO-MF" file="molecular_function.obo" repos-subdir="molecular_function" /> </field> <field name="Context" syntax-abbrev="Context" type="free_text"/> Added: phenote/trunk/conf/mp-xp.cfg =================================================================== --- phenote/trunk/conf/mp-xp.cfg (rev 0) +++ phenote/trunk/conf/mp-xp.cfg 2007-03-03 01:48:35 UTC (rev 387) @@ -0,0 +1,25 @@ + +<phenote-configuration version="1.0" xmlns="phenote/config/xml" noNamespaceSchemaLocation="phenote-config.xsd"> + + <dataadapter name="phenosyntax" enable="true"/> + <dataadapter name="phenoxml" enable="true"/> + + <log config-file="conf/log4j-standalone.xml" /> + + <uvic-graph enable="false"/> + + <obo-repository url-dir="http://purl.org/obo/obo-all/"/> + + <field name="Term" syntax-abbrev="Term"> + <ontology name="MP" file="mammalian_phenotype.obo" repos-subdir="mammalian_phenotype" /> + </field> + <field name="EquivalentTo" syntax-abbrev="EquivalentTo"> + <ontology name="PATO" file="quality.obo" repos-subdir="quality" /> + <ontology name="MA" file="adult_mouse_anatomy.obo" repos-subdir="adult_mouse_anatomy" /> + <postcomp relationship-ontology="relationship.obo" repos-subdir="OBO_REL"/> + <ontology name="GO-BP" file="biological_process.obo" repos-subdir="biological_process" /> + <ontology name="GO-CC" file="cellular_component.obo" repos-subdir="cellular_component" /> + <ontology name="CHEBI" file="chebi.obo" repos-subdir="chebi" /> + </field> + +</phenote-configuration> Added: phenote/trunk/doc/phenote-website/phenote-mp-xp.jnlp =================================================================== --- phenote/trunk/doc/phenote-website/phenote-mp-xp.jnlp (rev 0) +++ phenote/trunk/doc/phenote-website/phenote-mp-xp.jnlp 2007-03-03 01:48:35 UTC (rev 387) @@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="UTF-8"?> +<jnlp +spec="1.0+" +codebase="http://toy.lbl.gov:9010/phenote/1.1/" +href="phenote-mp-xp.jnlp"> +<information> + <title>Phenote-for-GO 1.1</title> + <vendor>BBOP</vendor> + <description>Phenote demo for </description> + <!-- Declares that the application can run without + access to the server it was downloaded from --> + <offline-allowed /> +</information> +<security> + <!-- Request that the application be given full + access to the local (executing) machine, + as if it were a regular Java application. + Requires that all JAR files be signed + by a trusted party --> + <all-permissions /> +</security> +<resources> + <!-- Specify the versions of the Java Runtime Environment + (JRE) that are supported by the application. + Multiple entries of this kind are allowed, in which + case they are considered to be in order of preference --> + <j2se version="1.5+" initial-heap-size="64m" max-heap-size="500m" /> + <jar href="jars/phenote.jar" /> + <jar href="jars/oboedit.jar" /> + <jar href="jars/org.geneontology.jar" /> + <jar href="jars/BrowserLauncher2-10rc4.jar" /> + <jar href="jars/jsr173_1.0_api.jar" /> + <jar href="jars/phenoxmlbeans.jar" /> + <jar href="jars/phenoteconfigbeans.jar" /> + <jar href="jars/xbean.jar" /> + <jar href="jars/tomcat-servlet.jar" /> + <jar href="jars/te-common.jar" /> + <jar href="jars/log4j-1.2.13.jar" /> +</resources> +<application-desc main-class="phenote.main.Phenote"> + <argument>-u</argument> + <argument>/mp-xp.cfg</argument> +</application-desc> +</jnlp> + + + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |