## imcode.server.document.textdocument
Class TextDocumentDomainObject

    java.lang.Object
      imcode.server.document.DocumentDomainObject
          imcode.server.document.textdocument.TextDocumentDomainObject

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable

    public class TextDocumentDomainObject

extends DocumentDomainObject

See Also:
  Serialized Form

Nested Class Summary

Nested classes/interfaces inherited from class imcode.server.document.DocumentDomainObject
`DocumentDomainObject.Attributes`

Field Summary

Fields inherited from class imcode.server.document.DocumentDomainObject
`attributes, DOCUMENT_PROPERTIES__IMCMS_DOCUMENT_ALIAS, ID_NEW`

Constructor Summary
`TextDocumentDomainObject()`
`TextDocumentDomainObject(int documentId)`

Method Summary
`void` `accept(DocumentVisitor documentVisitor)`
`TextDocumentDomainObject` `clone()`
`java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,ImageDomainObject>>` `getAllImages()` Returns all images.
`java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,TextDomainObject>>` `getAllTexts()` Returns all texts.
`java.util.Set` `getChildDocumentIds()`
`ContentLoop` `getContentLoop(int loopIndex)`
`java.util.Map<java.lang.Integer,ContentLoop>` `getContentLoopsMap()`
`java.lang.String` `getDefaultTemplateName()`
`java.lang.String` `getDefaultTemplateNameForRestricted1()`
`java.lang.String` `getDefaultTemplateNameForRestricted2()`
`DocumentTypeDomainObject` `getDocumentType()`
`ImageDomainObject` `getImage(I18nLanguage language, int index)` Returns image for language specified.
`ImageDomainObject` `getImage(int imageIndex)` Returns i18n-ed image for language bound to the current thread.
`java.util.Map<java.lang.Integer,ImageDomainObject>` `getImages()`
`java.util.Map<java.lang.Integer,ImageDomainObject>` `getImages(I18nLanguage language)`
`java.lang.Integer` `getIncludedDocumentId(int includeIndex)`
`java.util.Map<java.lang.Integer,java.lang.Integer>` `getIncludesMap()`
`MenuDomainObject` `getMenu(int menuIndex)`
`java.util.Map<java.lang.Integer,MenuDomainObject>` `getMenus()`
`int` `getTemplateGroupId()`
`java.lang.String` `getTemplateName()`
`TemplateNames` `getTemplateNames()`
`TextDomainObject` `getText(I18nLanguage language, int index)`
`TextDomainObject` `getText(int textFieldIndex)`
`java.util.Map<java.lang.Integer,TextDomainObject>` `getTexts()`
`java.util.Map<java.lang.Integer,TextDomainObject>` `getTexts(I18nLanguage language)`
`java.util.Map<java.lang.Integer,TextDomainObject>` `getTextsMap(I18nLanguage language)` Returns all texts for language specified.
`void` `removeAllContentLoops()`
`void` `removeAllImages()` Removes all image.
`void` `removeAllIncludes()`
`void` `removeAllMenus()`
`void` `removeAllTexts()`
`void` `removeInclude(int includeIndex)`
`void` `setAllImages(java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,ImageDomainObject>> images)`
`void` `setAllTexts(java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,TextDomainObject>> texts)`
`void` `setContentLoopsMap(java.util.Map<java.lang.Integer,ContentLoop> contentLoopsMap)`
`void` `setDefaultTemplateId(java.lang.String defaultTemplateId)`
`void` `setDefaultTemplateIdForRestricted1(java.lang.String defaultTemplateIdForRestricted1)`
`void` `setDefaultTemplateIdForRestricted2(java.lang.String defaultTemplateIdForRestricted2)`
`void` `setDependenciesMetaIdToNull()` // TODO: refactor into visitor For legacy code support: When saving document copy as new document its dependencies metaId should be set to null.
`void` `setImage(I18nLanguage language, int index, ImageDomainObject image)` Sets image.
`void` `setImage(int imageIndex, ImageDomainObject image)` Sets image to currently active language.
`void` `setInclude(int includeIndex, int includedDocumentId)`
`void` `setIncludesMap(java.util.Map<java.lang.Integer,java.lang.Integer> includesMap)`
`void` `setMenu(int menuIndex, MenuDomainObject menu)`
`void` `setMenusMap(java.util.Map<java.lang.Integer,MenuDomainObject> menusMap)`
`void` `setTemplateGroupId(int v)`
`void` `setTemplateName(java.lang.String templateName)`
`void` `setTemplateNames(TemplateNames templateNames)`
`void` `setText(I18nLanguage language, int index, TextDomainObject text)` Sets text.
`void` `setText(int textIndex, TextDomainObject text)` Sets text to currently active language.

