public final class DocMetadata extends DocumentMetadata<DocMetadataProperty>
Represents metadata in DocumentType.Doc
document.
Constructor and Description |
---|
DocMetadata()
Initializes a new instance of the
DocMetadata class. |
Modifier and Type | Method and Description |
---|---|
void |
add(String key,
boolean value)
Adds metadata with boolean value.
|
void |
add(String key,
Date value)
Adds
DateTime metadata. |
void |
add(String key,
double value)
Adds metadata with double value.
|
void |
add(String key,
int value)
Adds metadata with integer value.
|
void |
add(String key,
String value)
Adds metadata with string value.
|
String |
getAuthor()
Gets the document's author.
|
Integer |
getBytesInDocument()
Gets an estimate of the number of bytes in the document.
|
String |
getCategory()
Gets the category.
|
String |
getComments()
Gets the comments.
|
String |
getCompany()
Gets the company.
|
String |
getContentStatus()
Gets the content status.
|
String |
getContentType()
Gets the content type of the document.
|
Date |
getCreatedTime()
Gets the document created date.
|
DocComment[] |
getDocumentComments()
Gets an array of
DocComment presented in the document. |
String |
getHyperlinkBase()
Gets the hyperlink base.
|
protected DocMetadataProperty |
getInstance() |
String |
getKeywords()
Gets the keywords.
|
Date |
getLastPrintedDate()
Gets the last printed date.
|
String |
getLastSavedBy()
Gets the name of the last author.
|
Date |
getLastSavedTime()
Gets the time of the last save.
|
boolean |
getLinksUpToDate()
Gets a value indicating whether the hyperlinks in the document are up-to-date.
|
String |
getManager()
Gets the manager.
|
String |
getNameOfApplication()
Gets the name of the application.
|
int |
getRevisionNumber()
Gets the revision number.
|
String |
getSubject()
Gets the subject.
|
String |
getTemplate()
Gets the template.
|
String |
getTitle()
Gets the title of the document.
|
String[] |
getTitlesOfParts()
Gets the titles of document parts.
|
int |
getTotalEditingTime()
Gets the total editing time in minutes.
|
int |
getVersion()
Gets the version number of the application that created the document.
|
boolean |
isBuiltIn(String key)
Determines whether metadata is built-in.
|
boolean |
isReadOnly(String key)
Returns true if
<b>built-in</b> metadata key is read-only in Word document. |
boolean |
remove(String key)
Removes existing metadata property by key.
|
void |
setAuthor(String value)
Sets the document's author.
|
void |
setCategory(String value)
Sets the category.
|
void |
setComments(String value)
Sets the comments.
|
void |
setCompany(String value)
Sets the company.
|
void |
setContentStatus(String value)
Sets the content status.
|
void |
setContentType(String value)
Sets the content type of the document.
|
void |
setCreatedTime(Date value)
Sets the document created date.
|
void |
setHyperlinkBase(String value)
Sets the hyperlink base.
|
void |
setKeywords(String value)
Sets the keywords.
|
void |
setLastPrintedDate(Date value)
Sets the last printed date.
|
void |
setLastSavedBy(String value)
Sets the name of the last author.
|
void |
setLastSavedTime(Date value)
Sets the time of the last save.
|
void |
setLinksUpToDate(boolean value)
Sets a value indicating whether the hyperlinks in the document are up-to-date.
|
void |
setManager(String value)
Sets the manager.
|
void |
setRevisionNumber(int value)
Sets the revision number.
|
void |
setSubject(String value)
Sets the subject.
|
void |
setTemplate(String value)
Sets the template.
|
void |
setTitle(String value)
Sets the title of the document.
|
void |
setTotalEditingTime(int value)
Sets the total editing time in minutes.
|
clear, clearBuiltInData, clearCustomData, containsKey, getCollection, getCount, readPropertyValue, setValueByKey
getByType, getKeys, getMetadataType, iterator, readByStringKey
public DocMetadata()
Initializes a new instance of the DocMetadata
class.
public final String getAuthor()
Gets the document's author.
public final void setAuthor(String value)
Sets the document's author.
value
- The author.public final Integer getBytesInDocument()
Gets an estimate of the number of bytes in the document.
public final String getCategory()
Gets the category. Cannot be updated in ODT.
public final void setCategory(String value)
Sets the category. Cannot be updated in ODT.
value
- The category.public final String getComments()
Gets the comments.
public final void setComments(String value)
Sets the comments.
value
- The comments.public final String getCompany()
Gets the company.
public final void setCompany(String value)
Sets the company.
value
- The company.public final String getContentStatus()
Gets the content status.
public final void setContentStatus(String value)
Sets the content status.
value
- The content status.public final String getContentType()
Gets the content type of the document.
public final void setContentType(String value)
Sets the content type of the document.
value
- The type of the content.public final Date getCreatedTime()
Gets the document created date.
public final void setCreatedTime(Date value)
Sets the document created date.
value
- The created time.public final String getHyperlinkBase()
Gets the hyperlink base.
public final void setHyperlinkBase(String value)
Sets the hyperlink base.
value
- The hyperlink base.public final String getKeywords()
Gets the keywords.
public final void setKeywords(String value)
Sets the keywords.
value
- The keywords.public final String getSubject()
Gets the subject.
public final void setSubject(String value)
Sets the subject.
value
- The subject.public final String getTemplate()
Gets the template.
public final void setTemplate(String value)
Sets the template.
value
- The template.public final Date getLastPrintedDate()
Gets the last printed date.
public final void setLastPrintedDate(Date value)
Sets the last printed date.
value
- The last printed date.public final String getLastSavedBy()
Gets the name of the last author.
public final void setLastSavedBy(String value)
Sets the name of the last author.
value
- The name of the last author.public final Date getLastSavedTime()
Gets the time of the last save.
public final void setLastSavedTime(Date value)
Sets the time of the last save.
value
- The time of the last save.public final String getManager()
Gets the manager.
public final void setManager(String value)
Sets the manager.
value
- The manager.public final String getNameOfApplication()
Gets the name of the application.
public final int getRevisionNumber()
Gets the revision number.
public final void setRevisionNumber(int value)
Sets the revision number.
value
- The revision number.public final int getVersion()
Gets the version number of the application that created the document.
When a document was created by Microsoft Word, then high 16 bit represent the major version and low 16 bit represent the build number.
public final int getTotalEditingTime()
Gets the total editing time in minutes.
public final void setTotalEditingTime(int value)
Sets the total editing time in minutes.
value
- The total editing time in minutes.public final String getTitle()
Gets the title of the document.
public final void setTitle(String value)
Sets the title of the document.
value
- The title of the document.public final boolean getLinksUpToDate()
Gets a value indicating whether the hyperlinks in the document are up-to-date.
public final void setLinksUpToDate(boolean value)
Sets a value indicating whether the hyperlinks in the document are up-to-date.
value
- A value indicating whether the hyperlinks in the document are up-to-date.public final String[] getTitlesOfParts()
Gets the titles of document parts. Read-only.
public final DocComment[] getDocumentComments()
Gets an array of DocComment
presented in the document.
public boolean remove(String key)
Removes existing metadata property by key.
remove
in class DocumentMetadata<DocMetadataProperty>
key
- Metadata key.public final void add(String key, String value)
Adds metadata with string value.
key
- Metadata key.value
- Metadata value.public final void add(String key, boolean value)
Adds metadata with boolean value.
key
- Metadata key.value
- Metadata value.public final void add(String key, Date value)
Adds DateTime
metadata.
key
- Metadata key.value
- Metadata value.public final void add(String key, int value)
Adds metadata with integer value.
key
- Metadata key.value
- Metadata value.public final void add(String key, double value)
Adds metadata with double value.
key
- Metadata key.value
- Metadata value.public boolean isBuiltIn(String key)
Determines whether metadata is built-in.
isBuiltIn
in class DocumentMetadata<DocMetadataProperty>
key
- Metadata key.ArgumentNullException
- Key could not be null or empty.public boolean isReadOnly(String key)
Returns true if <b>built-in</b>
metadata key is read-only in Word document.
isReadOnly
in class DocumentMetadata<DocMetadataProperty>
key
- Metadata key.protected DocMetadataProperty getInstance()
getInstance
in class DocumentMetadata<DocMetadataProperty>
Copyright © 2019. All rights reserved.