Table of Contents

Class ShiftedWorkingContour

Namespace
Hi.Milling.FluteContours
Assembly
HiMech.dll

Represents a working contour that has been shifted by a specified angle. This class wraps another working contour and applies an angular transformation to it.

public class ShiftedWorkingContour : IWorkingContour, IExpandToBox3d, IMakeXmlSource, IEquatable<ShiftedWorkingContour>
Inheritance
ShiftedWorkingContour
Implements
Inherited Members
Extension Methods

Constructors

ShiftedWorkingContour()

Initializes a new instance of the ShiftedWorkingContour class

public ShiftedWorkingContour()

ShiftedWorkingContour(double, IWorkingContour)

Initializes a new instance of the ShiftedWorkingContour class with a specified shift angle and baseline contour

public ShiftedWorkingContour(double shiftAngle_rad, IWorkingContour baselineWorkingContour)

Parameters

shiftAngle_rad double

The shift angle in radians

baselineWorkingContour IWorkingContour

The baseline working contour to be shifted

ShiftedWorkingContour(XElement, string, IWorkingContour)

Initializes a new instance of the ShiftedWorkingContour class from XML data

public ShiftedWorkingContour(XElement src, string baseDirectory, IWorkingContour baselineWorkingContour)

Parameters

src XElement

The source XML element

baseDirectory string

The base directory for resolving relative paths

baselineWorkingContour IWorkingContour

The baseline working contour to be shifted

Properties

BaselineWorkingContour

Gets or sets the baseline working contour that is being shifted

public IWorkingContour BaselineWorkingContour { get; set; }

Property Value

IWorkingContour

KeyRange

Gets the key range of the baseline working contour

public Range<double> KeyRange { get; }

Property Value

Range<double>

ShiftAngle_deg

Gets or sets the shift angle in degrees

public double ShiftAngle_deg { get; set; }

Property Value

double

ShiftAngle_rad

Gets or sets the shift angle in radians

public double ShiftAngle_rad { get; set; }

Property Value

double

XName

Gets the XML name for serialization

public static string XName { get; }

Property Value

string

Methods

Duplicate(IGetZrList)

Creates a duplicate of this contour with a new Z-radius list provider.

public IWorkingContour Duplicate(IGetZrList zrList)

Parameters

zrList IGetZrList

The Z-radius list provider for the duplicate.

Returns

IWorkingContour

A new instance of ShiftedWorkingContour.

Equals(ShiftedWorkingContour)

Determines whether the specified ShiftedWorkingContour is equal to the current ShiftedWorkingContour

public bool Equals(ShiftedWorkingContour contour)

Parameters

contour ShiftedWorkingContour

The ShiftedWorkingContour to compare with the current ShiftedWorkingContour

Returns

bool

true if the specified ShiftedWorkingContour is equal to the current ShiftedWorkingContour; otherwise, false

Equals(object)

Determines whether the specified object is equal to the current object

public override bool Equals(object obj)

Parameters

obj object

The object to compare with the current object

Returns

bool

true if the specified object is equal to the current object; otherwise, false

ExpandToBox3d(Box3d)

Expands the given bounding box to include this shifted working contour

public void ExpandToBox3d(Box3d dst)

Parameters

dst Box3d

The bounding box to expand

GetHashCode()

Returns a hash code for this instance

public override int GetHashCode()

Returns

int

A hash code value

GetSpanContourPosList()

Gets the list of span contour positions after applying the shift transformation

public List<SpanContourPos4d> GetSpanContourPosList()

Returns

List<SpanContourPos4d>

A list of transformed span contour positions

MakeXmlSource(string, string)

Creates an XML element representing this shifted working contour

public XElement MakeXmlSource(string baseDirectory, string relFile)

Parameters

baseDirectory string

The base directory for resolving relative paths

relFile string

The relative file path

Returns

XElement

An XML element containing the shifted working contour data

Operators

operator ==(ShiftedWorkingContour, ShiftedWorkingContour)

Determines whether two ShiftedWorkingContour instances are equal

public static bool operator ==(ShiftedWorkingContour left, ShiftedWorkingContour right)

Parameters

left ShiftedWorkingContour

The first ShiftedWorkingContour to compare

right ShiftedWorkingContour

The second ShiftedWorkingContour to compare

Returns

bool

true if the specified ShiftedWorkingContour instances are equal; otherwise, false

operator !=(ShiftedWorkingContour, ShiftedWorkingContour)

Determines whether two ShiftedWorkingContour instances are not equal

public static bool operator !=(ShiftedWorkingContour left, ShiftedWorkingContour right)

Parameters

left ShiftedWorkingContour

The first ShiftedWorkingContour to compare

right ShiftedWorkingContour

The second ShiftedWorkingContour to compare

Returns

bool

true if the specified ShiftedWorkingContour instances are not equal; otherwise, false