~iaz/+junk/demo-bindings

« back to all changes in this revision

Viewing changes to bindings/objc/Library_objc.m

  • Committer: ivan.a.zorin at gmail
  • Date: 2011-11-16 16:16:00 UTC
  • Revision ID: ivan.a.zorin@gmail.com-20111116161600-59pn7uz60ksqcpxh
demo-bindings: add objective-c bindings support

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
#import <Foundation/Foundation.h>
 
3
#import <library.h>
 
4
#import "Library_objc.h"
 
5
 
 
6
@implementation Library
 
7
 
 
8
- (int) ObjectMethod
 
9
{
 
10
        NSLog(@"Library ObjectMethod");
 
11
        return 1;
 
12
}
 
13
 
 
14
- (int) ObjectFunction
 
15
{
 
16
        NSLog(@"Library ObjectFunction: calling libfunction()...");
 
17
        return libfunction();
 
18
}
 
19
 
 
20
+ (int) ClassMethod
 
21
{
 
22
        NSLog(@"Library ClassMethod");
 
23
        return 0;
 
24
}
 
25
 
 
26
+ (int) ClassFunction
 
27
{
 
28
        NSLog(@"Library ClassFunction: calling libfunction()...");
 
29
        return libfunction();
 
30
}
 
31
 
 
32
@end
 
33