From 5ca880943f2258adbaf37be24707639d937b5f6f Mon Sep 17 00:00:00 2001 From: Anak Mirasing Date: Thu, 12 May 2016 18:07:45 +0700 Subject: [PATCH] fix access control --- Omise-iOS_SDK/Omise-iOS_SDK/SDK/Card.swift | 36 +++++++++---------- Omise-iOS_SDK/Omise-iOS_SDK/SDK/Omise.swift | 6 ++-- .../Omise-iOS_SDK/SDK/OmiseToken.swift | 14 ++++---- .../Omise-iOS_SDK/SDK/OmiseTokenRequest.swift | 6 ++-- 4 files changed, 31 insertions(+), 31 deletions(-) diff --git a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Card.swift b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Card.swift index c4501ca..41f2677 100644 --- a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Card.swift +++ b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Card.swift @@ -7,22 +7,22 @@ // public class Card { - var cardId: String? - var livemode: Bool? - var location: String? - var country: String? - var number: String? - var city: String? - var postalCode: String? - var financing: String? - var lastDigits: String? - var brand: String? - var expirationMonth: String? - var expirationYear: String? - var fingerprint: String? - var name: String? - var created: String? - var securityCode: String? - var securityCodeCheck: Bool? - var bank: String? + public var cardId: String? + public var livemode: Bool? + public var location: String? + public var country: String? + public var number: String? + public var city: String? + public var postalCode: String? + public var financing: String? + public var lastDigits: String? + public var brand: String? + public var expirationMonth: String? + public var expirationYear: String? + public var fingerprint: String? + public var name: String? + public var created: String? + public var securityCode: String? + public var securityCodeCheck: Bool? + public var bank: String? } diff --git a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Omise.swift b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Omise.swift index 4e686ea..fda38cf 100644 --- a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Omise.swift +++ b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/Omise.swift @@ -20,7 +20,7 @@ public enum OmiseApi: Int { public class Omise: NSObject, NSURLConnectionDelegate { - var delegate: OmiseRequestDelegate? + public var delegate: OmiseRequestDelegate? var data: NSMutableData? var mTokenRequest: OmiseTokenRequest? var isConnecting: Bool = false @@ -30,7 +30,7 @@ public class Omise: NSObject, NSURLConnectionDelegate { isConnecting = false } - func requestToken(tokenRequest: OmiseTokenRequest?) { + public func requestToken(tokenRequest: OmiseTokenRequest?) { if isConnecting { let omiseError = NSError(domain: OmiseErrorDomain, code:OmiseErrorCode.OmiseServerConnectionError.rawValue , userInfo: ["Connection error": "Running other request."]) @@ -44,7 +44,7 @@ public class Omise: NSObject, NSURLConnectionDelegate { mTokenRequest = tokenRequest let url = NSURL(string: "https://vault.omise.co/tokens") - let OMISE_IOS_VERSION = "2.0.0" + let OMISE_IOS_VERSION = "2.0.1" let req = NSMutableURLRequest(URL: url!, cachePolicy: NSURLRequestCachePolicy.ReloadIgnoringLocalAndRemoteCacheData, timeoutInterval: 15) req.HTTPMethod = "POST" diff --git a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseToken.swift b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseToken.swift index 92b4c41..d5a5b3c 100644 --- a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseToken.swift +++ b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseToken.swift @@ -9,14 +9,14 @@ import Foundation public class OmiseToken: NSObject { - var tokenId: String? - var livemode: Bool? - var location: String? - var used: Bool? - var card: Card? - var created: String? + public var tokenId: String? + public var livemode: Bool? + public var location: String? + public var used: Bool? + public var card: Card? + public var created: String? - override init() { + public override init() { card = Card() } } diff --git a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseTokenRequest.swift b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseTokenRequest.swift index 951d96b..9f9d9e0 100644 --- a/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseTokenRequest.swift +++ b/Omise-iOS_SDK/Omise-iOS_SDK/SDK/OmiseTokenRequest.swift @@ -9,10 +9,10 @@ import Foundation public class OmiseTokenRequest: NSObject { - var card: Card? - var publicKey: String? + public var card: Card? + public var publicKey: String? - override init() { + public override init() { card = Card() } }