0: label
1: ont chooser or rest of label
2: input field
3: edit button(if dont fit), rest of input, list del, list?
4: buttons, list?
todo: move list to below input not to right of it - too scrunched
the destination field that this group is populating (with obo classes), if
a group is not populating a destination field this would be no-oped
one could imagine other destinations like main datamodel
I think chris wrote this? reads & writes obo files with annotations,
I believe this currently writes out the whole obo session terms and all,
which need to be filtered out
The Character datamodel is a generic hash of CharField-CharFieldValues
CharFieldValues are free text or from ontologies
This is the straightontabular implementation of CharacterI
In the table view a character represents a row
holds a list of Characters - rename phenotype? i dont think so - can have
multiple genotypes in it - transfreable allows it to be plopped on the
clipboard
hmmm isnt this just a List?
This actually is for a CharField change - rename this CharFieldChangeEvent?
but its really the value of the field thats changed
perhaps CharFieldValueChangeEvent - well thats verbose
but wait this holds the transaction that could be an update to a char field val
or a whole new char, or delete char...
so this class has evolved - this was actually doing the setting of field values at one
point - but now that we've gone to a generic datamodel, the datamodel is now determined
by the configuration - and not restricted to CharFieldEnums - you can have a field that is
not in CharFieldEnum - which leads to the question should we get rid of this class?
and the answer at the moment is maybe not - as you can still use this in data adapters
to get at predefined strings for definied fields - to make sure data adapters are using
the same string for the pub of entity field.
fields can either be text fields for free text or combo boxes if have
ontology to browse - CharFieldGui does either - with get/setText - hides the
details of the gui - just a field that gives text
ListSelectionListener listening to events from table selection (make inner class?)
subclasses: TermCompList, FreeTextField,...
do constraint check for commit time - should char list be passed in?
return ConstraintStatus indication if constraint passed and error msg
should only be called if isCommitConstraint is true
do constraint check for commit time - should char list be passed in?
return ConstraintStatus indication if constraint passed and error msg
should only be called if isCommitConstraint is true
do constraint check after user edit - should char list be passed in?
return ConstraintStatus indication if constraint passed and error msg
should only be called if isEditConstraint is true
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?
I think this should be refactored, currently this actually fires off config parsing
this should just keep all the command line state for main to query and use
i dont think config parsing should happen here(?)
in swixml config conf/character_table_panel.xml the save button is set up
to call this method
calls LoadSaveManager saveToDbOrFile() which if has queryable/db adapter
saves to db, otherwise saves to file
this method is fired when comparison button is pressed (if configged)
set up as action in conf/character_table_panel.xml swixml config
bring up comparison window to compare 2 statements - by default only
do 1 comparison at a time (may have pref for doing multiple with commit button?
for now if 2 statements not selected then put up error message
(eventually put drag & drop in comparator)
hmm - so returns true if compare element is set to true or if there
is a comparison field - i think the former way maybe should be phased out??
commenting out former way for now - may phase back in if need to cfg more stuff
about comparisons
a gui for making comparisons between 2 statements/annotations
there is comparison controller stuff in here - listens to gui elements and modifies
model
This is basically a view object for the auto completer - right now used for relations
OBOProperty - but terms should also go in here as OBOObject has both OBOClass and
OBOProperty as subclasses - thats the idea at least - simplify!
This is basically a view object for the auto completer for relations/
OBOProperties
This is pase - been replaced by more general CompletionObject - delete?
CompletionTerm should similarly be replaced by/merged with CompObj i think
thats the idea - then can have general stuff that can do both rels & terms
rather than this separation for it all - this is a first step
This is basically a view object for the auto completer for terms/OBOClass
this has been replaced by CompletionObject - i dont think its used anymore?
and should probably be deleted
Ontology - the initial ontology to search, setOntology changes this,
initially only searches the one ontology (not ALL) - used by servlet which
currently doesnt do ALL
Im realizing now ive done this all wrong - as theres really 2 redundant datamodels
for the config - the xml beans, and phenotes own and there really should be just
the xml beans - then you dont have to do all this back & forth between them
hindsight is 20 20
A constraint returns creates & returns one of these, says whether contraint checks
out ok and gives error message
A constraintStatus is recursive - it can hold ConstraintStatus kids - so if theres
a list of constraints all their status is returned in one ConstraintStatus
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.
Just pastes characters to clipboard for proforma
6/30/06 - changing this to use new Pheno-Syntax - should this be renamed
Pheno-Syntax data adapter? Pheno Syntax need to be able to write to a file
as well as also write to flybases proforma app - i think those are 2 different
data adapters sharing Syntax objects - PhenoSyntaxFileAdapter
and FlybaseProformaAdapter or something like that - todo...
mapping for character to obo annot, used for OBO_ANNOTATION character mode
meaningless in pure character mode, returns BasicAnnotationMappingDriver by
default
return COMPARISON field if have one, if dont should we:
1) create one on demand (like date)? sep method?
2) return null
3) throw ex?
returning null for now
query conf directories in app conf, jar conf(webstart) and .phenote/conf
List? soreted alphabeitcally?
these strings are the actual filenames as in name-with-dash.cfg
Throws exception if there isnt a current relation - for relation lists
(post comp), if the user
has typed something that isnt yet a rel - hasnt selected a rel
OntologyDataAdapter calls this to figure which ontologies to load
This is a list of enabled fields - does not include disabled fields!
retname getEnabledFieldConfigs?
This class will show the details of what's going on in Phenote, including
the details of the ontologies that are loaded, and some general preference
settings.
synchronized so cant reload an ontology while ontologies are being initialized
getInstance calls initOntologies - in other words you have to call getInstance to
initialize the ontologies
synchronized so cant reload an ontology while ontologies are being initialized
getInstance calls initOntologies - in other words you have to call getInstance to
initialize the ontologies
JList? initialize if configged
list gui is the list that is displayed if the field is multi valued - takes
more than one value - NOT the drop down list
Return the amount of letters/chars a user has to type before completion
kicks in - this helps with slow completion with many ontologies on a slow
computer
Send out notification when a new relation has been selected, used by ComparisonGui
avoids hardwiring modifying a particular datamodel like other CharFieldGuis(refactor)
this could migrate to superclass if needed there
in this directory obo/idw expects to find a file named perspectives.xml
which then points to idw files in this same directory
obo can get this from a jar but doesnt work from webstart jar???
FileNotFoundException printed to stdout if not found and no perspectives
come up
this is funny for TermCompList this is a CompletionTerm, for RelationCompList this
is a RelationTerm - with new OboObject interface these should be merged!
this returns a String if the user has not selected a term in the list yet
the String is the current User input - rename this!
peculiar that the method called is getSelectedItem as the String was
never actually selected
so with KeyListener on JTextField when get key selectedObj is a null state
so returns null if so - can get text straight from TextField in this case
if need it
gets from datatag then label if no syntax abbrev explicitly set,
replaces spaces with underscores in label
as pheno syntax is sensitive to spaces (in theory at least)
Tag is what comes from datatag in config, used for referencing field
(like from smart atlas servlet), and as dangling prefix for obo
mapping, if datatag not set in config, returns name
just gets useTermListener from terminfotoolbar, which back & forward
action use, which actually probably isnt right as back & forward
might be hitting terms with different use term listeners
but good enough for now
This method iterates through each character in the main data list and checks to see if it is a valid character for
the given row and given column in the matrix.
returns string for charfield value of char field, no matter what type,
return "" if null value?? throw ex? used for sorting CharList
this returns names not ids for terms
group adapters
originally were groups of fields this is not, but one thing group adapters do is make
terms/ontology on the fly - and thats what this does - but it does make ya wanna
change the name of GroupAdap if it applies to things that arent even groups of terms
maybe TermMaker?
theres really 2 things going on - grouping of fields and making of terms - and
character template which is a grouping of fields but it makes truncated char lists
not terms - but char temp is not a group adapteri but maybe should be?
- hmmmm - i think grouping of fields needs to be separated from making of terms
and making of characters - i think group adapter should be renamed TermMaker
as thats what it is!
and config should change with it - maybe call "plugin" in config instead of group?
Also im wondering if char change listener and char list change listener
should just be replaced with a TermListChange event? to make it more
destination oriented and less about the source? a listener just cares if
theres new terms - a listener doesnt care if that happened via char list or char
change or who knows what
also setDestinationField needs to take a list
This should be replaced by OntologyMakerI - phase out!
thiscould be CharOntMakerI but i dont think thats necasary
If a group reacts to char changes(edits) then a char change listener should be
added, for instance a user edits group fields and dest field is automatically
repopulated, otherwise no-op
uses contains which uses equals, which tests the value/term/string in
CharFieldValue, NOT if its the same CharFieldValue object!
so if CFV with same term but different Character will be true
an OBOObject can be an OBOClass or an OBOProperty and other obo thingies
return true if is term and obj is oboClassValue
using oboObject instead of OBOClass so can use same method for other obo objects
According to the CharacterI documentation, the methods below are garbage
They are here for backward compatibility - still used in nexus & phenoxml adapter
but they should be upgraded to new generic way at some point
need to keep in for now
for now this is just a free text field that checks if theres a ":" present
eventually may get more savvy with option of prepending an id prefix and
using OBOInstance instead of String
args are command line arguments
if doSplash is true then display phenote elephant splash screen
the splash screen comes up blank for plus - needs to be fixed as
its a nice splash.
Tries out dimensionInfo array trying to find biggest dimensions for
frame/window that will fit on screen - couldnt this also just do a
percentage of screen size - also should have configurable override
whether field is auto generated when creating new annotations, for instance
date_created is automatically set with every new annotation
eventually will have user & date_last_update as well...
If a CharField is compound, there is another group of fields in the config which
the value of this field can be parsed into - this is used by the CharacterListFieldGui.
Currently this returns true if there has been any non-add(add blank row) edits
However if one does an edit and then does undo this will still return true.
Changed this to actually do updating of config file by default given that this
is now the route in from webstart, without this users will never get config
updates - eventually get more sophisticated - give user options of
updateFromDefault, revertToMain/Default or personal/ignoreMain/dontupdate
CharFieldGui for main window not post comp box - factory method, make appropriate
CFG subclass from type of charField - minCompChars is not used at moment - may
come back
the idea for the tab-delimited output writer is to
1) identify what the header/column names should be (like they present in the phenote
window: pub, entity, quality, etc.).
If list adds to value, if not list just sets it, makes new CFV
This is used by CharacterListFieldGui (for template) but i dont understand how it
works for lists - newList and newValue never seem to connect - jim???
Given array of column headers and index col to start looking, find next valid
field -- a field that is in datamodel/configged -- and return Parser for it
throws DelimitedEx if fails to find a char field for all headers at index col
and greater
a user has requested to make a new ontology from proforma
bring up file chooser for them to select proforma file,
and then parse it and populate field with ontology from parse
set up as action method in character_table_panel.xml swix config make
terms button has been hit by user - go off and make terms if we have a
TermMaker - otherwise do nothing - error msg, this assumes for moment
that there is only 1 term maker - if we need more than need to deal with
that
if free text returns string charfieldValue, for ontology field valueString is
id and searches ontologies for id, throws CharFieldException if invalid date for
date field (used to for term not found but now creates dangler instead)
this deals with postcomp too)
if term is dangler then dangler gets id (valueString) but no name
use makeValue(Char,String,String) to get dangler name set as well
also deals with lists in format: "xxx","yyy",...
makes value - value string for term is id - if term is dangler (not in ontology)
and danglerName is non null, then danglers name is set to danglerName,
danglerName is ONLY used for danglers