Table of Contents

Class ConstRatioProfile

Namespace
Hi.Milling.Cutters
Assembly
HiMech.dll

Represents a constant ratio profile for a milling cutter. This profile maintains a constant ratio between inner and outer radii.

public class ConstRatioProfile : IShaperProfile, IMakeXmlSource, IAbstractNote, IGetZrList, IGetStl, IDuplicate, IClearCache, IGenStl, IZrListSourceProperty
Inheritance
ConstRatioProfile
Implements
Inherited Members
Extension Methods

Constructors

ConstRatioProfile()

Initializes a new instance of the ConstRatioProfile class.

public ConstRatioProfile()

ConstRatioProfile(double)

Initializes a new instance of the ConstRatioProfile class with a specified radius ratio.

public ConstRatioProfile(double innerRadiusRatio)

Parameters

innerRadiusRatio double

The ratio between inner and outer radii

ConstRatioProfile(XElement, string)

Initializes a new instance of the ConstRatioProfile class.

public ConstRatioProfile(XElement element, string baseDirectory)

Parameters

element XElement

The XML element containing profile data.

baseDirectory string

The base directory for resolving relative paths.

Properties

AbstractNote

Gets the abstract note describing the profile.

public string AbstractNote { get; }

Property Value

string

RadiusRatio

Gets or sets the ratio between inner and outer radii.

public double RadiusRatio { get; set; }

Property Value

double

XName

Name for XML IO.

public static string XName { get; }

Property Value

string

ZrListSource

Get base geometry source. Runtime property.

public Func<IGetZrList> ZrListSource { get; set; }

Property Value

Func<IGetZrList>

Methods

ClearCache()

Clears any cached data held by the implementing object.

public void ClearCache()

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

GetStl()

Gets the STL geometry data.

public Stl GetStl()

Returns

Stl

The STL geometry object

GetZrList()

Gets a list of Z-R coordinate pairs.

public List<PairZr> GetZrList()

Returns

List<PairZr>

A list of PairZr objects representing Z-R coordinates.

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.