Table of Contents

Class StepPropertyAccess

Namespace
Hi.MillingSteps
Assembly
HiMech.dll

Provides access to properties of a milling step with presentation information.

public class StepPropertyAccess
Inheritance
StepPropertyAccess
Inherited Members
Extension Methods

Constructors

StepPropertyAccess(PresentAttribute, Func<MachiningStep, double?>)

Initializes a new instance of the StepPropertyAccess class for numeric properties.

public StepPropertyAccess(PresentAttribute presentAttribute, Func<MachiningStep, double?> getQuantityFunc)

Parameters

presentAttribute PresentAttribute

The presentation attribute for the property.

getQuantityFunc Func<MachiningStep, double?>

The function to retrieve the numeric value.

StepPropertyAccess(PresentAttribute, Func<MachiningStep, object>)

Initializes a new instance of the StepPropertyAccess class for non-numeric properties.

public StepPropertyAccess(PresentAttribute presentAttribute, Func<MachiningStep, object> getNonQuantityFunc)

Parameters

presentAttribute PresentAttribute

The presentation attribute for the property.

getNonQuantityFunc Func<MachiningStep, object>

The function to retrieve the non-numeric value.

Properties

GetNonQuantityFunc

Gets or sets the function to retrieve a non-numeric value from a milling step.

public Func<MachiningStep, object> GetNonQuantityFunc { get; set; }

Property Value

Func<MachiningStep, object>

GetQuantityFunc

Gets or sets the function to retrieve a numeric value from a milling step.

public Func<MachiningStep, double?> GetQuantityFunc { get; set; }

Property Value

Func<MachiningStep, double?>

PresentAttribute

Gets or sets the presentation attribute for the property.

public PresentAttribute PresentAttribute { get; set; }

Property Value

PresentAttribute

Methods

GetValue(MachiningStep)

Gets the value of the property for the specified milling step.

public object GetValue(MachiningStep step)

Parameters

step MachiningStep

The milling step to get the property value from.

Returns

object

The property value, or null if neither function is set.

GetValueText(MachiningStep)

Gets the formatted text representation of the property value for the specified milling step.

public string GetValueText(MachiningStep step)

Parameters

step MachiningStep

The milling step to get the property value from.

Returns

string

The formatted text representation of the property value.

GetValueText(object)

Gets the formatted text representation of the specified value.

public string GetValueText(object v)

Parameters

v object

The value to format.

Returns

string

The formatted text representation of the value.