For a long time, COMs were only able to be applied to leaf features (features that didn't have another feature under any of it's options. With 17.5, changes have been made to support application of COMs to any feature that has a material associated with it. Previously, COM support was handled by the UI and as such, each UI that interacted with Features/Options had to implement support for showing COMs and applying them. In 17.5, this is almost entirely handled by DsDomain and DsPFeatureTVI/DsPMaterialTVI. Most of the changes have been in the behavior of the classes and the removal of special handling for COMs. Migration should only be needed if you relied on the structure of treeOwner on the DsPFeatureTVI and DsPMaterialTVI classes and/or subclasses of DsCOMMaterialCard and DsMaterialDialog.
Order exports now build an option tree before writing Configura SIF or OFDA XML. The selected-option map alone does not contain entries for unselected optional options, and the former export traversal missed subfeatures below selected optional options. The new DsOrderExportOptionInfo tree includes both no-code entries and selected options with their descendants so both formats can export the complete hierarchy.
DsPrdMeasurementColumn now stores its measurement type as a string:
Old: public dsMeasurementType mType Old: public str mTypeS New: public str mType
Replace mTypeS reads with mType. Code that requires dsMeasurementType should convert the string with dsiStrToDsMeasurementTypeEnum().
Both constructors have a new optional package argument:
Old: public constructor(str mType) New: public constructor(str mType, symbol pkg=null) Old: public constructor(dsMeasurementType mType) New: public constructor(dsMeasurementType mType, symbol pkg=null) Added: public double dsUnitConvertFactor(distanceUnit distUnit, str mTypeS)
In DsPData, rename calls or overrides of the part-option row helper and use the new tree hooks for standard data-symbol option rows:
Removed: extend public void generateOptionRows(PartOptionItem opt, DsPart part, SifEnv env, Space space, str featureCode=null, str featureDesc=null) Added: extend public void generatePartOptionRows(PartOptionItem opt, DsPart part, SifEnv env, Space space, str featureCode=null, str featureDesc=null) Added: extend public DsOrderExportOptionInfo[] createOrderExportOptionInfo() Added: extend public DsOrderExportOptionInfo[] createOrderExportOptionInfo(SFeature feat, DsPDataOption parent, int level=0) Added: extend public void addSifOptionRows(DsOrderExportOptionInfo info, SifEnv env, DsPart part, Space space)
The new tree node carries the feature, option, selected option (if any), and child entries:
Added: public class DsOrderExportOptionInfo : unstreamable
The former DsPData optional-select and recursive SIF helpers are removed. Code that called them for standard parts should use the option tree. The freeform-specific helpers now belong to DsFreeformPData:
Removed: extend public void generateOptionalNoOptionRows(SifEnv env, SFeature f, DsiPDataOption selOpt) Removed: extend public void generateOptionalSelOptionRows(SifEnv env, DsPart part, SFeature f, DsiPDataOption selOpt) Removed: extend public void generateOptionalSelOptionRows(SifEnv env, SFeature f, DsiPDataOption selOpt) Removed: final public void generateSifOptionRows(SifEnv env, Option o, DsiPDataOption pO, int level=0) Removed: final public void generateSifOptionRows(SifEnv env, Option o, DsiPDataOption pO, DsPart part=null, int level=0)
DsFreeformPData now provides these helpers for freeform export:
Added: extend public void generateOptionalSelOptionRows(SifEnv env, DsPart part, SFeature f, DsiPDataOption selOpt) Added: final public void generateSifOptionRows(SifEnv env, Option o, DsiPDataOption pO, DsPart part)
In DsPData, the overload that also takes an SFeature remains available for additional rows after a selected option. Pass the feature when replacing either removed overload:
Removed: extend public void generateAdditionalOptionRows(DsiPDataOption dataOpt|, DsPart part, SifEnv env, Space space, bool recurse=true) Removed: extend public void generateAdditionalOptionRows(SpecOption anchorOpt|, DsPart part, SifEnv env, Space space, bool recurse=true)
In DsPart, use addXMLOptions() for tree entries; the two-argument xmlOptions(prefix, buf) entry point remains available:
Removed: extend public void xmlAdditionalOptions(DsiPDataOption dataOpt|, int index, str prefix, XmlStreamBuf buf, bool recurse=true) Removed: extend public void xmlAdditionalOptions(SpecOption anchorOpt|, int index, str prefix, XmlStreamBuf buf, bool recurse=true) Removed: extend public void xmlOptions(str prefix, XmlStreamBuf buf, Option o, DsiPDataOption pO) Removed: extend public void xmlOptionalSelOptions(str prefix, XmlStreamBuf buf, SFeature f, DsiPDataOption selOpt) Added: extend public void addXMLOptions(DsOrderExportOptionInfo info, str prefix, XmlStreamBuf buf, int seq)
DsPDataThe following methods have been removed in DsPData class as they were deprecated or no longer in use.
Removed: public str->(str->(< double, double>)) propagateStretchInfo: copy=null, stream=null, deprecated; Removed: public void postApplyConstraints(DsiApplyConstraintsEnv env) { Removed: extend public void verifySyncGroupContainer(): deprecated { Removed: extend public bool trySetDsProp(Snapper snapper, SetSnapperPropertyEnv env) { Removed: public str graphicalSpecialCacheKey(Object obj) { Removed: extend public void clearPropagateStretchInfo() : deprecated { Removed: extend public void updatePropagateStretchValue(str key, str stretchMeasureParam, double length, double delta) : deprecated { Removed: extend public double propagateStretchValue(str key, str stretchMeasureParam) : deprecated { Removed: extend public bool symStretch(SymHandle handle, PreCorePropObj owner, str measParam, bool stretchEP, point p, AnimationMouseInfo mi) { Removed: extend public void apply(DsPData data) {
The following method has been renamed in DsPData class as part of the constraint changes in 17.5.
Modified: Old: public Bool dbg_forceDsApplyLogic() { New: public Bool forceDsApplyLogic() {
DataSymbolThe following methods have been removed in DataSymbol class as they were deprecated or no longer in use.
The method completeBuild() is now replaced by buildConnectors().
Removed: extend package DsConnector[] nodeConnectors() { Removed: extend public bool nodeConnectorExists(point pos) { Removed: extend public bool completeBuild(bool defaultMats=true) {
Some connector-related interfaces are now changed to public. Certain unused method arguments are also removed.
Old: extend public void buildConnectors(point{} pos, bool updateSpace) { New: extend public void buildConnectors(bool updateSpace) { Old: extend public void buildConnectors(point{} pos) { New: extend public void buildConnectors() {
DsCorePropertyFactoryRemoved: public str _comSpecialCode; // Had a FIXME to remove in 10.5 Removed: extend public str comSpecialCode() // Had a FIXME to remove in 10.5 Removed: extend public str comSpecialCode=(str s) // Had a FIXME to remove in 10.5 Removed: extend public void selectCOM(DsPDataOption option, Material m) // COM append is handled by DsDomain
DsPsLayoutPropertyEntryUIFactoryAdded: extend public void cleanMissingCOMs(DsiPDataOption option) Added: package void mergeNextSelOptions(DsiPDataOption oldO, DsiPDataOption newO)
DsCOMMaterialCardRemoved: extend public bool buildMaterials(TreeViewItem item0, TreeViewItem item, bool open)
Removed: extend public void propagateCOM(DsPDataOption option, Material com)
DsMaterialDomainRemoved: extend public void buildMaterials(DsPData data, SFeature feature) // Had a FIXME to remove in 11.0
DsDomainRemoved: extend public TreeViewItem optionTVI(SFeature feature, Option o, TreeViewItem parentTvi) : deprecated // Had a FIXME to remove in 11.0 Removed: extend public void buildLeaves(SFeature f, TreeViewItem tvi, str{} visitedFKeys) Removed: extend public TreeViewItem[] trees() : deprecated // Had a FIXME to remove in 7.0 Added: extend public void insertCOMs(DsPFeatureTVI tvi, DsiPDataOption selOps) {
DsPDataOptionAdded: extend public TreeViewItem[] sortedContains(TreeViewItem{} items, bool allowPartial=false) Added: public int tviContainsSort(TreeViewItem a, TreeViewItem b, Object env=null)
The following interface changes have been made to facilitate the functionality to remove related catalog files when an extension is uninstalled.
cm.abstract.dataSymbol.registerCatalogs.cm
Old: public void registerDsEmbeddedCatalog(int cid, str dbFile, str{} offlinePrdCatalogs=null) { New: public void registerDsEmbeddedCatalog(int cid, str dbFile, str{} offlinePrdCatalogs=null, symbol sourcePkg=#:package : caller eval) {
Also some interfaces were updated in the cm.abstract.dataSymInterface and cm.extension packages as part of this change. Please refer to the "Compile time changes" in the cm.abstract.dataSymInterface and cm.extension packages documentation for those changes as well.
Configura SIF rows generated for data-symbol parts now include VO (volume), WD (width), DP (depth), and HT (height). A value from Part.genericCode() is written as CG; TAG2 supplies CG only when the part has no generic code.
OFDA measurement values are now emitted through Part.xmlMeasurement(). The type, measurement system, and unit remain XML attributes, while numeric values are normalized through the shared conversion helper.
DsPart.xmlOptions() now writes the option price before OmitOnOrder. This changes the order of elements in exported OFDA XML without changing their values. Extensions or integrations that compare or parse option elements positionally must update for the 04.02.00 ordering. See the cm.abstract.ofdaXml migration notes for the other OFDA XML output changes.
Configura SIF and OFDA XML now traverse selected optional options into their subfeatures. An optional option that is not selected still exports its configured no-code and description. For example, selecting O1 when it contains subfeature options O3 and O5 now exports O3 and O5 beneath O1; previously those subfeature options were omitted.
Both exporters now consume the option tree:
// Configura SIF (DsPData) for (info in createOrderExportOptionInfo()) { addSifOptionRows(info, env, part, space); } // OFDA XML (DsPart) for (info in _data.createOrderExportOptionInfo(), index=seq) { addXMLOptions(info, prefix, buf, seq); }
SIF writes a zero-price O1 row for unselected optional options, and PO is emitted for root options only. OFDA XML nests the subfeature options under their selected parent. Extensions that parse these exports or compare reference files should update their expected option hierarchy and rows.
DsMaterialDialogDsMaterialSideBarPropertyupdateSelection()DsFeatureSideBarPropertyupdateSelection()DsFeaturePropertyFactoryappendControls(Control[] list)refreshProperty(PropertyRefreshVisitor visitor=null, bool fullRefresh=false)DsPsFeaturePropertyUIFactory appendControls(Control[] list)DsPsLayoutPropertyEntryUIFactoryselectCB0(Control c) has been updated to merge selected sel options for non-optional select features. This was added to preserve lower level COM selections when changing mid or top level options.DsCOMMaterialCardbuildMaterials() to loop over all COMs. This should support future work to eventually remove the need for a linked material.DsMaterialDialogDsDomaintreeOwner when creating a DsPFeatureTVI in createImageNode(TreeViewItem tree).treeOwner when copying the stored tree in DsDomain via treeViewCopy(DsMaterialTreeViewItem root, bool firstLevelOnly=false).noneCompactTrees(DsPFeatureTVI tvi, DsiPDataOption selOps, int level, bool firstLevelOnly=false to find and append COMS when building the tree for UI applications.DsMaterialTreeViewItem & materialTreeviewItem.cmtreeOwner in the function dsTviPDataOption(TreeViewItem this, bool noRoot) to only switch to traversing the treeOwner parent structure when we hit root for the TreeViewItem passed in. This way we can look for COMs at non-leaf levels from the UI and then traverse the rest of the domain's tree after the UI structure is no longer relevant.public DsPDataOption option() to just call dsTviPDataOption().