Table of Contents

Class AptProfile

Namespace
Hi.Milling.Cutters
Assembly
HiMech.dll

Represents an APT (Automatically Programmed Tool) based profile for a milling cutter. This profile uses APT definitions to describe the cutter geometry.

public class AptProfile : IShaperProfile, IMakeXmlSource, IAbstractNote, IGetZrList, IGenStl, IGetStl, IDuplicate, IGetSelectionName, IGetInitStickConvex, IVolumeRemover, IDisposable, IUpdateByContent, IClearCache, IPolarResolution2dSourceProperty
Inheritance
AptProfile
Implements
Inherited Members
Extension Methods

Constructors

AptProfile()

Initializes a new instance of the AptProfile class.

public AptProfile()

AptProfile(IAptBased)

Initializes a new instance of the AptProfile class.

public AptProfile(IAptBased apt)

Parameters

apt IAptBased

The APT-based object.

AptProfile(XElement, string)

Initializes a new instance of the AptProfile class.

public AptProfile(XElement src, string baseDirectory)

Parameters

src XElement

XML element containing the profile configuration.

baseDirectory string

The base directory for resolving relative paths.

Properties

AbstractNote

Gets the abstract note from the APT definition.

public string AbstractNote { get; }

Property Value

string

Apt

Gets or sets the APT-based definition for the profile.

public IAptBased Apt { get; set; }

Property Value

IAptBased

DefaultAngleResolution_rad

Gets or sets the default angle resolution in radians.

public static double DefaultAngleResolution_rad { get; set; }

Property Value

double

DefaultLinearResolution_mm

Gets or sets the default linear resolution in millimeters.

public static double DefaultLinearResolution_mm { get; set; }

Property Value

double

PolarResolution2dSource

public Func<IPolarResolution2d> PolarResolution2dSource { get; set; }

Property Value

Func<IPolarResolution2d>

XName

Name for XML IO.

public static string XName { get; }

Property Value

string

Methods

ClearCache()

Clears all cached data.

public void ClearCache()

Dispose()

Disposes of all resources.

public void Dispose()

Dispose(bool)

Disposes of unmanaged resources.

protected virtual void Dispose(bool disposing)

Parameters

disposing bool

True if disposing, false if finalizing

Duplicate(params object[])

Creates a deep copy of the object, excluding any source file references.

public object Duplicate(params object[] res)

Parameters

res object[]

Optional parameters that may be needed during the duplication process

Returns

object

A new instance that is a deep copy of the original object

GenStl(IPolarResolution2d)

Generate a new Stl.

public Stl GenStl(IPolarResolution2d resolution)

Parameters

resolution IPolarResolution2d

Returns

Stl

newly created Stl

GetInitStickConvex()

Gets the initial stick convex representation of the profile.

public InitStickConvex GetInitStickConvex()

Returns

InitStickConvex

The initial stick convex representation

GetSelectionName()

Gets the display name for selection.

public string GetSelectionName()

Returns

string

The display name

GetStl()

Gets the STL mesh representation of the profile.

public Stl GetStl()

Returns

Stl

The STL mesh

GetZrList()

Gets the ZR contour list for the profile.

public List<PairZr> GetZrList()

Returns

List<PairZr>

The list of ZR pairs

MakeXmlSource(string, string, bool)

Creates an XML representation of the object. This method may also generate additional resources such as related files.

public XElement MakeXmlSource(string baseDirectory, string relFile, bool exhibitionOnly)

Parameters

baseDirectory string

The base directory for resolving relative paths

relFile string

The relative file path for the XML source

exhibitionOnly bool

if true, the extended file creation is suppressed.

Returns

XElement

An XML element representing the object's state

Remarks

For the demand of easy moving source folder (especially project folder) without configuration file path corruption, the relative file path is applied. The baseDirectory is typically the folder at the nearest configuration file folder. Since the folder can be moving with the configuration file.

UpdateByContent()

Updates the profile based on content changes.

public void UpdateByContent()