Advance Steel 2020 .NET and COM API Changes

Learn about modifications and new additions in the API of this release of the software.

.NET API Breaking Changes

PlateFoldRelation:
  • method BreakFoldedPlate now no longer returns an integer (it returns nothing) and it starts with a upper case B.
Plate:
  • Plate(double dLength, double dWidth, const AstGeomPlane& plane, const AstGeomPoint3d& ptCenter) - changed signature to Plate(const AstGeomPlane& plane, const AstGeomPoint3d& ptCenter, double dLength, double dWidth); ptCenter is expected in WCS, as before.
  • Plate(const AstGeomPlane& plane, const AstGeomPoint3d& ptCenter) - changed behavior to expect ptCenter in WCS.
  • Plate(const AstGeomPlane& plane, const AstGeomPoint3d& ptCenter, double dRadius) - changed behavior to expect ptCenter in WCS.
Grating:
  • Grating(const AstString& strClass, const AstString& strName, const AstGeomPlane& cadPlane, const AstGeomPoint3d& ptCenter) - changed behavior to expect ptCenter in WCS.
  • Grating(const AstString& strClass, const AstString& strName, const AstGeomPlane& cadPlane, const AstGeomPoint3d& ptCenter, double dLength, double dWidth) - changed behavior to expect ptCenter in WCS.
  • Grating(const AstString& strSeries, int bearingBarSpacing, int crossBarSpacing, const AstString& strThickness, const AstString& strWidth, const AstString& strCrossBar, const AstGeomPlane& cadPlane, const AstGeomPoint3d& ptCenter, double dLength) - changed behavior to expect ptCenter in WCS.
Wall:
  • Wall(double dLength, double dHeight, const AstGeomPlane& plane, const AstGeomPoint3d& ptCenter) - changed signature to Wall(const AstGeomPlane& plane, const AstGeomPoint3d& ptCenter, double dLength, double dWidth); ptCenter is expected in WCS, as before.
Slab:
  • Slab(const AstGeomPlane& plnBase, const AstGeomPoint3d& ptCenter, double dXLength, double dYLength) - changed behavior to expect ptCenter in WCS.
FootingIsolated:
  • FootingIsolated(const AstGeomPlane& plnBase, const AstGeomPoint3d& ptCenter, double dXLength, double dYLength) - changed behavior to expect ptCenter in WCS.
  • FootingIsolated(const AstGeomPlane& plnBase, const AstGeomPoint3d& ptCenter, double dRadius) - changed behavior to expect ptCenter in WCS.
UserAutoConstructionObject:
  • UserAutoConstructionObject::UserAutoConstructionObject(System::String^ ruleName, Dictionary<FilerObject^, Point3d^>^ inputDrivers) - changed from dictionary to list of tuples
  • UserAutoConstructionObject::UserAutoConstructionObject(System::String^ ruleName, Dictionary<FilerObject^, Point3d^>^ inputDrivers, IFiler^ pFiler) - changed from dictionary to list of tuples
  • UserAutoConstructionObject::UserAutoConstructionObject(System::String^ ruleName, Dictionary<FilerObject^, Point3d^>^ inputDrivers, IFiler^ pFiler, System::Guid^ uid) - changed from dictionary to list of tuples

Transactions:

The Autodesk.AdvanceSteel.CADAccess.Transaction and Autodesk.AdvanceSteel.CADAccess.DocumentManagement.DocumentAccess elements no longer auto-commit.

This means that in the past, a code like this would have successfully committed changes:

using (new DocumentAccess da = new DocumentAccess(...))

{

<Make model changes here (create elements, modify elements, etc)>

} ← here, previously, if changes were not committed or discarded already they would have been committed

Now, you need to also add a "commit" call to prevent the changes from being discarded:

using (new DocumentAccess da = new DocumentAccess(...))

{

<Make model changes here (create elements, modify elements, etc)>

da.Commit()

} ← here, now, if changes are not committed or discarded already, they are discarded

TaperedBeam - removed the following functions that did not work correctly or did nothing at all:
  • void setLengthAt (int nIdx, double dLength);
  • double getLengthAt (int nIdx) const;
  • void setHeightAt (int nIdx, double dHeight);
  • double getHeightAt (int nIdx) const ;
  • void addSegment (double dLength, double dEndHeight, double dWebThickness);
  • void removeSegment (int nIdx);
Autodesk.AdvanceSteel.Geometry.GeInteropServices - removed the following:
  • Point2dArray(Point2d[] points, void* astPoints)
  • Point3dArray(Point3d[] points, void* astPoints)
  • Point3dArray(System.Collections.Generic.IEnumerable<Point3d> points, void* astPoints)
