APIClient
Swift
public struct APIClient: Sendable
A Steam API Client to be periodically polled
Topics
Configuration
enum PollKind
enum PollKind
init(SteamBaseAPI?, pollKind: PollKind, interval: TimeInterval, name: String)
init(SteamBaseAPI?, pollKind: PollKind, interval: TimeInterval, name: String)
Create a new client to be polled
Declaration
Swift
public init(
_ steam: SteamBaseAPI?, pollKind: PollKind = .runCallbacks,
interval: TimeInterval = 0.1, name: String = "APIClient")
Parameters
steam |
A |
pollKind |
What kind of polling to perform. Default is |
interval |
How often to make the polling call. More precisely, this time is left between calls to the polling function. No attempt is made to claw back lost time or account for time spent polling. |
name |
A name for this client, used for stats and debug. |
Properties
var steam: SteamBaseAPI?
var steam: SteamBaseAPI?
var pollKind: PollKind
var pollKind: PollKind
var interval: TimeInterval
var interval: TimeInterval
How frequently the API is polled
Declaration
Swift
public let interval: TimeInterval
var name: String
var name: String