DoricContext auto release in iOS
This commit is contained in:
@@ -10,16 +10,13 @@
|
||||
|
||||
@implementation DoricContext
|
||||
|
||||
- (instancetype)init {
|
||||
- (instancetype)initWithScript:(NSString *)script source:(NSString *)source {
|
||||
if(self = [super init]){
|
||||
_driver = [DoricDriver instance];
|
||||
[[DoricContextManager instance] createContext:self script:script source:source];
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
- (instancetype)initWithScript:(NSString *)script source:(NSString *)source {
|
||||
return [[DoricContextManager instance] createContext:script source:source];
|
||||
}
|
||||
|
||||
- (void)dealloc {
|
||||
[[DoricContextManager instance] destroyContext:self];
|
||||
|
||||
Reference in New Issue
Block a user