Community Tip - If community subscription notifications are filling up your inbox you can set up a daily digest and get all your notifications in a single email. X
Is there a go-to document or site that explains how to use ant with Windchill?
I have a lot of manual tasks to automate (deployments, admin tasks…) and have lots of catching up to do. If at least I could take a look at what ant can do, that may fill some of my requirements. So I'm starting with ant and will see how far I get with that.
Thanks!
JL
Running Windchill PDM/Link 10.1 M050 on UNIX RHEL5.
refer
ResourceBuild compiles rbInfo files from the /src directory instead of the /wtCustom directory , which is not a recommended practice. ant -f codebase/MakeJar.xml is needed its the execution.Ex. ResourceBuild com.ptc.ext.*
This command ant -f bin/tools.xml bundle -Dbundle.input=, which fonctions the same way as ResouceBuild, compiles rbInfo files from the /src directory.
Ex. ant -f bin/tools.xml bundle -Dbundle.input=com.acme.*
This command ant -f bin/tools.xml bundle -Dbundle.input= -Dbundle.source=, will compile rbInfo files from the directory defined by -Dbundle.source:
Ex. ant -f bin\tools.xml bundle -Dbundle.input=example.MySize.* -Dbundle.source=c:\temp
This command ant -f bin/tools.xml class -Dclass.includes= is used to compile Java classes from the directory /src.
Ex. ant -f bin/tools.xml class -Dclass.includes=com/ptc/serviceAcademy/training/*
This command ant -f bin/tools.xml class -Dclass.includes= -Dclass.source= is used to compile Java classes from the directory defined by -Dclass.source:
Ex. ant -f bin/tools.xml class -Dclass.includes=com/ptc/serviceAcademy/training/* -Dclass.source=c:\ext
This command is used to generate the SQL script in the <WC HOME>/db directory. Ex.
ant -f bin/tools.xml sql_script -Dgen.input=com.ptc.serviceAcademy.training.*
Note:
You have to check the directory to see if the classes are generated. Sometimes even it shows Successful in the shell window, but in fact the classes are not truely generated.
- Enumerated types are modeled classes in Windchill, and their location can be derived from their class name. They are stored in [WT_HOME]/codebase/[package structure]/[classname]RB_[locale].ser.
For example, the resource bundle for wt.lifecycle.State is
[WT_HOME]/codebase/wt/lifecycle/StateRB.ser . All resource bundles for enumerated types are capitalized and have the extension “.ser ,” for a serialized Java object.
- There is one modeled metadata resource bundle per package, not per class. For example, both wt.part.WTPart and wt.part.WTPartMaster share the wt.part resource bundle. As a result, they are stored by package name instead of class name in [WT_HOME]/codebase/[package structure]/[package name]ModelRB_[locale].ser.
For example, the resource bundle for the wt.part
package is [WT_HOME]/codebase/wt/part/partModelRB.ser . All resource bundles for modeledmetadata begin with a lowercase letter and have the extension “.ser ,” for a serialized Java object.
Editing Enumerated Type Bundles
- Non-modeled resource bundles are not associated with the object model, so they may be stored anywhere within the codebase directory structure. One example is [WT_HOME]/codebase/wt/change2/change2Resource.class. From its name and package structure, you can infer that this resource bundle contains display text for change objects, but there is no rule enforcing this. Notice that unlike modeled resource bundles, non-modeled bundles have the “.class” extension. They are Java classes instead of serialized Java objects.
Note:
To improve performance, Windchill applets are stored in .jar files on the client computer. These .jar
files include compiled resource bundles. So, to update an applet, the client must re-download an
updated .jar file. The Apache Ant script ant -f codebase/MakeJar.xml custUpdate the .jar file in Windchill and
modifies the timestamp, indicating to the client that it needs to download the new version.