Photon Quantum 3.0.0

Public Member Functions | Public Attributes | List of all members
Quantum.WarnIfAttribute Class Reference

Editor attribute for adding notices to fields if the condition member evaluates as true. Condition member can be a property, field or method (with a return value). More...

Inheritance diagram for Quantum.WarnIfAttribute:
Quantum.DoIfAttributeBase Quantum.DecoratingPropertyAttribute Quantum.PropertyAttribute

Public Member Functions

 WarnIfAttribute (string conditionMember, bool compareToValue, string message, CompareOperator compare=CompareOperator.Equal)
 
 WarnIfAttribute (string conditionMember, double compareToValue, string message, CompareOperator compare=CompareOperator.Equal)
 
 WarnIfAttribute (string conditionMember, long compareToValue, string message, CompareOperator compare=CompareOperator.Equal)
 
 WarnIfAttribute (string conditionMember, string message)
 Initializes a new instance that will hide the field if the condition member is not equal to zero. More...
 

Public Attributes

bool AsBox
 Should the warning be shown as a box? More...
 
string Message
 The default warning text, when a warning is shown. More...
 
- Public Attributes inherited from Quantum.DoIfAttributeBase
double _doubleValue
 The double value to compare against. More...
 
bool _isDouble
 Is the value to compare against a double? More...
 
long _longValue
 The long value to compare against. More...
 
CompareOperator Compare
 The comparison operator to use. More...
 
string ConditionMember
 Condition member to evaluate. More...
 
bool ErrorOnConditionMemberNotFound = true
 If true, an error will be thrown if the condition member is not found. More...
 

Additional Inherited Members

- Static Public Attributes inherited from Quantum.DecoratingPropertyAttribute
const int DefaultOrder = -10000
 The default order of the attribute. More...
 
- Protected Member Functions inherited from Quantum.DoIfAttributeBase
 DoIfAttributeBase (string conditionMember, bool compareToValue, CompareOperator compare)
 Initializes a new instance with a boolean value to compare against. More...
 
 DoIfAttributeBase (string conditionMember, double compareToValue, CompareOperator compare)
 Initializes a new instance with a double value to compare against. More...
 
 DoIfAttributeBase (string conditionMember, long compareToValue, CompareOperator compare)
 Initializes a new instance with a long value to compare against. More...
 
- Protected Member Functions inherited from Quantum.DecoratingPropertyAttribute
 DecoratingPropertyAttribute ()
 Initializes a new instance with the default order. More...
 
 DecoratingPropertyAttribute (int order)
 Initializes a new instance with the specified order. More...
 

Detailed Description

Editor attribute for adding notices to fields if the condition member evaluates as true. Condition member can be a property, field or method (with a return value).

Constructor & Destructor Documentation

◆ WarnIfAttribute()

Quantum.WarnIfAttribute.WarnIfAttribute ( string  conditionMember,
string  message 
)
inline

Initializes a new instance that will hide the field if the condition member is not equal to zero.

Parameters
conditionMember
message

Member Data Documentation

◆ Message

string Quantum.WarnIfAttribute.Message

The default warning text, when a warning is shown.

◆ AsBox

bool Quantum.WarnIfAttribute.AsBox

Should the warning be shown as a box?