Skip to content

Commit

Permalink
Renamed to Proba.
Browse files Browse the repository at this point in the history
  • Loading branch information
danilValeev committed Sep 14, 2021
1 parent d44ad8e commit b573e8d
Show file tree
Hide file tree
Showing 45 changed files with 401 additions and 410 deletions.
42 changes: 0 additions & 42 deletions AppboosterSDK.podspec

This file was deleted.

14 changes: 0 additions & 14 deletions AppboosterSDK/Classes/AppboosterABError.swift

This file was deleted.

14 changes: 0 additions & 14 deletions AppboosterSDK/Classes/AppboosterExperimentOption.swift

This file was deleted.

15 changes: 0 additions & 15 deletions AppboosterSDK/Classes/AppboosterExperimentStatus.swift

This file was deleted.

20 changes: 0 additions & 20 deletions AppboosterSDK/Classes/AppboosterExperimentValue.swift

This file was deleted.

13 changes: 0 additions & 13 deletions AppboosterSDK/Classes/AppboosterExperimentValueMeta.swift

This file was deleted.

13 changes: 0 additions & 13 deletions AppboosterSDK/Classes/AppboosterExperimentsResponse.swift

This file was deleted.

14 changes: 0 additions & 14 deletions AppboosterSDK/Classes/AppboosterExperimentsValuesResponse.swift

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2020 Appbooster
Copyright (c) 2020 Proba

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
10 changes: 5 additions & 5 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@
import PackageDescription

let package = Package(
name: "AppboosterSDK",
name: "Proba",
platforms: [.iOS(.v9)],
products: [
.library(
name: "AppboosterSDK",
targets: ["AppboosterSDK"]
name: "Proba",
targets: ["Proba"]
),
],
targets: [
.target(
name: "AppboosterSDK",
path: "AppboosterSDK"
name: "Proba",
path: "Proba"
),
]
)
29 changes: 29 additions & 0 deletions Proba.podspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#
# Be sure to run `pod lib lint Proba.podspec' to ensure this is a
# valid spec before submitting.
#
# Any lines starting with a # are optional, but their use is encouraged
# To learn more about a Podspec see https://guides.cocoapods.org/syntax/podspec.html
#

Pod::Spec.new do |s|
s.name = 'Proba'
s.version = '0.2.6'
s.summary = 'A/B testing in mobile apps.'
s.description = 'A/B testing in mobile apps. Based on Bayesian statistics.'
s.homepage = 'https://proba.ai'
s.authors = { 'Proba' => 'hello@proba.ai' }
s.license = { :type => 'MIT', :file => 'LICENSE' }
s.source = { :git => 'https://github.com/proba-ai/proba-sdk-ios.git', :tag => s.version }

s.ios.deployment_target = '9.0'

s.source_files = 'Proba/Classes/*', 'Proba/Classes/**/*'

s.resource_bundles = {
'Proba' => ['Proba/Assets/*.png']
}

s.swift_version = "5.0"

end
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
16 changes: 8 additions & 8 deletions AppboosterSDK/Classes/API.swift → Proba/Classes/API.swift
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//
// API.swift
// AppboosterSDK
// Proba
//
// Created by Appbooster on 22/07/2020.
// Copyright © 2020 Appbooster. All rights reserved.
// Created by Proba on 22/07/2020.
// Copyright © 2020 Proba. All rights reserved.
//

