Commons Library Reference
Overview
The extension program comes with an extensive library of common APIs that can help you program your extension.
Please note only APIs that are documented here are supported and all APIs come with a limited liability license e.g. You are responsible for the testing and usage
wt-framework-commons
Query Helper
This is a general purpose helper that is used extensively to find a Windchill Object from an OID (unique object identifier).
import com.wincomplm.wex.wt.framework.commons.persist.WexQueryHelper;
WTPart part = (WTPart) WexQueryHelper.getObject(oid);
String oid = WexQueryHelper.getOid(part);
Work in progress helper
The Work In Progress helper is mainly used to check-in and out Windchill Objects:
import com.wincomplm.wex.wt.framework.commons.wip.WexWipHelper;
WexWipHelper wexWipHelper = new WexWipHelper();
wexWipHelper.doCheckout(part)
This commons is used to hold APIs that make using Windchill APIs easier. It is an abstraction of these APIs,
Windchill System Info
This class allows you to interrogate the Windchill you are running is to find out information on its major version e.g. 12.0, or minor version aka MO
Usage
import com.wincomplm.wex.wt.framework.commons.system.WindchillSystemInfo;
WindchillSystemInfo windchillSystemInfo = WindchillSystemInfo.newWindchillSystemInfo();
String wcrelase = windchillSystemInfo.getRelease(); // e.g. 12.0