org.odftoolkit.simple.common.field
public class ReferenceField extends Field
The advantage of entering a reference as a field is that you do not have to adjust the references manually every time you change the document. Just update the fields and the references in the document are updated too.
NOTE: Before the document is opened in any editor, the value of this field maybe invalid.
Modifier and Type | Class and Description |
---|---|
static class |
ReferenceField.DisplayType
A DisplayType specifies the information that a reference field
should display.
|
Field.FieldType
Modifier and Type | Method and Description |
---|---|
void |
appendReferenceTo(OdfElement odfEle,
ReferenceField.DisplayType type)
Append this reference field after the specifics OdfElement.
|
Field.FieldType |
getFieldType()
Return the type of this field.
|
String |
getName()
Get the name of this reference field.
|
OdfElement |
getOdfElement()
Return the instance of OdfElement which presents this structure.
|
void |
setName(String referenceName)
Set the name of this reference field.
|
getComponentByElement, getOwnerDocument, registerComponent, unregisterComponent
public void setName(String referenceName)
referenceName
- the name of this content.public String getName()
public void appendReferenceTo(OdfElement odfEle, ReferenceField.DisplayType type)
odfEle
- the reference of odf element.type
- the display type.public OdfElement getOdfElement()
Component
getOdfElement
in class Component
public Field.FieldType getFieldType()
Field
getFieldType
in class Field
Copyright © 2010-2014 The Apache Software Foundation. All Rights Reserved.