CardTerminals

public class CardTerminals : BaseClass

SmartCardIO - CardTerminals Class

The set of terminals supported by a TerminalFactory. This class allows applications to enumerate the available CardTerminals, obtain a specific CardTerminal, or wait for the insertion or removal of cards.

  • Terminal Card States used for filtering the terminal list from the “list” function call

    See more

    Declaration

    Swift

    public enum State
  • Returns the terminal with the specified name or nil if no such terminal exists.

    Declaration

    Swift

    public func getTerminal(name: String) -> CardTerminal?

    Parameters

    name

    Name of the terminal to return

    Return Value

    Terminal with the specified name or nil if no such terminal exists.

  • Returns an unmodifiable list of all available terminals.

    Declaration

    Swift

    public func list() -> [CardTerminal]

    Return Value

    An unmodifiable list of all available terminals.

  • Returns an unmodifiable list of all terminals matching the specified state.

    Declaration

    Swift

    public func list(state: State) -> [CardTerminal]

    Parameters

    state

    State to match (see enum State for options)

    Return Value

    An unmodifiable list of all terminals matching the specified state.

  • Waits indefinitely for card insertion or removal in any of the terminals of this object.

    Declaration

    Swift

    public func waitForChange()
  • Waits for card insertion or removal in any of the terminals of this object or until the timeout expires.

    Declaration

    Swift

    public func waitForChange(timeout: Int) -> Bool

    Parameters

    timeout

    timeout in milliseconds

    Return Value

    True if a card change was detected, else false if timed out