Class PresentAttribute
- Namespace
- Hi.MachiningSteps
- Assembly
- HiMech.dll
Attribute for presenting property information with localization support.
public class PresentAttribute : Attribute
- Inheritance
-
PresentAttribute
- Inherited Members
- Extension Methods
Constructors
PresentAttribute()
Initializes a new instance of the PresentAttribute class.
public PresentAttribute()
PresentAttribute(PresentAttribute)
Initializes a new instance of the PresentAttribute class by copying from another instance.
public PresentAttribute(PresentAttribute src)
Parameters
srcPresentAttributeThe source attribute to copy from.
PresentAttribute(string, string, PhysicsUnit, string)
Initializes a new instance of the PresentAttribute class with specified parameters.
public PresentAttribute(string name, string shortName, PhysicsUnit unit, string dataFormatString)
Parameters
namestringThe display name of the property.
shortNamestringThe short name of the property.
unitPhysicsUnitThe physics unit of the property.
dataFormatStringstringThe format string for displaying the property value.
Properties
DataFormatString
Gets or sets the format string for displaying the property value.
public string DataFormatString { get; set; }
Property Value
Name
Gets or sets the display name of the property.
public string Name { get; set; }
Property Value
ShortName
Gets or sets the short name of the property.
public string ShortName { get; set; }
Property Value
TailUnitString
Gets the unit string with parentheses for display purposes.
public string TailUnitString { get; }
Property Value
Unit
Gets or sets the physics unit of the property.
public PhysicsUnit Unit { get; set; }
Property Value
Methods
GetPresentName(StringLocalizer)
Gets the localized presentation name with unit string.
public string GetPresentName(StringLocalizer loc)
Parameters
locStringLocalizerThe string localizer.
Returns
- string
The localized name with unit string.
GetPresentName(IStringLocalizer)
Gets the localized presentation name with unit string.
public string GetPresentName(IStringLocalizer loc)
Parameters
locIStringLocalizerThe string localizer.
Returns
- string
The localized name with unit string.