Added Lots of Documentation
Added some nice to haves Improved and Unified General Code Layout
This commit is contained in:
@@ -8,12 +8,7 @@
|
||||
|
||||
#import "MPVariable.h"
|
||||
|
||||
#import "MPParsedExpression.h"
|
||||
|
||||
#import "MPToken.h"
|
||||
|
||||
#import "MPExpression.h"
|
||||
#import "MPEvaluationContext.h"
|
||||
|
||||
@implementation MPVariable
|
||||
|
||||
@@ -22,11 +17,13 @@
|
||||
self = [super init];
|
||||
if (self) {
|
||||
NSAssert(variableName != nil, @"variableName must not be nil.");
|
||||
NSAssert(variableName.length > 0, @"variableName must be at least one character long.");
|
||||
_variableName = variableName;
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
|
||||
- (NSDecimalNumber *)doEvaluation:(NSError *__autoreleasing *)error
|
||||
{
|
||||
return [self valueForVariable:self.variableName
|
||||
|
||||
Reference in New Issue
Block a user