Class PresentAttribute
- Namespace
- Hi.MillingSteps
- 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
src
PresentAttributeThe 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
name
stringThe display name of the property.
shortName
stringThe short name of the property.
unit
PhysicsUnitThe physics unit of the property.
dataFormatString
stringThe 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
loc
StringLocalizerThe 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
loc
IStringLocalizerThe string localizer.
Returns
- string
The localized name with unit string.