import Foundation
Expand All @@ -18,7 +18,7 @@ struct API {
static func get(_ url: URL,
headers: [String: String]?,
timeoutInterval: TimeInterval,
completion: @escaping (Data?, AppboosterABError?) -> Void) {
completion: @escaping (Data?, ProbaABError?) -> Void) {
var urlRequest = URLRequest(url: url)
urlRequest.httpMethod = "GET"
urlRequest.allHTTPHeaderFields = headers
Expand All @@ -27,7 +27,7 @@ struct API {
URLSession.shared.dataTask(with: urlRequest) { data, response, error in
if let error = error {
DispatchQueue.main.async {
let abError = AppboosterABError(error: "URL error: \(error.localizedDescription)",
let abError = ProbaABError(error: "URL error: \(error.localizedDescription)",
code: (error as? URLError)?.errorCode ?? 0)
completion(nil, abError)
}
Expand All @@ -37,7 +37,7 @@ struct API {

guard let response = response as? HTTPURLResponse else {
DispatchQueue.main.async {
let abError = AppboosterABError(error: "Invalid response from server",
let abError = ProbaABError(error: "Invalid response from server",
code: 0)
completion(nil, abError)
}
Expand All @@ -47,7 +47,7 @@ struct API {

guard 200 ... 299 ~= response.statusCode else {
DispatchQueue.main.async {
let abError = AppboosterABError(error: "Server error",
let abError = ProbaABError(error: "Server error",
code: response.statusCode)
completion(nil, abError)
}
Expand All @@ -57,7 +57,7 @@ struct API {

guard let data = data else {
DispatchQueue.main.async {
let abError = AppboosterABError(error: "Invalid response data",
let abError = ProbaABError(error: "Invalid response data",
code: 0)
completion(nil, abError)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//
// AnyCodable.swift
// AppboosterSDK
// Proba
//
// Created by Appbooster on 22/07/2020.
// Copyright © 2020 Appbooster. All rights reserved.
// Created by Proba on 22/07/2020.
// Copyright © 2020 Proba. All rights reserved.
//

import Foundation
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//
// ExperimentsCell.swift
// AppboosterSDK
// Proba
//
// Created by Appbooster on 22/07/2020.
// Copyright © 2020 Appbooster. All rights reserved.
// Created by Proba on 22/07/2020.
// Copyright © 2020 Proba. All rights reserved.
//

import UIKit
Expand All @@ -22,7 +22,7 @@ class ExperimentCell: UITableViewCell {
private var keyLabel: UILabel!

func configure(
with option: AppboosterExperimentOption,
with option: ProbaExperimentOption,
isCurrent: Bool,
isSelected: Bool
) {
Expand All @@ -32,8 +32,8 @@ class ExperimentCell: UITableViewCell {

var image: UIImage?

let bundle = Bundle(for: AppboosterSDK.self)
if let bundleURL = bundle.resourceURL?.appendingPathComponent("AppboosterSDK.bundle") {
let bundle = Bundle(for: Proba.self)
if let bundleURL = bundle.resourceURL?.appendingPathComponent("Proba.bundle") {
let resourceBundle = Bundle(url: bundleURL)
let imageName = isSelected ? "checkbox-fill" : "checkbox"
image = UIImage(named: imageName, in: resourceBundle, compatibleWith: nil)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//
// ExperimentsController.swift
// AppboosterSDK
// Proba
//
// Created by Appbooster on 22/07/2020.
// Copyright © 2020 Appbooster. All rights reserved.
// Created by Proba on 22/07/2020.
// Copyright © 2020 Proba. All rights reserved.
//

import UIKit
Expand All @@ -22,7 +22,7 @@ class ExperimentsController: UITableViewController {

// MARK: - Private Properties

private var experiments: [AppboosterExperiment] = State.experiments {
private var experiments: [ProbaExperiment] = State.experiments {
didSet {
State.experiments = experiments
}
Expand Down Expand Up @@ -126,7 +126,7 @@ class ExperimentsController: UITableViewController {
if let index = State.debugExperimentsValues.firstIndex(where: { experimentValue in experimentValue.key == experiment.key }) {
State.debugExperimentsValues.remove(at: index)
}
let experimentValue = AppboosterExperimentValue(key: experiment.key, value: experiment.options[indexPath.row].value, optionId: nil)
let experimentValue = ProbaExperimentValue(key: experiment.key, value: experiment.options[indexPath.row].value, optionId: nil)
State.debugExperimentsValues.append(experimentValue)

tableView.deselectRow(at: indexPath, animated: true)
Expand Down Expand Up @@ -233,8 +233,8 @@ class ExperimentsController: UITableViewController {

var arrowImage: UIImage?

let bundle = Bundle(for: AppboosterSDK.self)
if let bundleURL = bundle.resourceURL?.appendingPathComponent("AppboosterSDK.bundle") {
let bundle = Bundle(for: Proba.self)
if let bundleURL = bundle.resourceURL?.appendingPathComponent("Proba.bundle") {
let resourceBundle = Bundle(url: bundleURL)
arrowImage = UIImage(named: "arrow", in: resourceBundle, compatibleWith: nil)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//
// JWTToken.swift
// AppboosterSDK
// Proba
//
// Created by Appbooster on 22/07/2020.
// Copyright © 2020 Appbooster. All rights reserved.
// Created by Proba on 22/07/2020.
// Copyright © 2020 Proba. All rights reserved.
//

import Foundation
Expand Down
Loading

0 comments on commit b573e8d

Please sign in to comment.