This class represents an entry (record) from a Toolbox lexicon. Each
entry consists of a collection of fields, stored as a special type of
dictionary which keeps track of the sequence in which its keys were
entered.
|
__init__(self)
This method constructs a new Entry object. |
source code
|
|
string
|
|
|
set_raw_text(self,
rawText)
This method provides access to the raw text from which the Entry
object was parsed. |
source code
|
|
string
|
get_raw_text(self)
This method sets the raw text from which the Entry object was parsed. |
source code
|
|
list of Entry objects
|
|
|
add_subentry(self,
subentry)
This method adds to an entry a subentry, which is simply another
Entry object. |
source code
|
|
|
set_number(self,
number)
This method sets the position of the entry in the dictionary as a
cardinal number. |
source code
|
|
integer
|
get_number(self)
This method obtains the position of the entry in the dictionary as a
cardinal number. |
source code
|
|
list of Field objects
|
get_fields(self)
This method obtains all of the fields found in the Entry object. |
source code
|
|
list
|
|
|
get_values_by_marker(self,
field_marker,
sep=None) |
source code
|
|
string (if sep); otherwise, list of Field objects
|
|
string
|
|
Field object
|
get_field(self,
fieldMarker)
This method returns a particular field given a field marker. |
source code
|
|
|
set_field(self,
fieldMarker,
field)
This method sets a field, given a marker and its associated data. |
source code
|
|
|
|
|
add_field(self,
marker,
value)
This method adds a field to an entry if it does not already exist and
adds a new value to the field of an entry if it does. |
source code
|
|
|
remove_field(self,
fieldMarker)
This method removes from an entry every field for a given field
marker. |
source code
|
|