Commits

Joris Kluivers committed f19637f

Initial commit

Comments (0)

Files changed (8)

+# .gitignore in use by Joris Kluivers
+
+*.DS_Store
+
+# Xcode
+*.pbxuser
+*.mode1v3
+*.move2v3
+*.perspectivev3
+*.xcuserstate
+project.xcworkspace/
+xcuserdata/
+
+build/
+
+# Generated
+*.o
+*.pyc   
+

ProxyTest.xcodeproj/project.pbxproj

+// !$*UTF8*$!
+{
+	archiveVersion = 1;
+	classes = {
+	};
+	objectVersion = 46;
+	objects = {
+
+/* Begin PBXBuildFile section */
+		A96B7104152055AB0078E0A6 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A96B7103152055AB0078E0A6 /* UIKit.framework */; };
+		A96B7106152055AB0078E0A6 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A96B7105152055AB0078E0A6 /* Foundation.framework */; };
+		A96B7108152055AB0078E0A6 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A96B7107152055AB0078E0A6 /* CoreGraphics.framework */; };
+		A96B710E152055AB0078E0A6 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = A96B710C152055AB0078E0A6 /* InfoPlist.strings */; };
+		A96B7110152055AB0078E0A6 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = A96B710F152055AB0078E0A6 /* main.m */; };
+		A96B7114152055AB0078E0A6 /* JKAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = A96B7113152055AB0078E0A6 /* JKAppDelegate.m */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXFileReference section */
+		A96B70FF152055AB0078E0A6 /* ProxyTest.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ProxyTest.app; sourceTree = BUILT_PRODUCTS_DIR; };
+		A96B7103152055AB0078E0A6 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
+		A96B7105152055AB0078E0A6 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+		A96B7107152055AB0078E0A6 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
+		A96B710B152055AB0078E0A6 /* ProxyTest-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "ProxyTest-Info.plist"; sourceTree = "<group>"; };
+		A96B710D152055AB0078E0A6 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		A96B710F152055AB0078E0A6 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
+		A96B7111152055AB0078E0A6 /* ProxyTest-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "ProxyTest-Prefix.pch"; sourceTree = "<group>"; };
+		A96B7112152055AB0078E0A6 /* JKAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = JKAppDelegate.h; sourceTree = "<group>"; };
+		A96B7113152055AB0078E0A6 /* JKAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = JKAppDelegate.m; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+		A96B70FC152055AB0078E0A6 /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				A96B7104152055AB0078E0A6 /* UIKit.framework in Frameworks */,
+				A96B7106152055AB0078E0A6 /* Foundation.framework in Frameworks */,
+				A96B7108152055AB0078E0A6 /* CoreGraphics.framework in Frameworks */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+		A96B70F4152055AB0078E0A6 = {
+			isa = PBXGroup;
+			children = (
+				A96B7109152055AB0078E0A6 /* ProxyTest */,
+				A96B7102152055AB0078E0A6 /* Frameworks */,
+				A96B7100152055AB0078E0A6 /* Products */,
+			);
+			sourceTree = "<group>";
+		};
+		A96B7100152055AB0078E0A6 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				A96B70FF152055AB0078E0A6 /* ProxyTest.app */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		A96B7102152055AB0078E0A6 /* Frameworks */ = {
+			isa = PBXGroup;
+			children = (
+				A96B7103152055AB0078E0A6 /* UIKit.framework */,
+				A96B7105152055AB0078E0A6 /* Foundation.framework */,
+				A96B7107152055AB0078E0A6 /* CoreGraphics.framework */,
+			);
+			name = Frameworks;
+			sourceTree = "<group>";
+		};
+		A96B7109152055AB0078E0A6 /* ProxyTest */ = {
+			isa = PBXGroup;
+			children = (
+				A96B7112152055AB0078E0A6 /* JKAppDelegate.h */,
+				A96B7113152055AB0078E0A6 /* JKAppDelegate.m */,
+				A96B710A152055AB0078E0A6 /* Supporting Files */,
+			);
+			path = ProxyTest;
+			sourceTree = "<group>";
+		};
+		A96B710A152055AB0078E0A6 /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				A96B710B152055AB0078E0A6 /* ProxyTest-Info.plist */,
+				A96B710C152055AB0078E0A6 /* InfoPlist.strings */,
+				A96B710F152055AB0078E0A6 /* main.m */,
+				A96B7111152055AB0078E0A6 /* ProxyTest-Prefix.pch */,
+			);
+			name = "Supporting Files";
+			sourceTree = "<group>";
+		};
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+		A96B70FE152055AB0078E0A6 /* ProxyTest */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = A96B7117152055AB0078E0A6 /* Build configuration list for PBXNativeTarget "ProxyTest" */;
+			buildPhases = (
+				A96B70FB152055AB0078E0A6 /* Sources */,
+				A96B70FC152055AB0078E0A6 /* Frameworks */,
+				A96B70FD152055AB0078E0A6 /* Resources */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+			);
+			name = ProxyTest;
+			productName = ProxyTest;
+			productReference = A96B70FF152055AB0078E0A6 /* ProxyTest.app */;
+			productType = "com.apple.product-type.application";
+		};
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+		A96B70F6152055AB0078E0A6 /* Project object */ = {
+			isa = PBXProject;
+			attributes = {
+				CLASSPREFIX = JK;
+				LastUpgradeCheck = 0430;
+				ORGANIZATIONNAME = Cardcloud;
+			};
+			buildConfigurationList = A96B70F9152055AB0078E0A6 /* Build configuration list for PBXProject "ProxyTest" */;
+			compatibilityVersion = "Xcode 3.2";
+			developmentRegion = English;
+			hasScannedForEncodings = 0;
+			knownRegions = (
+				en,
+			);
+			mainGroup = A96B70F4152055AB0078E0A6;
+			productRefGroup = A96B7100152055AB0078E0A6 /* Products */;
+			projectDirPath = "";
+			projectRoot = "";
+			targets = (
+				A96B70FE152055AB0078E0A6 /* ProxyTest */,
+			);
+		};
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+		A96B70FD152055AB0078E0A6 /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				A96B710E152055AB0078E0A6 /* InfoPlist.strings in Resources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+		A96B70FB152055AB0078E0A6 /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				A96B7110152055AB0078E0A6 /* main.m in Sources */,
+				A96B7114152055AB0078E0A6 /* JKAppDelegate.m in Sources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXVariantGroup section */
+		A96B710C152055AB0078E0A6 /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				A96B710D152055AB0078E0A6 /* en */,
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+		A96B7115152055AB0078E0A6 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = NO;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_DYNAMIC_NO_PIC = NO;
+				GCC_OPTIMIZATION_LEVEL = 0;
+				GCC_PREPROCESSOR_DEFINITIONS = (
+					"DEBUG=1",
+					"$(inherited)",
+				);
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 5.1;
+				SDKROOT = iphoneos;
+			};
+			name = Debug;
+		};
+		A96B7116152055AB0078E0A6 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = YES;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 5.1;
+				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
+				SDKROOT = iphoneos;
+				VALIDATE_PRODUCT = YES;
+			};
+			name = Release;
+		};
+		A96B7118152055AB0078E0A6 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "ProxyTest/ProxyTest-Prefix.pch";
+				INFOPLIST_FILE = "ProxyTest/ProxyTest-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Debug;
+		};
+		A96B7119152055AB0078E0A6 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "ProxyTest/ProxyTest-Prefix.pch";
+				INFOPLIST_FILE = "ProxyTest/ProxyTest-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Release;
+		};
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+		A96B70F9152055AB0078E0A6 /* Build configuration list for PBXProject "ProxyTest" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				A96B7115152055AB0078E0A6 /* Debug */,
+				A96B7116152055AB0078E0A6 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+		A96B7117152055AB0078E0A6 /* Build configuration list for PBXNativeTarget "ProxyTest" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				A96B7118152055AB0078E0A6 /* Debug */,
+				A96B7119152055AB0078E0A6 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+		};
+/* End XCConfigurationList section */
+	};
+	rootObject = A96B70F6152055AB0078E0A6 /* Project object */;
+}

