diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6a5328e --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +.DS_Store +xcuserdata + +*.xccheckout +*.xcuserstate + +build diff --git a/ChimpKit/ChimpKit.xcodeproj/project.pbxproj b/ChimpKit/ChimpKit.xcodeproj/project.pbxproj new file mode 100644 index 0000000..615fe5f --- /dev/null +++ b/ChimpKit/ChimpKit.xcodeproj/project.pbxproj @@ -0,0 +1,592 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 5F6702641A46E47D00B9B325 /* ChimpKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5F6702581A46E47C00B9B325 /* ChimpKit.framework */; }; + 5F67026B1A46E47D00B9B325 /* ChimpKitTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 5F67026A1A46E47D00B9B325 /* ChimpKitTests.m */; }; + 5F6702761A46E4B700B9B325 /* ChimpKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 5F6702741A46E4B700B9B325 /* ChimpKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 5F6702771A46E4B700B9B325 /* ChimpKit.m in Sources */ = {isa = PBXBuildFile; fileRef = 5F6702751A46E4B700B9B325 /* ChimpKit.m */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 5F6702651A46E47D00B9B325 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 5F67024F1A46E47C00B9B325 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 5F6702571A46E47C00B9B325; + remoteInfo = ChimpKit; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 5F6702581A46E47C00B9B325 /* ChimpKit.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = ChimpKit.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 5F67025C1A46E47D00B9B325 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 5F6702631A46E47D00B9B325 /* ChimpKitTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ChimpKitTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 5F6702691A46E47D00B9B325 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 5F67026A1A46E47D00B9B325 /* ChimpKitTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ChimpKitTests.m; sourceTree = ""; }; + 5F6702741A46E4B700B9B325 /* ChimpKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ChimpKit.h; path = ../../ChimpKit3/ChimpKit.h; sourceTree = ""; }; + 5F6702751A46E4B700B9B325 /* ChimpKit.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ChimpKit.m; path = ../../ChimpKit3/ChimpKit.m; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 5F6702541A46E47C00B9B325 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5F6702601A46E47D00B9B325 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 5F6702641A46E47D00B9B325 /* ChimpKit.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 5F67024E1A46E47C00B9B325 = { + isa = PBXGroup; + children = ( + 5F67025A1A46E47C00B9B325 /* ChimpKit */, + 5F6702671A46E47D00B9B325 /* ChimpKitTests */, + 5F6702591A46E47C00B9B325 /* Products */, + ); + sourceTree = ""; + }; + 5F6702591A46E47C00B9B325 /* Products */ = { + isa = PBXGroup; + children = ( + 5F6702581A46E47C00B9B325 /* ChimpKit.framework */, + 5F6702631A46E47D00B9B325 /* ChimpKitTests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 5F67025A1A46E47C00B9B325 /* ChimpKit */ = { + isa = PBXGroup; + children = ( + 5F6702741A46E4B700B9B325 /* ChimpKit.h */, + 5F6702751A46E4B700B9B325 /* ChimpKit.m */, + 5F67025B1A46E47D00B9B325 /* Supporting Files */, + ); + path = ChimpKit; + sourceTree = ""; + }; + 5F67025B1A46E47D00B9B325 /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 5F67025C1A46E47D00B9B325 /* Info.plist */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; + 5F6702671A46E47D00B9B325 /* ChimpKitTests */ = { + isa = PBXGroup; + children = ( + 5F67026A1A46E47D00B9B325 /* ChimpKitTests.m */, + 5F6702681A46E47D00B9B325 /* Supporting Files */, + ); + path = ChimpKitTests; + sourceTree = ""; + }; + 5F6702681A46E47D00B9B325 /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 5F6702691A46E47D00B9B325 /* Info.plist */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXHeadersBuildPhase section */ + 5F6702551A46E47C00B9B325 /* Headers */ = { + isa = PBXHeadersBuildPhase; + buildActionMask = 2147483647; + files = ( + 5F6702761A46E4B700B9B325 /* ChimpKit.h in Headers */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXHeadersBuildPhase section */ + +/* Begin PBXNativeTarget section */ + 5F6702571A46E47C00B9B325 /* ChimpKit */ = { + isa = PBXNativeTarget; + buildConfigurationList = 5F67026E1A46E47D00B9B325 /* Build configuration list for PBXNativeTarget "ChimpKit" */; + buildPhases = ( + 5F6702531A46E47C00B9B325 /* Sources */, + 5F6702541A46E47C00B9B325 /* Frameworks */, + 5F6702551A46E47C00B9B325 /* Headers */, + 5F6702561A46E47C00B9B325 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = ChimpKit; + productName = ChimpKit; + productReference = 5F6702581A46E47C00B9B325 /* ChimpKit.framework */; + productType = "com.apple.product-type.framework"; + }; + 5F6702621A46E47D00B9B325 /* ChimpKitTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 5F6702711A46E47D00B9B325 /* Build configuration list for PBXNativeTarget "ChimpKitTests" */; + buildPhases = ( + 5F67025F1A46E47D00B9B325 /* Sources */, + 5F6702601A46E47D00B9B325 /* Frameworks */, + 5F6702611A46E47D00B9B325 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 5F6702661A46E47D00B9B325 /* PBXTargetDependency */, + ); + name = ChimpKitTests; + productName = ChimpKitTests; + productReference = 5F6702631A46E47D00B9B325 /* ChimpKitTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 5F67024F1A46E47C00B9B325 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0700; + ORGANIZATIONNAME = MailChimp; + TargetAttributes = { + 5F6702571A46E47C00B9B325 = { + CreatedOnToolsVersion = 6.1; + }; + 5F6702621A46E47D00B9B325 = { + CreatedOnToolsVersion = 6.1; + }; + }; + }; + buildConfigurationList = 5F6702521A46E47C00B9B325 /* Build configuration list for PBXProject "ChimpKit" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 5F67024E1A46E47C00B9B325; + productRefGroup = 5F6702591A46E47C00B9B325 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 5F6702571A46E47C00B9B325 /* ChimpKit */, + 5F6702621A46E47D00B9B325 /* ChimpKitTests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 5F6702561A46E47C00B9B325 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5F6702611A46E47D00B9B325 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 5F6702531A46E47C00B9B325 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 5F6702771A46E4B700B9B325 /* ChimpKit.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5F67025F1A46E47D00B9B325 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 5F67026B1A46E47D00B9B325 /* ChimpKitTests.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 5F6702661A46E47D00B9B325 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 5F6702571A46E47C00B9B325 /* ChimpKit */; + targetProxy = 5F6702651A46E47D00B9B325 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 5F67026C1A46E47D00B9B325 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + 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_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = macosx; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Debug; + }; + 5F67026D1A46E47D00B9B325 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = YES; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = macosx; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; + 5F67026F1A46E47D00B9B325 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "$(INSTALL_PATH)"; + FRAMEWORK_VERSION = A; + INFOPLIST_FILE = ChimpKit/Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_DYLIB_INSTALL_NAME = "@rpath/../Frameworks/$(EXECUTABLE_PATH)"; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Debug; + }; + 5F6702701A46E47D00B9B325 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "$(INSTALL_PATH)"; + FRAMEWORK_VERSION = A; + INFOPLIST_FILE = ChimpKit/Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_DYLIB_INSTALL_NAME = "@rpath/../Frameworks/$(EXECUTABLE_PATH)"; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Release; + }; + 5F6702721A46E47D00B9B325 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + FRAMEWORK_SEARCH_PATHS = ( + "$(DEVELOPER_FRAMEWORKS_DIR)", + "$(inherited)", + ); + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + INFOPLIST_FILE = ChimpKitTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Debug; + }; + 5F6702731A46E47D00B9B325 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + FRAMEWORK_SEARCH_PATHS = ( + "$(DEVELOPER_FRAMEWORKS_DIR)", + "$(inherited)", + ); + INFOPLIST_FILE = ChimpKitTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 5F67028A1A46EFA000B9B325 /* Testing */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + ENABLE_STRICT_OBJC_MSGSEND = YES; + 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_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = macosx; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Testing; + }; + 5F67028B1A46EFA000B9B325 /* Testing */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "$(INSTALL_PATH)"; + FRAMEWORK_VERSION = A; + INFOPLIST_FILE = ChimpKit/Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_DYLIB_INSTALL_NAME = "@rpath/../Frameworks/$(EXECUTABLE_PATH)"; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Testing; + }; + 5F67028C1A46EFA000B9B325 /* Testing */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + FRAMEWORK_SEARCH_PATHS = ( + "$(DEVELOPER_FRAMEWORKS_DIR)", + "$(inherited)", + ); + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + INFOPLIST_FILE = ChimpKitTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Testing; + }; + 5F8E73181AD53F8E007CF280 /* Internal */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + ENABLE_STRICT_OBJC_MSGSEND = YES; + 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_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = macosx; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Internal; + }; + 5F8E73191AD53F8E007CF280 /* Internal */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "$(INSTALL_PATH)"; + FRAMEWORK_VERSION = A; + INFOPLIST_FILE = ChimpKit/Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_DYLIB_INSTALL_NAME = "@rpath/../Frameworks/$(EXECUTABLE_PATH)"; + LD_RUNPATH_SEARCH_PATHS = "@executable_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Internal; + }; + 5F8E731A1AD53F8E007CF280 /* Internal */ = { + isa = XCBuildConfiguration; + buildSettings = { + COMBINE_HIDPI_IMAGES = YES; + FRAMEWORK_SEARCH_PATHS = ( + "$(DEVELOPER_FRAMEWORKS_DIR)", + "$(inherited)", + ); + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + INFOPLIST_FILE = ChimpKitTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "com.mailchimp.$(PRODUCT_NAME:rfc1034identifier)"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Internal; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 5F6702521A46E47C00B9B325 /* Build configuration list for PBXProject "ChimpKit" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5F67026C1A46E47D00B9B325 /* Debug */, + 5F8E73181AD53F8E007CF280 /* Internal */, + 5F67028A1A46EFA000B9B325 /* Testing */, + 5F67026D1A46E47D00B9B325 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 5F67026E1A46E47D00B9B325 /* Build configuration list for PBXNativeTarget "ChimpKit" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5F67026F1A46E47D00B9B325 /* Debug */, + 5F8E73191AD53F8E007CF280 /* Internal */, + 5F67028B1A46EFA000B9B325 /* Testing */, + 5F6702701A46E47D00B9B325 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 5F6702711A46E47D00B9B325 /* Build configuration list for PBXNativeTarget "ChimpKitTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5F6702721A46E47D00B9B325 /* Debug */, + 5F8E731A1AD53F8E007CF280 /* Internal */, + 5F67028C1A46EFA000B9B325 /* Testing */, + 5F6702731A46E47D00B9B325 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 5F67024F1A46E47C00B9B325 /* Project object */; +} diff --git a/ChimpKit/ChimpKit.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/ChimpKit/ChimpKit.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..9cda6ca --- /dev/null +++ b/ChimpKit/ChimpKit.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/ChimpKit/ChimpKit.xcodeproj/xcshareddata/xcschemes/ChimpKit.xcscheme b/ChimpKit/ChimpKit.xcodeproj/xcshareddata/xcschemes/ChimpKit.xcscheme new file mode 100644 index 0000000..b8f3845 --- /dev/null +++ b/ChimpKit/ChimpKit.xcodeproj/xcshareddata/xcschemes/ChimpKit.xcscheme @@ -0,0 +1,113 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ChimpKit/ChimpKit.xcodeproj/xcuserdata/mz2.xcuserdatad/xcschemes/xcschememanagement.plist b/ChimpKit/ChimpKit.xcodeproj/xcuserdata/mz2.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..c8d2615 --- /dev/null +++ b/ChimpKit/ChimpKit.xcodeproj/xcuserdata/mz2.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,27 @@ + + + + + SchemeUserState + + ChimpKit.xcscheme_^#shared#^_ + + orderHint + 0 + + + SuppressBuildableAutocreation + + 5F6702571A46E47C00B9B325 + + primary + + + 5F6702621A46E47D00B9B325 + + primary + + + + + diff --git a/ChimpKit/ChimpKit/Info.plist b/ChimpKit/ChimpKit/Info.plist new file mode 100644 index 0000000..64554a8 --- /dev/null +++ b/ChimpKit/ChimpKit/Info.plist @@ -0,0 +1,28 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + $(CURRENT_PROJECT_VERSION) + NSHumanReadableCopyright + Copyright © 2014 MailChimp. All rights reserved. + NSPrincipalClass + + + diff --git a/ChimpKit/ChimpKitTests/ChimpKitTests.m b/ChimpKit/ChimpKitTests/ChimpKitTests.m new file mode 100644 index 0000000..7f709b0 --- /dev/null +++ b/ChimpKit/ChimpKitTests/ChimpKitTests.m @@ -0,0 +1,40 @@ +// +// ChimpKitTests.m +// ChimpKitTests +// +// Created by Matias Piipari on 21/12/2014. +// Copyright (c) 2014 MailChimp. All rights reserved. +// + +#import +#import + +@interface ChimpKitTests : XCTestCase + +@end + +@implementation ChimpKitTests + +- (void)setUp { + [super setUp]; + // Put setup code here. This method is called before the invocation of each test method in the class. +} + +- (void)tearDown { + // Put teardown code here. This method is called after the invocation of each test method in the class. + [super tearDown]; +} + +- (void)testExample { + // This is an example of a functional test case. + XCTAssert(YES, @"Pass"); +} + +- (void)testPerformanceExample { + // This is an example of a performance test case. + [self measureBlock:^{ + // Put the code you want to measure the time of here. + }]; +} + +@end diff --git a/ChimpKit/ChimpKitTests/Info.plist b/ChimpKit/ChimpKitTests/Info.plist new file mode 100644 index 0000000..ba72822 --- /dev/null +++ b/ChimpKit/ChimpKitTests/Info.plist @@ -0,0 +1,24 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + + diff --git a/ChimpKit3/ChimpKit.h b/ChimpKit3/ChimpKit.h index ddbe9f1..ec45a19 100644 --- a/ChimpKit3/ChimpKit.h +++ b/ChimpKit3/ChimpKit.h @@ -8,13 +8,18 @@ #import +//! Project version number for ChimpKit. +FOUNDATION_EXPORT double ChimpKitVersionNumber; + +//! Project version string for ChimpKit. +FOUNDATION_EXPORT const unsigned char ChimpKitVersionString[]; #define kCKDebug 0 #define kDefaultTimeoutInterval 15.0f typedef enum { - kChimpKitErrorInvalidAPIKey = 0, + kChimpKitErrorInvalidAPIKey = 1, kChimpKitErrorInvalidDelegate, kChimpKitErrorInvalidCompletionHandler } ChimpKitError; diff --git a/ChimpKit3/ChimpKit.m b/ChimpKit3/ChimpKit.m index ba98198..7ee7dcd 100644 --- a/ChimpKit3/ChimpKit.m +++ b/ChimpKit3/ChimpKit.m @@ -112,7 +112,9 @@ - (NSUInteger)callApiMethod:(NSString *)aMethod withApiKey:(NSString *)anApiKey - (NSUInteger)callApiMethod:(NSString *)aMethod withApiKey:(NSString *)anApiKey params:(NSDictionary *)someParams andCompletionHandler:(ChimpKitRequestCompletionBlock)aHandler orDelegate:(id)aDelegate { if ((anApiKey == nil) && (self.apiKey == nil)) { - NSError *error = [NSError errorWithDomain:kErrorDomain code:kChimpKitErrorInvalidAPIKey userInfo:nil]; + NSError *error = [NSError errorWithDomain:kErrorDomain + code:kChimpKitErrorInvalidAPIKey + userInfo:@{NSLocalizedDescriptionKey : @"Invalid API key"}]; if (aDelegate && [aDelegate respondsToSelector:@selector(ckRequestFailedWithIdentifier:andError:)]) { [aDelegate ckRequestFailedWithIdentifier:0 andError:error]; @@ -172,9 +174,11 @@ - (NSUInteger)callApiMethod:(NSString *)aMethod withApiKey:(NSString *)anApiKey [dataTask resume]; +#ifdef __IPHONE_OS_VERSION_MIN_REQUIRED dispatch_async(dispatch_get_main_queue(), ^{ [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible:YES]; }); +#endif [self.requests setObject:requestWrapper forKey:[NSNumber numberWithUnsignedInteger:[dataTask taskIdentifier]]]; @@ -208,9 +212,12 @@ - (void)URLSession:(NSURLSession *)session dataTask:(NSURLSessionDataTask *)data } - (void)URLSession:(NSURLSession *)session task:(NSURLSessionTask *)task didCompleteWithError:(NSError *)error { + +#ifdef __IPHONE_OS_VERSION_MIN_REQUIRED dispatch_async(dispatch_get_main_queue(), ^{ [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible:NO]; }); +#endif ChimpKitRequestWrapper *requestWrapper = [self.requests objectForKey:[NSNumber numberWithUnsignedInteger:[task taskIdentifier]]];