Methods inherited from class imcode.server.document.DocumentDomainObject

`addCategoryId, addSectionId, equals, fromDocumentTypeId, getActualModifiedDatetime, getAlias, getArchivedDatetime, getAttributes, getCategoryIds, getCreatedDatetime, getCreatorId, getDocumentPermissionSetTypeForRoleId, getDocumentTypeId, getDocumentTypeName, getHeadline, getHeadline, getI18nMeta, getId, getKeywords, getKeywords, getLanguageIso639_2, getLifeCyclePhase, getMenuImage, getMenuImage, getMenuText, getMenuText, getMeta, getModifiedDatetime, getName, getPermissionSets, getPermissionSetsForNewDocuments, getProperties, getProperty, getPublicationEndDatetime, getPublicationStartDatetime, getPublicationStatus, getPublisherId, getRoleIdsMappedToDocumentPermissionSetTypes, getSectionIds, getTarget, hashCode, isActive, isArchived, isLinkableByOtherUsers, isLinkedForUnauthorizedUsers, isPublished, isRestrictedOneMorePrivilegedThanRestrictedTwo, isSearchDisabled, removeAllCategories, removeAllSections, removeCategoryId, removeProperty, setActualModifiedDatetime, setAlias, setArchivedDatetime, setAttributes, setCategoryIds, setCreatedDatetime, setCreator, setCreatorId, setDocumentPermissionSetTypeForRoleId, setHeadline, setHeadline, setId, setKeywords, setLanguageIso639_2, setLinkableByOtherUsers, setLinkedForUnauthorizedUsers, setMenuImage, setMenuText, setMenuText, setMeta, setModifiedDatetime, setPermissionSets, setPermissionSetsForNew, setProperties, setProperty, setPublicationEndDatetime, setPublicationStartDatetime, setPublicationStatus, setPublisher, setPublisherId, setRestrictedOneMorePrivilegedThanRestrictedTwo, setRoleIdsMappedToDocumentPermissionSetTypes, setSearchDisabled, setSectionIds, setTarget`