ProxyTest/JKAppDelegate.h

+//
+//  JKAppDelegate.h
+//  ProxyTest
+//
+//  Created by Joris Kluivers on 3/26/12.
+//  Copyright (c) 2012 Cardcloud. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface JKAppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end

ProxyTest/JKAppDelegate.m

+//
+//  JKAppDelegate.m
+//  ProxyTest
+//
+//  Created by Joris Kluivers on 3/26/12.
+//  Copyright (c) 2012 Cardcloud. All rights reserved.
+//
+
+#import "JKAppDelegate.h"
+
+@implementation JKAppDelegate
+
+@synthesize window = _window;
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
+    // Override point for customization after application launch.
+    self.window.backgroundColor = [UIColor whiteColor];
+    [self.window makeKeyAndVisible];
+    return YES;
+}
+
+- (void)applicationWillResignActive:(UIApplication *)application
+{
+	// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
+	// Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
+}
+
+- (void)applicationDidEnterBackground:(UIApplication *)application
+{
+	// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 
+	// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
+}
+
+- (void)applicationWillEnterForeground:(UIApplication *)application
+{
+	// Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
+}
+
+- (void)applicationDidBecomeActive:(UIApplication *)application
+{
+	// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
+}
+
+- (void)applicationWillTerminate:(UIApplication *)application
+{
+	// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
+}
+
+@end

