diff options
author | CodaFi <devteam.codafi@gmail.com> | 2013-06-29 19:07:06 -0600 |
---|---|---|
committer | CodaFi <devteam.codafi@gmail.com> | 2013-06-29 19:07:06 -0600 |
commit | b3c6cc9e7135e925590af96923b39cb1f1f432d0 (patch) | |
tree | 0c73215a26c06104de4497fdb882fdef6a02fcd7 /src/objc/abstract | |
parent | d90bb3ec8178d5190c829d82750fea1f8ef0d5ef (diff) |
Add default constructors to abstract classes
Diffstat (limited to 'src/objc/abstract')
-rw-r--r-- | src/objc/abstract/MCOAbstractMessage.mm | 8 | ||||
-rw-r--r-- | src/objc/abstract/MCOAbstractPart.mm | 8 |
2 files changed, 16 insertions, 0 deletions
diff --git a/src/objc/abstract/MCOAbstractMessage.mm b/src/objc/abstract/MCOAbstractMessage.mm index 6fedcc8a..93695fea 100644 --- a/src/objc/abstract/MCOAbstractMessage.mm +++ b/src/objc/abstract/MCOAbstractMessage.mm @@ -28,6 +28,14 @@ return _message; } +- (id) init +{ + nativeType *message = new nativeType(); + self = [self initWithMCMessage:message]; + message->release(); + return self; +} + - (id) initWithMCMessage:(mailcore::AbstractMessage *)message { self = [super init]; diff --git a/src/objc/abstract/MCOAbstractPart.mm b/src/objc/abstract/MCOAbstractPart.mm index 8b2b008d..ca8b049c 100644 --- a/src/objc/abstract/MCOAbstractPart.mm +++ b/src/objc/abstract/MCOAbstractPart.mm @@ -27,6 +27,14 @@ return _part; } +- (id) init +{ + nativeType *part = new nativeType(); + self = [self initWithMCPart:part]; + part->release(); + return self; +} + - (id) initWithMCPart:(mailcore::AbstractPart *)part { self = [super init]; |