CaseValue
Overview
A case value is the Cirrus equivalent of an individual Case Statement Expression in Oxygene. It is a conditional expression of which only 1 or 0 branches will be executed, depending on the value.
Location
- Reference: RemObjects.Elements.Cirrus.dll
- Namespace: RemObjects.Elements.Cirrus.Values
- Ancestry: Value | CaseValue
constructor
Empty constructor; sets none of the properties
constructor
CaseValue()
init()
CaseValue()
Sub New()
constructor (IType, Value, Value, array of CaseValueItem)
Constructor that initializes the properties listed below
constructor(ResultType: IType; aInput: Value; aDefault: Value; params aValues: array of CaseValueItem)
CaseValue(IType ResultType, Value aInput, Value aDefault, params CaseValueItem[] aValues)
init(_ ResultType: IType, _ aInput: Value, _ aDefault: Value, _ aValues: CaseValueItem...)
CaseValue(IType ResultType, Value aInput, Value aDefault, CaseValueItem[]... aValues)
Sub New(ResultType As IType, aInput As Value, aDefault As Value, ParamArray aValues As CaseValueItem())
Parameters:
- ResultType: Result type of the case
- aInput: Case value
- aDefault: Default value
- aValues: Case arguments
Binary (declared in Value)
Creates a binary value
method Binary(aOp: BinaryOperator; aOther: Value): Value
Value Binary(BinaryOperator aOp, Value aOther)
func Binary(_ aOp: BinaryOperator, _ aOther: Value) -> Value
Value Binary(BinaryOperator aOp, Value aOther)
Function Binary(aOp As BinaryOperator, aOther As Value) As Value
Parameters:
- aOp: Operator
- aOther: Right side value
Default
Value in case none of the items in Values matches (else)
property Default: Value read write;
Value Default { get; set; }
var Default: Value { get{} set{} }
Value Default { __get; __set; }
Property Default() As Value
creates an identifier value
Parameters:
- aName: Name of the value
creates an identifier value
Parameters:
- aName: Name of the value
- aArgs: Generic arguments.
Input
The condition for this case expression
property Input: Value read write;
Value Input { get; set; }
var Input: Value { get{} set{} }
Value Input { __get; __set; }
Property Input() As Value
Kind
Value kind; use this for a fast way of determining what kind of sub class a Value object is
property Kind: ValueKind read;
ValueKind Kind { get; }
var Kind: ValueKind { get{} }
ValueKind Kind { __get; }
ReadOnly Property Kind() As ValueKind
Length (declared in Value)
Creates a length value
method Length: Value
Value Length()
func Length() -> Value
Value Length()
Function Length() As Value
NotNil (declared in Value)
Creates a not nil value
method NotNil: Value
Value NotNil()
func NotNil() -> Value
Value NotNil()
Function NotNil() As Value
Position (declared in Value)
Position this value is defined at (if not set, it will be at the aspects position)
property Position: IPosition read write;
IPosition Position { get; set; }
var Position: IPosition { get{} set{} }
IPosition Position { __get; __set; }
Property Position() As IPosition
Creates a call value
Parameters:
- aName: Method name
- aGP: Generic parameters to pass
- aArgs: Arguments for this call
Creates a call value
Parameters:
- aName: Method name
- aArgs: Arguments for this call
ResultType
Result type of this case statement; optional; if not set, it is infered from the result values
property ResultType: IType read write;
IType ResultType { get; set; }
var ResultType: IType { get{} set{} }
IType ResultType { __get; __set; }
Property ResultType() As IType
SubArray (declared in Value)
Creates an array/property element access value
Parameters:
- aArgs: Arguments for element access
ToString
Returns the string value of this value
method ToString: String
String ToString()
func ToString() -> String
String ToString()
Function ToString() As String
Unary (declared in Value)
Creates a unary value
method Unary(aOp: UnaryOperator): Value
Value Unary(UnaryOperator aOp)
func Unary(_ aOp: UnaryOperator) -> Value
Value Unary(UnaryOperator aOp)
Function Unary(aOp As UnaryOperator) As Value
Parameters:
- aOp: Operator
Values
Elements in the case expression
property Values: List<CaseValueItem> read;
List<CaseValueItem> Values { get; }
var Values: List<CaseValueItem> { get{} }
List<CaseValueItem> Values { __get; }
ReadOnly Property Values() As List<CaseValueItem>
Default
Value in case none of the items in Values matches (else)
property Default: Value read write;
Value Default { get; set; }
var Default: Value { get{} set{} }
Value Default { __get; __set; }
Property Default() As Value
Input
The condition for this case expression
property Input: Value read write;
Value Input { get; set; }
var Input: Value { get{} set{} }
Value Input { __get; __set; }
Property Input() As Value
Kind
Value kind; use this for a fast way of determining what kind of sub class a Value object is
property Kind: ValueKind read;
ValueKind Kind { get; }
var Kind: ValueKind { get{} }
ValueKind Kind { __get; }
ReadOnly Property Kind() As ValueKind
Position (declared in Value)
Position this value is defined at (if not set, it will be at the aspects position)
property Position: IPosition read write;
IPosition Position { get; set; }
var Position: IPosition { get{} set{} }
IPosition Position { __get; __set; }
Property Position() As IPosition
ResultType
Result type of this case statement; optional; if not set, it is infered from the result values
property ResultType: IType read write;
IType ResultType { get; set; }
var ResultType: IType { get{} set{} }
IType ResultType { __get; __set; }
Property ResultType() As IType
Values
Elements in the case expression
property Values: List<CaseValueItem> read;
List<CaseValueItem> Values { get; }
var Values: List<CaseValueItem> { get{} }
List<CaseValueItem> Values { __get; }
ReadOnly Property Values() As List<CaseValueItem>
constructor
Empty constructor; sets none of the properties
constructor
CaseValue()
init()
CaseValue()
Sub New()
constructor (IType, Value, Value, array of CaseValueItem)
Constructor that initializes the properties listed below
constructor(ResultType: IType; aInput: Value; aDefault: Value; params aValues: array of CaseValueItem)
CaseValue(IType ResultType, Value aInput, Value aDefault, params CaseValueItem[] aValues)
init(_ ResultType: IType, _ aInput: Value, _ aDefault: Value, _ aValues: CaseValueItem...)
CaseValue(IType ResultType, Value aInput, Value aDefault, CaseValueItem[]... aValues)
Sub New(ResultType As IType, aInput As Value, aDefault As Value, ParamArray aValues As CaseValueItem())
Parameters:
- ResultType: Result type of the case
- aInput: Case value
- aDefault: Default value
- aValues: Case arguments
Binary (declared in Value)
Creates a binary value
method Binary(aOp: BinaryOperator; aOther: Value): Value
Value Binary(BinaryOperator aOp, Value aOther)
func Binary(_ aOp: BinaryOperator, _ aOther: Value) -> Value
Value Binary(BinaryOperator aOp, Value aOther)
Function Binary(aOp As BinaryOperator, aOther As Value) As Value
Parameters:
- aOp: Operator
- aOther: Right side value
creates an identifier value
Parameters:
- aName: Name of the value
creates an identifier value
Parameters:
- aName: Name of the value
- aArgs: Generic arguments.
Length (declared in Value)
Creates a length value
method Length: Value
Value Length()
func Length() -> Value
Value Length()
Function Length() As Value
NotNil (declared in Value)
Creates a not nil value
method NotNil: Value
Value NotNil()
func NotNil() -> Value
Value NotNil()
Function NotNil() As Value
Creates a call value
Parameters:
- aName: Method name
- aGP: Generic parameters to pass
- aArgs: Arguments for this call
Creates a call value
Parameters:
- aName: Method name
- aArgs: Arguments for this call
SubArray (declared in Value)
Creates an array/property element access value
Parameters:
- aArgs: Arguments for element access
ToString
Returns the string value of this value
method ToString: String
String ToString()
func ToString() -> String
String ToString()
Function ToString() As String
Unary (declared in Value)
Creates a unary value
method Unary(aOp: UnaryOperator): Value
Value Unary(UnaryOperator aOp)
func Unary(_ aOp: UnaryOperator) -> Value
Value Unary(UnaryOperator aOp)
Function Unary(aOp As UnaryOperator) As Value
Parameters:
- aOp: Operator