ProxyTest/ProxyTest-Info.plist

+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>nl.tarento.${PRODUCT_NAME:rfc1034identifier}</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		<string>armv7</string>
+	</array>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+</dict>
+</plist>

ProxyTest/ProxyTest-Prefix.pch

+//
+// Prefix header for all source files of the 'ProxyTest' target in the 'ProxyTest' project
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_3_0
+#warning "This project uses features only available in iOS SDK 3.0 and later."
+#endif
+
+#ifdef __OBJC__
+	#import <UIKit/UIKit.h>
+	#import <Foundation/Foundation.h>
+#endif

ProxyTest/en.lproj/InfoPlist.strings

+/* Localized versions of Info.plist keys */
+
+//
+//  main.m
+//  ProxyTest
+//
+//  Created by Joris Kluivers on 3/26/12.
+//  Copyright (c) 2012 Cardcloud. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+#import "JKAppDelegate.h"
+
+@interface JKObject : NSObject
+@property(nonatomic, weak) id delegate;
+@end
+
+@implementation JKObject
+@synthesize delegate;
+@end
+
+@interface JKDelegateProxy : NSProxy
+- (id) initWithObject:(NSObject *)object;
+@end
+
+@implementation JKDelegateProxy {
+	NSObject *_obj;
+}
+
+- (id) initWithObject:(NSObject *)object {
+	_obj = object;
+	return self;
+}
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+    return [_obj methodSignatureForSelector:aSelector];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+    [anInvocation setTarget:_obj];
+    [anInvocation invoke];
+    return;
+}
+
+@end
+
+
+
+
+int main(int argc, char *argv[]) {
+	@autoreleasepool {
+	    JKObject *object = [[JKObject alloc] init];
+		JKDelegateProxy *delegate = [[JKDelegateProxy alloc] initWithObject:@"Joris Kluivers"];
+		object.delegate = delegate;
+		NSLog(@"delegate: %@", delegate);
+		NSLog(@"object.delegate: %@", object.delegate);
+		
+		return UIApplicationMain(argc, argv, nil, NSStringFromClass([JKAppDelegate class]));
+	}
+}