Package org.eclipse.jface.text.templates.persistence

# Class TemplatePersistenceData

java.lang.Object
org.eclipse.text.templates.TemplatePersistenceData
org.eclipse.jface.text.templates.persistence.TemplatePersistenceData

@Deprecated public class TemplatePersistenceData extends TemplatePersistenceData
Deprecated.
See `TemplatePersistenceData`
TemplatePersistenceData stores information about a template. It uniquely references contributed templates via their id. Contributed templates may be deleted or modified. All template may be enabled or not.

Clients may use this class, although this is not usually needed except when implementing a custom template preference page or template store. This class is not intended to be subclassed.

Since:
  3.0
Restriction:
  This class is not intended to be subclassed by clients.

## Constructor Summary

Constructors
Constructor
Description
`TemplatePersistenceData(Template template, boolean enabled)`
Deprecated.
`TemplatePersistenceData(Template template, boolean enabled, String id)`
Deprecated.
`TemplatePersistenceData(TemplatePersistenceData data)`
Deprecated.

## Method Summary

Modifier and Type
Method
Description
`boolean`
`equals(Object other)`
Deprecated.
`String`
`getId()`
Deprecated.
`Template`
`getTemplate()`
Deprecated.
`protected UUID`
`getUniqueIdForEquals()`
Deprecated.
`int`
`hashCode()`
Deprecated.
`boolean`
`isCustom()`
Deprecated.
`boolean`
`isDeleted()`
Deprecated.
`boolean`
`isEnabled()`
Deprecated.
`boolean`
`isModified()`
Deprecated.
`boolean`
`isUserAdded()`
Deprecated.
`void`
`revert()`
Deprecated.
`void`
`setDeleted(boolean isDeleted)`
Deprecated.
`void`
`setEnabled(boolean isEnabled)`
Deprecated.
`void`
`setTemplate(Template template)`
Deprecated.

### Methods inherited from class org.eclipse.text.templates.TemplatePersistenceData

`getUniqueIdForEquals`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### TemplatePersistenceData

@Deprecated public TemplatePersistenceData(TemplatePersistenceData data)
Deprecated.
In some cases, we must continue to respect the deprecated TemplatePresistenceData even though we are given `TemplatePersistenceData`.

Parameters:
  `data` - The `TemplatePersistenceData` that will underlie this object.
Since:
  3.14

### TemplatePersistenceData

@Deprecated public TemplatePersistenceData(Template template, boolean enabled)
Deprecated.

### TemplatePersistenceData

@Deprecated public TemplatePersistenceData(Template template, boolean enabled, String id)
Deprecated.

## Method Details

### getId

@Deprecated public String getId()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns the id of this template store, or `null` if there is none.

Overrides:
  `getId` in class `TemplatePersistenceData`
Returns:
  the id of this template store

### isDeleted

@Deprecated public boolean isDeleted()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns the deletion state of the stored template. This is only relevant of contributed templates.

Overrides:
  `isDeleted` in class `TemplatePersistenceData`
Returns:
  the deletion state of the stored template

### setDeleted

@Deprecated public void setDeleted(boolean isDeleted)
Deprecated.
Description copied from class: `TemplatePersistenceData`
Sets the deletion state of the stored template.

Overrides:
  `setDeleted` in class `TemplatePersistenceData`
Parameters:
  `isDeleted` - the deletion state of the stored template

### getTemplate

@Deprecated public Template getTemplate()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns the template encapsulated by the receiver.

Overrides:
  `getTemplate` in class `TemplatePersistenceData`
Returns:
  the template encapsulated by the receiver

### setTemplate

@Deprecated public void setTemplate(Template template)
Deprecated.
Description copied from class: `TemplatePersistenceData`
Sets the template encapsulated by the receiver.

Overrides:
  `setTemplate` in class `TemplatePersistenceData`
Parameters:
  `template` - the new template

### isCustom

@Deprecated public boolean isCustom()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns whether the receiver represents a custom template, i.e. is either a user-added template or a contributed template that has been modified.

Overrides:
  `isCustom` in class `TemplatePersistenceData`
Returns:
  `true` if the contained template is a custom template and cannot be reconstructed from the contributed templates

### isModified

@Deprecated public boolean isModified()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns whether the receiver represents a modified template, i.e. a contributed template that has been changed.

Overrides:
  `isModified` in class `TemplatePersistenceData`
Returns:
  `true` if the contained template is contributed but has been modified, `false` otherwise

### isUserAdded

@Deprecated public boolean isUserAdded()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns `true` if the contained template was added by a user, i.e. does not reference a contributed template.

Overrides:
  `isUserAdded` in class `TemplatePersistenceData`
Returns:
  `true` if the contained template was added by a user, `false` otherwise

### revert

@Deprecated public void revert()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Reverts the template to its original setting.

Overrides:
  `revert` in class `TemplatePersistenceData`

### isEnabled

@Deprecated public boolean isEnabled()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Returns the enablement state of the contained template.

Overrides:
  `isEnabled` in class `TemplatePersistenceData`
Returns:
  the enablement state of the contained template

### setEnabled

@Deprecated public void setEnabled(boolean isEnabled)
Deprecated.
Description copied from class: `TemplatePersistenceData`
Sets the enablement state of the contained template.

Overrides:
  `setEnabled` in class `TemplatePersistenceData`
Parameters:
  `isEnabled` - the new enablement state of the contained template

### equals

@Deprecated public boolean equals(Object other)
Deprecated.

Overrides:
  `equals` in class `TemplatePersistenceData`

### hashCode

@Deprecated public int hashCode()
Deprecated.

Overrides:
  `hashCode` in class `TemplatePersistenceData`

### getUniqueIdForEquals

@Deprecated protected UUID getUniqueIdForEquals()
Deprecated.
Description copied from class: `TemplatePersistenceData`
Required to support equals() with deprecated type org.eclipse.jface.text.templates.persistence.TemplatePersistenceData.

Overrides:
  `getUniqueIdForEquals` in class `TemplatePersistenceData`
Returns:
  unique id to support `TemplatePersistenceData.equals(Object)`