Methods inherited from class java.lang.Object
`finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### TextDocumentDomainObject

    public TextDocumentDomainObject()

### TextDocumentDomainObject

    public TextDocumentDomainObject(int documentId)

Method Detail

### clone

    public TextDocumentDomainObject clone()

  Overrides:
    `clone` in class `DocumentDomainObject`

### getDocumentType

    public DocumentTypeDomainObject getDocumentType()

  Specified by:
    `getDocumentType` in class `DocumentDomainObject`

### getChildDocumentIds

    public java.util.Set getChildDocumentIds()

### getIncludedDocumentId

    public java.lang.Integer getIncludedDocumentId(int includeIndex)

### getMenu

    public MenuDomainObject getMenu(int menuIndex)

### getText

    public TextDomainObject getText(int textFieldIndex)

### getText

    public TextDomainObject getText(I18nLanguage language,
                                    int index)

  Returns:
    TextDomainObject or null if text can not be found.

### getTextsMap

    public java.util.Map<java.lang.Integer,TextDomainObject> getTextsMap(I18nLanguage language)

  Returns all texts for language specified.

### accept

    public void accept(DocumentVisitor documentVisitor)

  Specified by:
    `accept` in class `DocumentDomainObject`

### removeAllImages

    public void removeAllImages()

  Removes all image.

### removeAllIncludes

    public void removeAllIncludes()

### removeAllMenus

    public void removeAllMenus()

### removeAllContentLoops

    public void removeAllContentLoops()

### removeAllTexts

    public void removeAllTexts()

### setInclude

    public void setInclude(int includeIndex,
                           int includedDocumentId)

### setMenu

    public void setMenu(int menuIndex,
                        MenuDomainObject menu)

### setText

    public void setText(int textIndex,
                        TextDomainObject text)

  Sets text to currently active language.

### setText

    public void setText(I18nLanguage language,
                        int index,
                        TextDomainObject text)

  Sets text.

### getIncludesMap

    public java.util.Map<java.lang.Integer,java.lang.Integer> getIncludesMap()

### getMenus

    public java.util.Map<java.lang.Integer,MenuDomainObject> getMenus()

### getTemplateName

    public java.lang.String getTemplateName()

### getTemplateGroupId

    public int getTemplateGroupId()

### getTexts

    public java.util.Map<java.lang.Integer,TextDomainObject> getTexts()

### getTexts

    public java.util.Map<java.lang.Integer,TextDomainObject> getTexts(I18nLanguage language)

### setTemplateName

    public void setTemplateName(java.lang.String templateName)

### setTemplateGroupId

    public void setTemplateGroupId(int v)

### getDefaultTemplateName

    public java.lang.String getDefaultTemplateName()

### setDefaultTemplateId

    public void setDefaultTemplateId(java.lang.String defaultTemplateId)

### removeInclude

    public void removeInclude(int includeIndex)

### getDefaultTemplateNameForRestricted1

    public java.lang.String getDefaultTemplateNameForRestricted1()

### getDefaultTemplateNameForRestricted2

    public java.lang.String getDefaultTemplateNameForRestricted2()

### setDefaultTemplateIdForRestricted1

    public void setDefaultTemplateIdForRestricted1(java.lang.String defaultTemplateIdForRestricted1)

### setDefaultTemplateIdForRestricted2

    public void setDefaultTemplateIdForRestricted2(java.lang.String defaultTemplateIdForRestricted2)

### getImages

    public java.util.Map<java.lang.Integer,ImageDomainObject> getImages()

  Returns:
    Image id mapped to image for current language.

### getImages

    public java.util.Map<java.lang.Integer,ImageDomainObject> getImages(I18nLanguage language)

  Returns:
    Image id mapped to image for language specified.

### setImage

    public void setImage(int imageIndex,
                         ImageDomainObject image)

  Sets image to currently active language. Not in use.

### setImage

    public void setImage(I18nLanguage language,
                         int index,
                         ImageDomainObject image)

  Sets image.

### getImage

    public ImageDomainObject getImage(int imageIndex)

  Returns i18n-ed image for language bound to the current thread.

  Returns:
    ImageDomainObject for language bound to the current thread.

### getImage

    public ImageDomainObject getImage(I18nLanguage language,
                                      int index)

  Returns image for language specified.

### setDependenciesMetaIdToNull

    public void setDependenciesMetaIdToNull()

  Description copied from class: `DocumentDomainObject`
  // TODO: refactor into visitor For legacy code support: When saving document copy as new document its dependencies metaId should be set to null.

  Overrides:
    `setDependenciesMetaIdToNull` in class `DocumentDomainObject`
  See Also:
    `DocumentSaver.saveNewDocument`

### getTemplateNames

    public TemplateNames getTemplateNames()

### setTemplateNames

    public void setTemplateNames(TemplateNames templateNames)

### setMenusMap

    public void setMenusMap(java.util.Map<java.lang.Integer,MenuDomainObject> menusMap)

### setIncludesMap

    public void setIncludesMap(java.util.Map<java.lang.Integer,java.lang.Integer> includesMap)

### getAllTexts

    public java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,TextDomainObject>> getAllTexts()

  Returns all texts.

### setAllTexts

    public void setAllTexts(java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,TextDomainObject>> texts)

### getAllImages

    public java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,ImageDomainObject>> getAllImages()

  Returns all images.

### setAllImages

    public void setAllImages(java.util.Map<I18nLanguage,java.util.Map<java.lang.Integer,ImageDomainObject>> images)

### getContentLoopsMap

    public java.util.Map<java.lang.Integer,ContentLoop> getContentLoopsMap()

### setContentLoopsMap

    public void setContentLoopsMap(java.util.Map<java.lang.Integer,ContentLoop> contentLoopsMap)

### getContentLoop

    public ContentLoop getContentLoop(int loopIndex)