TemplatePersistenceData
@Deprecated public class TemplatePersistenceData extends org.eclipse.text.templates.TemplatePersistenceData
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.
Constructor and Description |
---|
TemplatePersistenceData(Template template,
boolean enabled)
Deprecated.
|
TemplatePersistenceData(Template template,
boolean enabled,
String id)
Deprecated.
|
TemplatePersistenceData(org.eclipse.text.templates.TemplatePersistenceData data)
Deprecated.
In some cases, we must continue to respect the deprecated TemplatePresistenceData
even though we are given
TemplatePersistenceData . |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object other)
Deprecated.
|
String |
getId()
Deprecated.
Returns the id of this template store, or
null if there is none. |
Template |
getTemplate()
Deprecated.
Returns the template encapsulated by the receiver.
|
int |
hashCode()
Deprecated.
|
boolean |
isCustom()
Deprecated.
Returns whether the receiver represents a custom template, i.e. is either
a user-added template or a contributed template that has been modified.
|
boolean |
isDeleted()
Deprecated.
Returns the deletion state of the stored template.
|
boolean |
isEnabled()
Deprecated.
Returns the enablement state of the contained template.
|
boolean |
isModified()
Deprecated.
Returns whether the receiver represents a modified template, i.e. a
contributed template that has been changed.
|
boolean |
isUserAdded()
Deprecated.
Returns
true if the contained template was added by a
user, i.e. does not reference a contributed template. |
void |
revert()
Deprecated.
Reverts the template to its original setting.
|
void |
setDeleted(boolean isDeleted)
Deprecated.
Sets the deletion state of the stored template.
|
void |
setEnabled(boolean isEnabled)
Deprecated.
Sets the enablement state of the contained template.
|
void |
setTemplate(Template template)
Deprecated.
Sets the template encapsulated by the receiver.
|
public TemplatePersistenceData(org.eclipse.text.templates.TemplatePersistenceData data)
TemplatePersistenceData
.data
- The TemplatePersistenceData
that will
underlie this object.public TemplatePersistenceData(Template template, boolean enabled)
public String getId()
org.eclipse.text.templates.TemplatePersistenceData
null
if there is none.getId
in class org.eclipse.text.templates.TemplatePersistenceData
public boolean isDeleted()
org.eclipse.text.templates.TemplatePersistenceData
isDeleted
in class org.eclipse.text.templates.TemplatePersistenceData
public void setDeleted(boolean isDeleted)
org.eclipse.text.templates.TemplatePersistenceData
setDeleted
in class org.eclipse.text.templates.TemplatePersistenceData
isDeleted
- the deletion state of the stored templatepublic Template getTemplate()
org.eclipse.text.templates.TemplatePersistenceData
getTemplate
in class org.eclipse.text.templates.TemplatePersistenceData
public void setTemplate(Template template)
org.eclipse.text.templates.TemplatePersistenceData
setTemplate
in class org.eclipse.text.templates.TemplatePersistenceData
template
- the new templatepublic boolean isCustom()
org.eclipse.text.templates.TemplatePersistenceData
isCustom
in class org.eclipse.text.templates.TemplatePersistenceData
true
if the contained template is a custom
template and cannot be reconstructed from the contributed
templatespublic boolean isModified()
org.eclipse.text.templates.TemplatePersistenceData
isModified
in class org.eclipse.text.templates.TemplatePersistenceData
true
if the contained template is contributed but has been modified, false
otherwisepublic boolean isUserAdded()
org.eclipse.text.templates.TemplatePersistenceData
true
if the contained template was added by a
user, i.e. does not reference a contributed template.isUserAdded
in class org.eclipse.text.templates.TemplatePersistenceData
true
if the contained template was added by a user, false
otherwisepublic void revert()
org.eclipse.text.templates.TemplatePersistenceData
revert
in class org.eclipse.text.templates.TemplatePersistenceData
public boolean isEnabled()
org.eclipse.text.templates.TemplatePersistenceData
isEnabled
in class org.eclipse.text.templates.TemplatePersistenceData
public void setEnabled(boolean isEnabled)
org.eclipse.text.templates.TemplatePersistenceData
setEnabled
in class org.eclipse.text.templates.TemplatePersistenceData
isEnabled
- the new enablement state of the contained template
Copyright (c) 2000, 2018 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.