MBConditionalDeclaration Class Reference
Inherits from | MBDataModel : MBFormattedDescriptionObject |
---|---|
Declared in | MBConditionalDeclaration.h |
Overview
A data model representing a conditional declaration.
Conditional declarations contain an ifCondition
expression that gets
evaluated in a boolean context. This condition is typically populated
using the if="
…"
attribute on the associated MBML tag.
ifCondition
Returns the if condition associated with the receiver, a boolean
expression indicating whether the variable declaration should be processed.
contents of the if="
…"
attribute.
@property (nullable, nonatomic, readonly) NSString *ifCondition
Declared In
MBConditionalDeclaration.h
shouldDeclare
Determines whether the variable declaration should proceed. This returns
YES
if the ifCondition
is nil
or if the ifCondition
evaluates
to YES
in a boolean context. Otherwise, returns NO
, indicating that
the variable declaration will be ignored.
@property (nonatomic, readonly) BOOL shouldDeclare
Declared In
MBConditionalDeclaration.h