Autodesk.AdvanceSteel.Profiles.ProfileStaticValues - property capitalization changed:
  • property double ez → property double Ez
  • property double ey → property double Ey
Autodesk.AdvanceSteel.Profiles.ProfileType
  • bool hasKDistance(out double dDistance) → bool GetKDistance(out double dDistance) - function name changed
  • property AstProfType* Native - changed to read-only
Autodesk.AdvanceSteel.ASSettings.ASSettingsUtils - changed property names:
  • ASRegistryPath_UserSettings → ASSettingsPath_UserSettings
  • ASRegistryPath_MachineEnvironment → ASSettingsPath_MachineEnvironment
  • ASRegistryPath_UserEnvironment → ASSettingsPath_UserEnvironment
Autodesk.AdvanceSteel.DotNetRoots.DatabaseAccess.AstorBase
  • public void AddBoltToStandard(string anchorName, string author, bool autoLength) - changed signature to public void AddBoltToStandard(string anchorName, string author, bool autoLength, string standardSet)
Autodesk.AdvanceSteel.Modeler.IModeler
  • ErrorCode SetTag(Guid nTag) - changed signature to ErrorCode SetTag(Guid nTag, int bodyIndex)
  • int IsNull() - changed signature to bool IsNull()

.NET API New Classes and Methods

Autodesk.AdvanceSteel.InteropServices.ASInteropServices - copied these methods from GeomMgd because of accessibility issues of methods with native and managed parameters

AstGeomPoint2dArray PointArray(System.Collections.Generic.IEnumerable<Point2d> points)

AstGeomPoint3dArray PointArray(System.Collections.Generic.IEnumerable<Point3d> points)

Autodesk.AdvanceSteel.Modeler.IModeler

IModeler RelinquishUnderlyingModeler()

This allows proper transfer of modeler ownership when we need to release resources in a more timely manner or we want to avoid unnecessary copies.

The current modeler on which this method is called will no longer have valid data inside after this call - the only existing copy and reference to the inner modeler will be the returned object. It is the caller responsibility to properly store and dispose of that object.

Autodesk.AdvanceSteel.Profiles.ProfilesManager

System.String ValidateProfile(ProfileType profType) - Validates a dynamic profile, returns the internal name of the profile.

Autodesk.AdvanceSteel.Profiles.ProfileStaticValues

property double C - K Distance in mm.

Autodesk.AdvanceSteel.Profiles.ProfileType

bool operator != (ProfileType first, ProfileType second)

bool GetStaticValues(out ProfileStaticValues values)

bool GetSpecificGravity(out double gravity)

Autodesk.AdvanceSteel.DotNetRoots.AstDpi

new class containing methods for scaling controls with DPI

Autodesk.AdvanceSteel.DotNetRoots.DatabaseAccess.AstorBase

DataTable GetModelRolesByObjectTypeId(int objectTypeId)

DataTable GetAnchorsOrientationTable()

string GetGradeRunName(string key)

Autodesk.AdvanceSteel.Modelling.HoleDefinition

new class

Autodesk.AdvanceSteel.Modelling.ScrewBoltPattern

double GetWeight()

HoleDefinition GetHoleDefinition(int index) - The input parameters refers to the index of the bolt connected element for which the hole definition is requested

SetHoleDefinition(int index, HoleDefinition holeDef)

Autodesk.AdvanceSteel.Modelling.AnchorPattern

double GetWeight()

Autodesk.AdvanceSteel.Modelling.Connector

double GetWeight()

Autodesk.AdvanceSteel.Modelling.PlateBase

double GetPaintArea()

Autodesk.AdvanceSteel.AutoConnection.AutoConnectionUtilities

static int PropagateJoint(AutoConstructionObject pJoint, AutoConnectionDescriptor[] descriptors, ref string[][] connInputIds, ref Point3d[][] connInputPts)

static int Group(AutoConnectionDescriptor[] descriptors, ref ZoneResult[][] groups)

static ZoneResult[][] MergeGroups(ZoneResult[][] groups)

Autodesk.AdvanceSteel.AutoConnection.ZoneResult

new class

Autodesk.AdvanceSteel.AutoConnection.AutoConnectionDescriptor

property const Autodesk.AdvanceSteel.CADLink.Database.ObjectId Id

Autodesk.AdvanceSteel.AutoConnection.BeamAutoConnectionDescriptor

void SetFromGeometry(LineSeg3d value)

Autodesk.AdvanceSteel.ASMgdJoints.ASIUIProxy

has a new read-only property: "IClassTypeFilter ClassFilter" - this will allow the implementation of proper object selection behavior for .NET joints.

COM API New Classes and Methods

DscGeomCOM → CExtents

property CenterPoint get - returns the center point of the box.