|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ptc.windchill.enterprise.templates.TemplatesUtility
Makes template functions available for UI processing used during Create
Template and Create from Template.
Supported API: false
Extendable: false
Field Summary | |
private static AttributeHelper |
attributeHelper
|
private static String |
CLASSNAME
|
static long |
EXTERNALIZATION_VERSION_UID
|
protected static long |
OLD_FORMAT_VERSION_UID
|
private static String |
RESOURCE
|
(package private) static long |
serialVersionUID
|
private static boolean |
VERBOSE
|
Constructor Summary | |
TemplatesUtility()
|
Method Summary | |
protected static String |
changeFilename(String origFilename,
String format,
FormatContentHolder contentHolder)
Performs the filename conversion during a Create from Template action. |
static void |
disablePriorIterations(Templateable obj)
A method that uses a Templateable object as the input and disables the previously enabled version/iteration if the current iteration is enabled. |
protected static String |
getAttributeValue(FormatContentHolder contentHolder,
String attrName)
Returns the value for the requested attribute from the given object. |
static String |
getEnabledVersionString(Templateable object)
A method that uses a Templateable object as the input and returns the enabled version.iteration string of that object. |
static String |
getFilenameFormat()
Returns the value stored in the site preference com/ptc/windchill/enterprise/templates/doc/renameFileFormatOnCreateFromTemplate. |
static Templateable |
getLatestVersionIteration(Templateable obj)
A method that takes a Templateable object as the input and returns the latest iteration of the latest version of the object. |
static Persistable[] |
getTemplates(Class objClass,
String context)
Return a vector to represent the template list. |
static TypeIdentifier[] |
getTemplateTypes(Class objClass,
String context)
Return an array of the types of an object that a template can be created with. |
void |
readExternal(ObjectInput input)
Reads the non-transient fields of this class from an external source. |
private boolean |
readOldVersion(ObjectInput input,
long readSerialVersionUID,
boolean passThrough,
boolean superDone)
Reads the non-transient fields of this class from an external source, which is not the current version. |
protected boolean |
readVersion(TemplatesUtility thisObject,
ObjectInput input,
long readSerialVersionUID,
boolean passThrough,
boolean superDone)
Reads the non-transient fields of this class from an external source. |
static RevisionControlled |
saveObjFromTemplate(RevisionControlled object,
Templateable template)
A wrapper function that uses a Templateable object as the input. |
static FormatContentHolder |
setFilename(FormatContentHolder formatContentHolder)
When creating objects from a template (i.e. |
void |
writeExternal(ObjectOutput output)
Writes the non-transient fields of this class to an external source. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final String RESOURCE
private static final String CLASSNAME
static final long serialVersionUID
public static final long EXTERNALIZATION_VERSION_UID
protected static final long OLD_FORMAT_VERSION_UID
private static AttributeHelper attributeHelper
private static final boolean VERBOSE
Constructor Detail |
public TemplatesUtility()
Method Detail |
public void writeExternal(ObjectOutput output) throws IOException
writeExternal
in interface Externalizable
output
-
IOException
public void readExternal(ObjectInput input) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
input
-
IOException
ClassNotFoundException
protected boolean readVersion(TemplatesUtility thisObject, ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone) throws IOException, ClassNotFoundException
thisObject
- input
- readSerialVersionUID
- passThrough
- superDone
-
IOException
ClassNotFoundException
private boolean readOldVersion(ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone) throws IOException, ClassNotFoundException
input
- readSerialVersionUID
- passThrough
- superDone
-
IOException
ClassNotFoundException
public static Persistable[] getTemplates(Class objClass, String context) throws WTException
objClass
- The class of the object that the template list is requested for.context
- The product/library or project that this is requested from.
WTException
public static TypeIdentifier[] getTemplateTypes(Class objClass, String context) throws WTException
objClass
- The class of the object that the template list is requested for.context
- The product/library or project that this is requested from.
WTException
public static RevisionControlled saveObjFromTemplate(RevisionControlled object, Templateable template) throws WTException
object
- Object the template is create from.template
- Template used to create the object from.
WTException
public static FormatContentHolder setFilename(FormatContentHolder formatContentHolder) throws WTException
formatContentHolder
-
WTException
protected static String changeFilename(String origFilename, String format, FormatContentHolder contentHolder) throws WTException
origFilename
- format
- contentHolder
-
WTException
protected static String getAttributeValue(FormatContentHolder contentHolder, String attrName) throws WTException
contentHolder
- attrName
-
WTException
public static String getFilenameFormat()
public static String getEnabledVersionString(Templateable object) throws WTException
object
- Object that implements the Templateable interface
WTException
public static void disablePriorIterations(Templateable obj) throws WTException
WTException
public static Templateable getLatestVersionIteration(Templateable obj) throws WTException
obj
- Object that implements the Templateable interface
WTException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |