public interface RichAnnotation extends Annotation
Note,
RichAnnotatable| Modifier and Type | Field and Description |
|---|---|
static RichAnnotation |
EMPTY_ANNOTATION |
PROPERTY| Modifier and Type | Method and Description |
|---|---|
void |
addNote(Note note)
Adds a note to this annotation.
|
void |
clear()
Removes all notes from this annotation object.
|
boolean |
contains(Note note)
Returns true if the given note exists in this annotation.
|
Note |
getNote(Note note)
Uses the term and rank to lookup a note in this annotation.
|
Set<Note> |
getNoteSet()
Returns an immutable set of all notes in this annotation.
|
Note[] |
getProperties(Object key)
Find all the
Notes with any rank that match the key. |
void |
removeNote(Note note)
Removes a note from this annotation.
|
void |
setNoteSet(Set<Note> notes)
Clears the notes from this annotation and replaces them with
those from the given set.
|
asMap, containsProperty, getProperty, keys, removeProperty, setPropertyaddChangeListener, addChangeListener, isUnchanging, removeChangeListener, removeChangeListenerstatic final RichAnnotation EMPTY_ANNOTATION
void clear() throws ChangeVetoException
ChangeVetoException - if it couldn't do it.void addNote(Note note) throws ChangeVetoException
note - note to addChangeVetoException - if it doesn't like this.void removeNote(Note note) throws ChangeVetoException
note - note to removeChangeVetoException - if it doesn't like this.Note getNote(Note note) throws NoSuchElementException
note - note to lookup, using term and rank.ChangeVetoException - if it doesn't like this.NoSuchElementException - if it couldn't be found.boolean contains(Note note)
note - note to lookupSet<Note> getNoteSet()
Notevoid setNoteSet(Set<Note> notes) throws ChangeVetoException
notes - a set of Note objects to use from now on.ChangeVetoException - if it doesn't like any of them.NoteNote[] getProperties(Object key)
Notes with any rank that match the key.key - either a String identifier of a term from the
default ontology or a ComparableTermNotes in order of rank or an
empty array if there are no matches. No implementation should ever
return null!Note,
ComparableTermCopyright © 2020 BioJava. All rights reserved.