public class TdbFieldDesign extends java.lang.Object implements com.tietoenator.trip.jxp.internal.utils.DOMSink, java.lang.Comparable<TdbFieldDesign>
Constructor and Description |
---|
TdbFieldDesign()
Constructor, creates a blank field design
|
TdbFieldDesign(TdbFieldDesign src)
Copy constructor
|
Modifier and Type | Method and Description |
---|---|
void |
clear()
Clear the contents of the field design, reset all values to their
default state.
|
int |
compareTo(TdbFieldDesign field)
Order this object with relation to another -- required to be able to sort a
collection of these objects.
|
void |
copyFrom(TdbFieldDesign src)
Initialize this instance from the source provided
|
boolean |
equals(java.lang.Object o)
Compares to another object; equality is defined by field number only
|
java.lang.String |
getCopyrightHolderField()
Retrieve the name of the field in which the name or identifier of the
copyright holder of the information contained within this field can be found.
|
int |
getCost()
Retrieve the field's cost, that is the unit cost that is reported in the
server's debit logfile every time a user views the content of the field.
|
TdbDefaultFunction |
getDefaultFunction()
Retrieve the function id that will be run to create default field content if no other
values are provided.
|
java.lang.String |
getDefaultValue()
Retrieve the value that is applied to the field if no other values are provided.
|
java.lang.String |
getDescription()
Retrieve any comment or description associated with the field design
|
java.lang.String |
getIndexAse()
Retrieve the name of an ASE function called when scanning terms in this field during
indexing.
|
int |
getIndexMode()
Retrieve the index mode of the field.
|
java.lang.String |
getLoadAse()
Retrieve the name of an ASE function called when storing values in this field
using the TFORM load utility (BAFFIT)
|
int |
getMaxItems()
Retrieve the maximum number of items (subfields / paragraphs) that the field
can validly contain.
|
int |
getMinItems()
Retrieve the minimum number of items (subfields / paragraphs) that the field
can validly contain.
|
java.lang.String |
getName()
Retrieve the name of the field
|
int |
getNumber()
Retrieve the field's unique ID
|
java.lang.String |
getRestriction()
Retrieve any restriction value associated with the field.
|
java.lang.String |
getType()
Retrieve the type of the field, e.g.
|
TdbFieldType |
getTypeId()
Retrieve the type of the field as an ID, therefore dialect-indepedent
|
boolean |
getUsesPattern()
Check if this field's data restrictions are to be evaluated as a pattern
(a regular expression).
|
boolean |
getUsesReference()
Check if this field's data restrictions are to be interpreted as a reference
to a field in another database.
|
boolean |
isFieldIndexed()
Check if the index for this field should be constructed
and stored separately from that for other fields within the database.
|
boolean |
isIncludedInTextProcessing()
Check if this field is included in non-Boolean text processing, e.g.
|
boolean |
isIndexed()
Check if this field is indexed in any way.
|
boolean |
isOriginalLayout()
Check if the field is stored in original layout, or if TRIP will compress white space
when storing field values.
|
boolean |
isPartField()
Check if this field is a member of the part record structure
|
boolean |
isPartNameField()
Check if this field is the part record name field
|
boolean |
isRecordNameField()
Check if this field is the record name field, i.e.
|
boolean |
isRecordNumberField()
Check if this field is the record number field
|
boolean |
isUnique()
Check if field values are to be validated for uniqueness.
|
boolean |
isWordIndexed()
Check if the index for this (PHrase-only) field should
consist of the phrase and its constituent words (false), or whether only the
constituent words (true) should be indexed and not the containing phrase.
|
void |
setCopyrightHolderField(java.lang.String name)
Establish the name of the field in which the name or identifier of the
copyright holder of the information contained within this field can be found.
|
void |
setCost(int cost)
Establish the field's cost, that is the unit cost that is reported in the
server's debit logfile every time a user views the content of the field.
|
void |
setDefaultFunction(TdbDefaultFunction func)
Establish the function id that will be run to create default field content if no other
values are provided.
|
void |
setDefaultValue(java.lang.String value)
Establish the value that is to be applied to the field if no other values are provided.
|
void |
setDescription(java.lang.String comment)
Establish a comment or description to be associated with the field design
|
void |
setFieldIndexed(boolean mode)
Establish whether the index for this field should be constructed
and stored separately from that for other fields within the database.
|
void |
setIncludedInTextProcessing(boolean mode)
Establish whether this field is to be included in non-Boolean text processing,
e.g.
|
void |
setIndexAse(java.lang.String ase)
Establish the name of an ASE function to be called when scanning terms in this field during
indexing.
|
void |
setIndexed(boolean mode)
Establish whether this field is indexed in any way.
|
void |
setIndexMode(int mode)
Establish the index mode of the field.
|
void |
setLoadAse(java.lang.String ase)
Establish the name of an ASE function to be called when storing values in this field
using the TFORM load utility (BAFFIT)
|
void |
setMaxItems(int items)
Establish the maximum number of items (subfields / paragraphs) that the field
can validly contain.
|
void |
setMinItems(int items)
Establish the minimum number of items (subfields / paragraphs) that the field
can validly contain.
|
void |
setName(java.lang.String name)
Establish the name of the field
|
void |
setNumber(int nr)
Assign the field's unique ID.
|
void |
setOriginalLayout(boolean layout)
Establish whether the field is to be stored in original layout, or if TRIP should
compress white space when storing field values.
|
void |
setPartField(boolean flag)
Establish this field as belonging to the part record structure
|
void |
setPartNameField(boolean flag)
Establish whether this field is the part record name field
|
void |
setRecordNameField(boolean flag)
Establish whether this field is the record name field, i.e.
|
void |
setRecordNumberField(boolean flag)
Establish whether this field is the record number field
|
void |
setRestriction(java.lang.String value)
Establish a restriction value associated with the field.
|
void |
setType(java.lang.String type)
Establish the type of the field, e.g.
|
void |
setTypeId(TdbFieldType typeId)
Set the type of the field.
|
void |
setUnique(boolean unique)
Establish whether field values are to be validated for uniqueness.
|
void |
setUsesPattern(boolean flag)
Establish whether this field's data restrictions are to be evaluated as a pattern
(a regular expression).
|
void |
setUsesReference(boolean flag)
Establish whether this field's data restrictions are to be interpreted as a reference
to a field in another database.
|
void |
setWordIndexed(boolean mode)
Establish whether the index for this (PHrase-only) field should
consist of the phrase and its constituent words (false), or whether only the
constituent words (true) should be indexed and not the containing phrase.
|
public TdbFieldDesign()
public TdbFieldDesign(TdbFieldDesign src)
src
- Copy sourcepublic java.lang.String getName()
public void setName(java.lang.String name)
name
- Field namepublic java.lang.String getType()
public void setType(java.lang.String type)
type
- Field typepublic java.lang.String getCopyrightHolderField()
public void setCopyrightHolderField(java.lang.String name)
name
- Copyright holder fieldpublic java.lang.String getDescription()
public void setDescription(java.lang.String comment)
comment
- Field commentpublic java.lang.String getRestriction()
getUsesPattern
and getUsesReference
.public void setRestriction(java.lang.String value)
getUsesPattern
and getUsesReference
.value
- Restriction valuepublic boolean getUsesPattern()
getRestriction
is the pattern to
which field values must conform.public void setUsesPattern(boolean flag)
setRestriction
is the pattern to
which field values must conform.flag
- true if field values must conform to a patternpublic boolean getUsesReference()
getRestriction
is the name of the
database and field (using the normal "Database.Field" syntax) where the list
of valid values for this field can be foundpublic void setUsesReference(boolean flag)
setRestriction
is the name of the
database and field (using the normal "Database.Field" syntax) where the list
of valid values for this field can be foundflag
- true if field values must conform to values in another databasepublic java.lang.String getLoadAse()
public void setLoadAse(java.lang.String ase)
ase
- Load ASE namepublic java.lang.String getIndexAse()
public void setIndexAse(java.lang.String ase)
ase
- Index ASE namepublic java.lang.String getDefaultValue()
getDefaultFunction
for more flexibility.public void setDefaultValue(java.lang.String value)
getDefaultFunction
for more flexibility.value
- Default field valuepublic TdbDefaultFunction getDefaultFunction()
public void setDefaultFunction(TdbDefaultFunction func)
func
- Default field functionpublic boolean isOriginalLayout()
public void setOriginalLayout(boolean layout)
layout
- true if the field is to be compressed.public boolean isUnique()
public void setUnique(boolean unique)
unique
- true if field values must be uniquepublic boolean isRecordNameField()
public void setRecordNameField(boolean flag)
flag
- true if the field is the record name fieldpublic boolean isRecordNumberField()
public void setRecordNumberField(boolean flag)
flag
- true if the field is the record number fieldpublic boolean isPartNameField()
public void setPartNameField(boolean flag)
flag
- true if the field is the part record name fieldpublic boolean isPartField()
public void setPartField(boolean flag)
flag
- true if this field is to be in the part record structurepublic TdbFieldType getTypeId()
public void setTypeId(TdbFieldType typeId)
typeId
- A TdbFieldType enum indicating the field type.public int getIndexMode()
isIndexed
,
isFieldIndexed
, isWordIndexed
, and
isIncludedInTextProcessing
public void setIndexMode(int mode)
setIndexed
,
setFieldIndexed
,
setWordIndexed
, and
setIncludedInTextProcessing
mode
- Index modepublic boolean isIndexed()
public void setIndexed(boolean mode)
mode
- If this value is false, all indexing flags are removed for
the field; if true, the field is enabled for indexing and the type of
indexing can be further modified using other index-related methods.public boolean isFieldIndexed()
public void setFieldIndexed(boolean mode)
mode
- true if the field is to be setup for separate field-level indexingpublic boolean isWordIndexed()
public void setWordIndexed(boolean mode)
mode
- true if the PHrase field is setup for word-level indexingpublic boolean isIncludedInTextProcessing()
public void setIncludedInTextProcessing(boolean mode)
mode
- true if the field is included in text processing (TExt and PHrase only)public int getNumber()
public void setNumber(int nr)
nr
- Field number
Please note that a field's number is set by the server and can't be
modified meaningfully.public int getCost()
public void setCost(int cost)
cost
- Unit costpublic int getMinItems()
public void setMinItems(int items)
items
- Minimum acceptable itemspublic int getMaxItems()
public void setMaxItems(int items)
items
- Maximum acceptable itemspublic void copyFrom(TdbFieldDesign src)
src
- Source from which to copypublic void clear()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- Object with which to comparepublic int compareTo(TdbFieldDesign field)
compareTo
in interface java.lang.Comparable<TdbFieldDesign>
field
- The field to compare to the current; ordering is performed
using the field number only