@amplitude/plugin-engagement-react-native 1.3.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/PluginEngagementReactNative.podspec +1 -1
- package/android/build.gradle +1 -1
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/Info.plist +48 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/AmplitudeEngagementSwift +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Apache License.txt +203 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Assets.car +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Info.plist +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios.abi.json +15469 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios.private.swiftinterface +272 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios.swiftinterface +272 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Black.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-BlackItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Bold.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-BoldItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Italic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Light.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-LightItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Medium.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-MediumItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Regular.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-Thin.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/Roboto-ThinItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/RobotoCondensed-Bold.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/RobotoCondensed-BoldItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/RobotoCondensed-Italic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/RobotoCondensed-Light.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/RobotoCondensed-LightItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/RobotoCondensed-Regular.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/AmplitudeEngagementSwift.framework/engagement.js +25174 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Info.plist +20 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/DWARF/AmplitudeEngagementSwift +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/Relocations/aarch64/AmplitudeEngagementSwift.yml +11379 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/Swift/aarch64/AmplitudeCore.swiftinterface +175 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/AmplitudeEngagementSwift +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Apache License.txt +203 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Assets.car +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Info.plist +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios-simulator.abi.json +15469 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +272 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/arm64-apple-ios-simulator.swiftinterface +272 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/x86_64-apple-ios-simulator.abi.json +15469 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +272 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Modules/AmplitudeEngagementSwift.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +272 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Black.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-BlackItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Bold.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-BoldItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Italic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Light.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-LightItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Medium.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-MediumItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Regular.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-Thin.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/Roboto-ThinItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/RobotoCondensed-Bold.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/RobotoCondensed-BoldItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/RobotoCondensed-Italic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/RobotoCondensed-Light.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/RobotoCondensed-LightItalic.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/RobotoCondensed-Regular.ttf +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/_CodeSignature/CodeResources +443 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/AmplitudeEngagementSwift.framework/engagement.js +25174 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Info.plist +20 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/DWARF/AmplitudeEngagementSwift +0 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/Relocations/aarch64/AmplitudeEngagementSwift.yml +11403 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/Relocations/x86_64/AmplitudeEngagementSwift.yml +11343 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/Swift/aarch64/AmplitudeCore.swiftinterface +175 -0
- package/ios/Frameworks/AmplitudeEngagementSwift.xcframework/ios-arm64_x86_64-simulator/dSYMs/AmplitudeEngagementSwift.framework.dSYM/Contents/Resources/Swift/x86_64/AmplitudeCore.swiftinterface +175 -0
- package/ios/Frameworks/CQuickJS.xcframework/Info.plist +44 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/CQuickJS +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/Headers/quickjs-libc.h +66 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/Headers/quickjs.h +1168 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/Info.plist +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/Modules/module.modulemap +7 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/VERSION +1 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/CQuickJS +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/Headers/quickjs-libc.h +66 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/Headers/quickjs.h +1168 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/Info.plist +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/Modules/module.modulemap +7 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/VERSION +1 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/_CodeSignature/CodeDirectory +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/_CodeSignature/CodeRequirements +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/_CodeSignature/CodeRequirements-1 +0 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/_CodeSignature/CodeResources +162 -0
- package/ios/Frameworks/CQuickJS.xcframework/ios-arm64_x86_64-simulator/CQuickJS.framework/_CodeSignature/CodeSignature +0 -0
- package/lib/module/build-version.json +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
// swift-interface-format-version: 1.0
|
|
2
|
+
// swift-compiler-version: Apple Swift version 6.0.2 effective-5.10 (swiftlang-6.0.2.1.2 clang-1600.0.26.4)
|
|
3
|
+
// swift-module-flags: -target arm64-apple-ios11.0-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -enable-bare-slash-regex -module-name AmplitudeCore
|
|
4
|
+
// swift-module-flags-ignorable: -no-verify-emitted-module-interface
|
|
5
|
+
import Combine
|
|
6
|
+
import Foundation
|
|
7
|
+
import OSLog
|
|
8
|
+
import Swift
|
|
9
|
+
import _Concurrency
|
|
10
|
+
import _StringProcessing
|
|
11
|
+
import _SwiftConcurrencyShims
|
|
12
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
13
|
+
public struct AmplitudeContext {
|
|
14
|
+
public let apiKey: Swift.String
|
|
15
|
+
public let instanceName: Swift.String
|
|
16
|
+
public let serverZone: AmplitudeCore.ServerZone
|
|
17
|
+
public let remoteConfigClient: AmplitudeCore.RemoteConfigClient
|
|
18
|
+
public let logger: any AmplitudeCore.CoreLogger
|
|
19
|
+
public init(apiKey: Swift.String, instanceName: Swift.String = "$default_instance", serverZone: AmplitudeCore.ServerZone = .US, logger: any AmplitudeCore.CoreLogger = OSLogger(logLevel: .error))
|
|
20
|
+
}
|
|
21
|
+
@objc public enum LogLevel : Swift.Int, Swift.Comparable, Swift.Sendable {
|
|
22
|
+
case off = 0
|
|
23
|
+
case error = 1
|
|
24
|
+
case warn = 2
|
|
25
|
+
case log = 3
|
|
26
|
+
case debug = 4
|
|
27
|
+
public static func < (lhs: AmplitudeCore.LogLevel, rhs: AmplitudeCore.LogLevel) -> Swift.Bool
|
|
28
|
+
public init?(rawValue: Swift.Int)
|
|
29
|
+
public typealias RawValue = Swift.Int
|
|
30
|
+
public var rawValue: Swift.Int {
|
|
31
|
+
get
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
@objc @preconcurrency public protocol CoreLogger : Swift.Sendable {
|
|
35
|
+
@objc func error(message: Swift.String)
|
|
36
|
+
@objc func warn(message: Swift.String)
|
|
37
|
+
@objc func log(message: Swift.String)
|
|
38
|
+
@objc func debug(message: Swift.String)
|
|
39
|
+
}
|
|
40
|
+
final public class OSLogger : AmplitudeCore.CoreLogger {
|
|
41
|
+
final public let logLevel: AmplitudeCore.LogLevel
|
|
42
|
+
public init(logLevel: AmplitudeCore.LogLevel = .off)
|
|
43
|
+
@objc final public func error(message: Swift.String)
|
|
44
|
+
@objc final public func warn(message: Swift.String)
|
|
45
|
+
@objc final public func log(message: Swift.String)
|
|
46
|
+
@objc final public func debug(message: Swift.String)
|
|
47
|
+
final public func log(_ logLevel: AmplitudeCore.LogLevel, _ message: Swift.String)
|
|
48
|
+
@objc deinit
|
|
49
|
+
}
|
|
50
|
+
#if compiler(>=5.3) && $PrimaryAssociatedTypes2
|
|
51
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
52
|
+
public protocol AnalyticsClient<Identity> : AnyObject {
|
|
53
|
+
associatedtype Identity : AmplitudeCore.AnalyticsIdentity
|
|
54
|
+
var identity: Self.Identity { get }
|
|
55
|
+
var sessionId: Swift.Int64 { get }
|
|
56
|
+
var optOut: Swift.Bool { get }
|
|
57
|
+
func track(eventType: Swift.String, eventProperties: [Swift.String : Any]?)
|
|
58
|
+
}
|
|
59
|
+
#else
|
|
60
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
61
|
+
public protocol AnalyticsClient : AnyObject {
|
|
62
|
+
associatedtype Identity : AmplitudeCore.AnalyticsIdentity
|
|
63
|
+
var identity: Self.Identity { get }
|
|
64
|
+
var sessionId: Swift.Int64 { get }
|
|
65
|
+
var optOut: Swift.Bool { get }
|
|
66
|
+
func track(eventType: Swift.String, eventProperties: [Swift.String : Any]?)
|
|
67
|
+
}
|
|
68
|
+
#endif
|
|
69
|
+
public protocol AnalyticsEvent {
|
|
70
|
+
var userId: Swift.String? { get }
|
|
71
|
+
var deviceId: Swift.String? { get }
|
|
72
|
+
var timestamp: Swift.Int64? { get }
|
|
73
|
+
var sessionId: Swift.Int64? { get }
|
|
74
|
+
var eventType: Swift.String { get }
|
|
75
|
+
var eventProperties: [Swift.String : Any]? { get set }
|
|
76
|
+
}
|
|
77
|
+
public protocol AnalyticsIdentity {
|
|
78
|
+
var deviceId: Swift.String? { get }
|
|
79
|
+
var userId: Swift.String? { get }
|
|
80
|
+
var userProperties: [Swift.String : Any] { get }
|
|
81
|
+
}
|
|
82
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
83
|
+
public protocol PluginHost {
|
|
84
|
+
func plugin(name: Swift.String) -> (any AmplitudeCore.UniversalPlugin)?
|
|
85
|
+
func plugins<PluginType>(type: PluginType.Type) -> [PluginType] where PluginType : AmplitudeCore.UniversalPlugin
|
|
86
|
+
}
|
|
87
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
88
|
+
extension AmplitudeCore.PluginHost {
|
|
89
|
+
public func plugins<PluginType>(type: PluginType.Type) -> [PluginType] where PluginType : AmplitudeCore.UniversalPlugin
|
|
90
|
+
}
|
|
91
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
92
|
+
public protocol UniversalPlugin : AnyObject {
|
|
93
|
+
var name: Swift.String? { get }
|
|
94
|
+
func setup(analyticsClient: any AmplitudeCore.AnalyticsClient, amplitudeContext: AmplitudeCore.AmplitudeContext)
|
|
95
|
+
func execute<Event>(_ event: inout Event) where Event : AmplitudeCore.AnalyticsEvent
|
|
96
|
+
func teardown()
|
|
97
|
+
func onIdentityChanged(_ identity: any AmplitudeCore.AnalyticsIdentity)
|
|
98
|
+
func onSessionIdChanged(_ sessionId: Swift.Int64)
|
|
99
|
+
func onOptOutChanged(_ optOut: Swift.Bool)
|
|
100
|
+
}
|
|
101
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
102
|
+
extension AmplitudeCore.UniversalPlugin {
|
|
103
|
+
public var name: Swift.String? {
|
|
104
|
+
get
|
|
105
|
+
}
|
|
106
|
+
public func setup(analyticsClient: any AmplitudeCore.AnalyticsClient, amplitudeContext: AmplitudeCore.AmplitudeContext)
|
|
107
|
+
public func execute<Event>(_ event: inout Event) where Event : AmplitudeCore.AnalyticsEvent
|
|
108
|
+
public func teardown()
|
|
109
|
+
public func onIdentityChanged(_ identity: any AmplitudeCore.AnalyticsIdentity)
|
|
110
|
+
public func onSessionIdChanged(_ sessionId: Swift.Int64)
|
|
111
|
+
public func onOptOutChanged(_ optOut: Swift.Bool)
|
|
112
|
+
}
|
|
113
|
+
@objc @_hasMissingDesignatedInitializers @available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
114
|
+
public actor RemoteConfigClient : ObjectiveC.NSObject {
|
|
115
|
+
public enum DeliveryMode : Swift.Sendable {
|
|
116
|
+
case all
|
|
117
|
+
case waitForRemote(timeout: Foundation.TimeInterval = 3)
|
|
118
|
+
}
|
|
119
|
+
public enum Source : Swift.Sendable {
|
|
120
|
+
case cache
|
|
121
|
+
case remote
|
|
122
|
+
public static func == (a: AmplitudeCore.RemoteConfigClient.Source, b: AmplitudeCore.RemoteConfigClient.Source) -> Swift.Bool
|
|
123
|
+
public func hash(into hasher: inout Swift.Hasher)
|
|
124
|
+
public var hashValue: Swift.Int {
|
|
125
|
+
get
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
public enum RemoteConfigError : Swift.Error {
|
|
129
|
+
case notInCache
|
|
130
|
+
case invalidServerURL
|
|
131
|
+
case badResponse
|
|
132
|
+
case preInit
|
|
133
|
+
case cancelled
|
|
134
|
+
public static func == (a: AmplitudeCore.RemoteConfigClient.RemoteConfigError, b: AmplitudeCore.RemoteConfigClient.RemoteConfigError) -> Swift.Bool
|
|
135
|
+
public func hash(into hasher: inout Swift.Hasher)
|
|
136
|
+
public var hashValue: Swift.Int {
|
|
137
|
+
get
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
public typealias RemoteConfig = [Swift.String : any Swift.Sendable]
|
|
141
|
+
public typealias RemoteConfigCallback = @Sendable (AmplitudeCore.RemoteConfigClient.RemoteConfig?, AmplitudeCore.RemoteConfigClient.Source, Foundation.Date?) -> Swift.Void
|
|
142
|
+
public typealias RemoteConfigSubscription = Swift.Sendable
|
|
143
|
+
public convenience init(apiKey: Swift.String, serverZone: AmplitudeCore.ServerZone, instanceName: Swift.String? = nil, logger: any AmplitudeCore.CoreLogger)
|
|
144
|
+
@discardableResult
|
|
145
|
+
nonisolated public func subscribe(key: Swift.String? = nil, deliveryMode: AmplitudeCore.RemoteConfigClient.DeliveryMode = .all, callback: @escaping AmplitudeCore.RemoteConfigClient.RemoteConfigCallback) -> any Swift.Sendable
|
|
146
|
+
nonisolated public func unsubscribe(_ token: any Swift.Sendable)
|
|
147
|
+
nonisolated public func updateConfigs()
|
|
148
|
+
@objc deinit
|
|
149
|
+
@available(iOS 13.0, tvOS 13.0, watchOS 6.0, macOS 10.15, *)
|
|
150
|
+
@_semantics("defaultActor") nonisolated final public var unownedExecutor: _Concurrency.UnownedSerialExecutor {
|
|
151
|
+
get
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
@objc(AMPServerZone) public enum ServerZone : Swift.Int, Swift.Sendable {
|
|
155
|
+
case US
|
|
156
|
+
case EU
|
|
157
|
+
public typealias RawValue = Swift.String
|
|
158
|
+
public var rawValue: AmplitudeCore.ServerZone.RawValue {
|
|
159
|
+
get
|
|
160
|
+
}
|
|
161
|
+
public init?(rawValue: AmplitudeCore.ServerZone.RawValue)
|
|
162
|
+
}
|
|
163
|
+
extension AmplitudeCore.LogLevel : Swift.Hashable {}
|
|
164
|
+
extension AmplitudeCore.LogLevel : Swift.RawRepresentable {}
|
|
165
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
166
|
+
extension AmplitudeCore.RemoteConfigClient.Source : Swift.Equatable {}
|
|
167
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
168
|
+
extension AmplitudeCore.RemoteConfigClient.Source : Swift.Hashable {}
|
|
169
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
170
|
+
extension AmplitudeCore.RemoteConfigClient.RemoteConfigError : Swift.Equatable {}
|
|
171
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
172
|
+
extension AmplitudeCore.RemoteConfigClient.RemoteConfigError : Swift.Hashable {}
|
|
173
|
+
extension AmplitudeCore.ServerZone : Swift.Equatable {}
|
|
174
|
+
extension AmplitudeCore.ServerZone : Swift.Hashable {}
|
|
175
|
+
extension AmplitudeCore.ServerZone : Swift.RawRepresentable {}
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
// swift-interface-format-version: 1.0
|
|
2
|
+
// swift-compiler-version: Apple Swift version 6.0.2 effective-5.10 (swiftlang-6.0.2.1.2 clang-1600.0.26.4)
|
|
3
|
+
// swift-module-flags: -target x86_64-apple-ios11.0-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -enable-bare-slash-regex -module-name AmplitudeCore
|
|
4
|
+
// swift-module-flags-ignorable: -no-verify-emitted-module-interface
|
|
5
|
+
import Combine
|
|
6
|
+
import Foundation
|
|
7
|
+
import OSLog
|
|
8
|
+
import Swift
|
|
9
|
+
import _Concurrency
|
|
10
|
+
import _StringProcessing
|
|
11
|
+
import _SwiftConcurrencyShims
|
|
12
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
13
|
+
public struct AmplitudeContext {
|
|
14
|
+
public let apiKey: Swift.String
|
|
15
|
+
public let instanceName: Swift.String
|
|
16
|
+
public let serverZone: AmplitudeCore.ServerZone
|
|
17
|
+
public let remoteConfigClient: AmplitudeCore.RemoteConfigClient
|
|
18
|
+
public let logger: any AmplitudeCore.CoreLogger
|
|
19
|
+
public init(apiKey: Swift.String, instanceName: Swift.String = "$default_instance", serverZone: AmplitudeCore.ServerZone = .US, logger: any AmplitudeCore.CoreLogger = OSLogger(logLevel: .error))
|
|
20
|
+
}
|
|
21
|
+
@objc public enum LogLevel : Swift.Int, Swift.Comparable, Swift.Sendable {
|
|
22
|
+
case off = 0
|
|
23
|
+
case error = 1
|
|
24
|
+
case warn = 2
|
|
25
|
+
case log = 3
|
|
26
|
+
case debug = 4
|
|
27
|
+
public static func < (lhs: AmplitudeCore.LogLevel, rhs: AmplitudeCore.LogLevel) -> Swift.Bool
|
|
28
|
+
public init?(rawValue: Swift.Int)
|
|
29
|
+
public typealias RawValue = Swift.Int
|
|
30
|
+
public var rawValue: Swift.Int {
|
|
31
|
+
get
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
@objc @preconcurrency public protocol CoreLogger : Swift.Sendable {
|
|
35
|
+
@objc func error(message: Swift.String)
|
|
36
|
+
@objc func warn(message: Swift.String)
|
|
37
|
+
@objc func log(message: Swift.String)
|
|
38
|
+
@objc func debug(message: Swift.String)
|
|
39
|
+
}
|
|
40
|
+
final public class OSLogger : AmplitudeCore.CoreLogger {
|
|
41
|
+
final public let logLevel: AmplitudeCore.LogLevel
|
|
42
|
+
public init(logLevel: AmplitudeCore.LogLevel = .off)
|
|
43
|
+
@objc final public func error(message: Swift.String)
|
|
44
|
+
@objc final public func warn(message: Swift.String)
|
|
45
|
+
@objc final public func log(message: Swift.String)
|
|
46
|
+
@objc final public func debug(message: Swift.String)
|
|
47
|
+
final public func log(_ logLevel: AmplitudeCore.LogLevel, _ message: Swift.String)
|
|
48
|
+
@objc deinit
|
|
49
|
+
}
|
|
50
|
+
#if compiler(>=5.3) && $PrimaryAssociatedTypes2
|
|
51
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
52
|
+
public protocol AnalyticsClient<Identity> : AnyObject {
|
|
53
|
+
associatedtype Identity : AmplitudeCore.AnalyticsIdentity
|
|
54
|
+
var identity: Self.Identity { get }
|
|
55
|
+
var sessionId: Swift.Int64 { get }
|
|
56
|
+
var optOut: Swift.Bool { get }
|
|
57
|
+
func track(eventType: Swift.String, eventProperties: [Swift.String : Any]?)
|
|
58
|
+
}
|
|
59
|
+
#else
|
|
60
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
61
|
+
public protocol AnalyticsClient : AnyObject {
|
|
62
|
+
associatedtype Identity : AmplitudeCore.AnalyticsIdentity
|
|
63
|
+
var identity: Self.Identity { get }
|
|
64
|
+
var sessionId: Swift.Int64 { get }
|
|
65
|
+
var optOut: Swift.Bool { get }
|
|
66
|
+
func track(eventType: Swift.String, eventProperties: [Swift.String : Any]?)
|
|
67
|
+
}
|
|
68
|
+
#endif
|
|
69
|
+
public protocol AnalyticsEvent {
|
|
70
|
+
var userId: Swift.String? { get }
|
|
71
|
+
var deviceId: Swift.String? { get }
|
|
72
|
+
var timestamp: Swift.Int64? { get }
|
|
73
|
+
var sessionId: Swift.Int64? { get }
|
|
74
|
+
var eventType: Swift.String { get }
|
|
75
|
+
var eventProperties: [Swift.String : Any]? { get set }
|
|
76
|
+
}
|
|
77
|
+
public protocol AnalyticsIdentity {
|
|
78
|
+
var deviceId: Swift.String? { get }
|
|
79
|
+
var userId: Swift.String? { get }
|
|
80
|
+
var userProperties: [Swift.String : Any] { get }
|
|
81
|
+
}
|
|
82
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
83
|
+
public protocol PluginHost {
|
|
84
|
+
func plugin(name: Swift.String) -> (any AmplitudeCore.UniversalPlugin)?
|
|
85
|
+
func plugins<PluginType>(type: PluginType.Type) -> [PluginType] where PluginType : AmplitudeCore.UniversalPlugin
|
|
86
|
+
}
|
|
87
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
88
|
+
extension AmplitudeCore.PluginHost {
|
|
89
|
+
public func plugins<PluginType>(type: PluginType.Type) -> [PluginType] where PluginType : AmplitudeCore.UniversalPlugin
|
|
90
|
+
}
|
|
91
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
92
|
+
public protocol UniversalPlugin : AnyObject {
|
|
93
|
+
var name: Swift.String? { get }
|
|
94
|
+
func setup(analyticsClient: any AmplitudeCore.AnalyticsClient, amplitudeContext: AmplitudeCore.AmplitudeContext)
|
|
95
|
+
func execute<Event>(_ event: inout Event) where Event : AmplitudeCore.AnalyticsEvent
|
|
96
|
+
func teardown()
|
|
97
|
+
func onIdentityChanged(_ identity: any AmplitudeCore.AnalyticsIdentity)
|
|
98
|
+
func onSessionIdChanged(_ sessionId: Swift.Int64)
|
|
99
|
+
func onOptOutChanged(_ optOut: Swift.Bool)
|
|
100
|
+
}
|
|
101
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
102
|
+
extension AmplitudeCore.UniversalPlugin {
|
|
103
|
+
public var name: Swift.String? {
|
|
104
|
+
get
|
|
105
|
+
}
|
|
106
|
+
public func setup(analyticsClient: any AmplitudeCore.AnalyticsClient, amplitudeContext: AmplitudeCore.AmplitudeContext)
|
|
107
|
+
public func execute<Event>(_ event: inout Event) where Event : AmplitudeCore.AnalyticsEvent
|
|
108
|
+
public func teardown()
|
|
109
|
+
public func onIdentityChanged(_ identity: any AmplitudeCore.AnalyticsIdentity)
|
|
110
|
+
public func onSessionIdChanged(_ sessionId: Swift.Int64)
|
|
111
|
+
public func onOptOutChanged(_ optOut: Swift.Bool)
|
|
112
|
+
}
|
|
113
|
+
@objc @_hasMissingDesignatedInitializers @available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
114
|
+
public actor RemoteConfigClient : ObjectiveC.NSObject {
|
|
115
|
+
public enum DeliveryMode : Swift.Sendable {
|
|
116
|
+
case all
|
|
117
|
+
case waitForRemote(timeout: Foundation.TimeInterval = 3)
|
|
118
|
+
}
|
|
119
|
+
public enum Source : Swift.Sendable {
|
|
120
|
+
case cache
|
|
121
|
+
case remote
|
|
122
|
+
public static func == (a: AmplitudeCore.RemoteConfigClient.Source, b: AmplitudeCore.RemoteConfigClient.Source) -> Swift.Bool
|
|
123
|
+
public func hash(into hasher: inout Swift.Hasher)
|
|
124
|
+
public var hashValue: Swift.Int {
|
|
125
|
+
get
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
public enum RemoteConfigError : Swift.Error {
|
|
129
|
+
case notInCache
|
|
130
|
+
case invalidServerURL
|
|
131
|
+
case badResponse
|
|
132
|
+
case preInit
|
|
133
|
+
case cancelled
|
|
134
|
+
public static func == (a: AmplitudeCore.RemoteConfigClient.RemoteConfigError, b: AmplitudeCore.RemoteConfigClient.RemoteConfigError) -> Swift.Bool
|
|
135
|
+
public func hash(into hasher: inout Swift.Hasher)
|
|
136
|
+
public var hashValue: Swift.Int {
|
|
137
|
+
get
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
public typealias RemoteConfig = [Swift.String : any Swift.Sendable]
|
|
141
|
+
public typealias RemoteConfigCallback = @Sendable (AmplitudeCore.RemoteConfigClient.RemoteConfig?, AmplitudeCore.RemoteConfigClient.Source, Foundation.Date?) -> Swift.Void
|
|
142
|
+
public typealias RemoteConfigSubscription = Swift.Sendable
|
|
143
|
+
public convenience init(apiKey: Swift.String, serverZone: AmplitudeCore.ServerZone, instanceName: Swift.String? = nil, logger: any AmplitudeCore.CoreLogger)
|
|
144
|
+
@discardableResult
|
|
145
|
+
nonisolated public func subscribe(key: Swift.String? = nil, deliveryMode: AmplitudeCore.RemoteConfigClient.DeliveryMode = .all, callback: @escaping AmplitudeCore.RemoteConfigClient.RemoteConfigCallback) -> any Swift.Sendable
|
|
146
|
+
nonisolated public func unsubscribe(_ token: any Swift.Sendable)
|
|
147
|
+
nonisolated public func updateConfigs()
|
|
148
|
+
@objc deinit
|
|
149
|
+
@available(iOS 13.0, tvOS 13.0, watchOS 6.0, macOS 10.15, *)
|
|
150
|
+
@_semantics("defaultActor") nonisolated final public var unownedExecutor: _Concurrency.UnownedSerialExecutor {
|
|
151
|
+
get
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
@objc(AMPServerZone) public enum ServerZone : Swift.Int, Swift.Sendable {
|
|
155
|
+
case US
|
|
156
|
+
case EU
|
|
157
|
+
public typealias RawValue = Swift.String
|
|
158
|
+
public var rawValue: AmplitudeCore.ServerZone.RawValue {
|
|
159
|
+
get
|
|
160
|
+
}
|
|
161
|
+
public init?(rawValue: AmplitudeCore.ServerZone.RawValue)
|
|
162
|
+
}
|
|
163
|
+
extension AmplitudeCore.LogLevel : Swift.Hashable {}
|
|
164
|
+
extension AmplitudeCore.LogLevel : Swift.RawRepresentable {}
|
|
165
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
166
|
+
extension AmplitudeCore.RemoteConfigClient.Source : Swift.Equatable {}
|
|
167
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
168
|
+
extension AmplitudeCore.RemoteConfigClient.Source : Swift.Hashable {}
|
|
169
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
170
|
+
extension AmplitudeCore.RemoteConfigClient.RemoteConfigError : Swift.Equatable {}
|
|
171
|
+
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
|
|
172
|
+
extension AmplitudeCore.RemoteConfigClient.RemoteConfigError : Swift.Hashable {}
|
|
173
|
+
extension AmplitudeCore.ServerZone : Swift.Equatable {}
|
|
174
|
+
extension AmplitudeCore.ServerZone : Swift.Hashable {}
|
|
175
|
+
extension AmplitudeCore.ServerZone : Swift.RawRepresentable {}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
3
|
+
<plist version="1.0">
|
|
4
|
+
<dict>
|
|
5
|
+
<key>AvailableLibraries</key>
|
|
6
|
+
<array>
|
|
7
|
+
<dict>
|
|
8
|
+
<key>BinaryPath</key>
|
|
9
|
+
<string>CQuickJS.framework/CQuickJS</string>
|
|
10
|
+
<key>LibraryIdentifier</key>
|
|
11
|
+
<string>ios-arm64_x86_64-simulator</string>
|
|
12
|
+
<key>LibraryPath</key>
|
|
13
|
+
<string>CQuickJS.framework</string>
|
|
14
|
+
<key>SupportedArchitectures</key>
|
|
15
|
+
<array>
|
|
16
|
+
<string>arm64</string>
|
|
17
|
+
<string>x86_64</string>
|
|
18
|
+
</array>
|
|
19
|
+
<key>SupportedPlatform</key>
|
|
20
|
+
<string>ios</string>
|
|
21
|
+
<key>SupportedPlatformVariant</key>
|
|
22
|
+
<string>simulator</string>
|
|
23
|
+
</dict>
|
|
24
|
+
<dict>
|
|
25
|
+
<key>BinaryPath</key>
|
|
26
|
+
<string>CQuickJS.framework/CQuickJS</string>
|
|
27
|
+
<key>LibraryIdentifier</key>
|
|
28
|
+
<string>ios-arm64</string>
|
|
29
|
+
<key>LibraryPath</key>
|
|
30
|
+
<string>CQuickJS.framework</string>
|
|
31
|
+
<key>SupportedArchitectures</key>
|
|
32
|
+
<array>
|
|
33
|
+
<string>arm64</string>
|
|
34
|
+
</array>
|
|
35
|
+
<key>SupportedPlatform</key>
|
|
36
|
+
<string>ios</string>
|
|
37
|
+
</dict>
|
|
38
|
+
</array>
|
|
39
|
+
<key>CFBundlePackageType</key>
|
|
40
|
+
<string>XFWK</string>
|
|
41
|
+
<key>XCFrameworkFormatVersion</key>
|
|
42
|
+
<string>1.0</string>
|
|
43
|
+
</dict>
|
|
44
|
+
</plist>
|
package/ios/Frameworks/CQuickJS.xcframework/ios-arm64/CQuickJS.framework/Headers/quickjs-libc.h
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* QuickJS C library
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) 2017-2018 Fabrice Bellard
|
|
5
|
+
*
|
|
6
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
8
|
+
* in the Software without restriction, including without limitation the rights
|
|
9
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
11
|
+
* furnished to do so, subject to the following conditions:
|
|
12
|
+
*
|
|
13
|
+
* The above copyright notice and this permission notice shall be included in
|
|
14
|
+
* all copies or substantial portions of the Software.
|
|
15
|
+
*
|
|
16
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
19
|
+
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
22
|
+
* THE SOFTWARE.
|
|
23
|
+
*/
|
|
24
|
+
#ifndef QUICKJS_LIBC_H
|
|
25
|
+
#define QUICKJS_LIBC_H
|
|
26
|
+
|
|
27
|
+
#include <stdio.h>
|
|
28
|
+
#include <stdlib.h>
|
|
29
|
+
|
|
30
|
+
#include "quickjs.h"
|
|
31
|
+
|
|
32
|
+
#ifdef __cplusplus
|
|
33
|
+
extern "C" {
|
|
34
|
+
#endif
|
|
35
|
+
|
|
36
|
+
JSModuleDef *js_init_module_std(JSContext *ctx, const char *module_name);
|
|
37
|
+
JSModuleDef *js_init_module_os(JSContext *ctx, const char *module_name);
|
|
38
|
+
void js_std_add_helpers(JSContext *ctx, int argc, char **argv);
|
|
39
|
+
void js_std_loop(JSContext *ctx);
|
|
40
|
+
JSValue js_std_await(JSContext *ctx, JSValue obj);
|
|
41
|
+
void js_std_init_handlers(JSRuntime *rt);
|
|
42
|
+
void js_std_free_handlers(JSRuntime *rt);
|
|
43
|
+
void js_std_dump_error(JSContext *ctx);
|
|
44
|
+
uint8_t *js_load_file(JSContext *ctx, size_t *pbuf_len, const char *filename);
|
|
45
|
+
int js_module_set_import_meta(JSContext *ctx, JSValueConst func_val,
|
|
46
|
+
JS_BOOL use_realpath, JS_BOOL is_main);
|
|
47
|
+
int js_module_test_json(JSContext *ctx, JSValueConst attributes);
|
|
48
|
+
int js_module_check_attributes(JSContext *ctx, void *opaque, JSValueConst attributes);
|
|
49
|
+
JSModuleDef *js_module_loader(JSContext *ctx,
|
|
50
|
+
const char *module_name, void *opaque,
|
|
51
|
+
JSValueConst attributes);
|
|
52
|
+
void js_std_eval_binary(JSContext *ctx, const uint8_t *buf, size_t buf_len,
|
|
53
|
+
int flags);
|
|
54
|
+
void js_std_eval_binary_json_module(JSContext *ctx,
|
|
55
|
+
const uint8_t *buf, size_t buf_len,
|
|
56
|
+
const char *module_name);
|
|
57
|
+
void js_std_promise_rejection_tracker(JSContext *ctx, JSValueConst promise,
|
|
58
|
+
JSValueConst reason,
|
|
59
|
+
JS_BOOL is_handled, void *opaque);
|
|
60
|
+
void js_std_set_worker_new_context_func(JSContext *(*func)(JSRuntime *rt));
|
|
61
|
+
|
|
62
|
+
#ifdef __cplusplus
|
|
63
|
+
} /* extern "C" { */
|
|
64
|
+
#endif
|
|
65
|
+
|
|
66
|
+
#endif /* QUICKJS_LIBC_H */
|