# AirPlayFactory Class

    public class AirPlayFactory : CastComponentFactoryProtocol

Create AirPlay client instance

- `engine`

  #### Declaration

  Swift

      public var engine: CastEngine

### Public

- `create(for:_:)`

  #### Declaration

  Swift

      public func create(
          for session: Session,
          _ castSettings: CastSettings)
          -> CastComponentProtocol?

- `create(for:on:)`

  #### Declaration

  Swift

      public func create(
          for session: Session,
          on player: any PlayerAPI
      ) -> (any CastComponentProtocol)?

- `shouldAttachOnlyToNativePlayer()`

  #### Declaration

  Swift

      public func shouldAttachOnlyToNativePlayer() -> Bool

- `canAttach(to:)`

  #### Declaration

  Swift

      public func canAttach(to session: Session) -> Bool

- `isSupported(_:)`

  #### Declaration

  Swift

      public func isSupported(_ settings: CastSettings) -> Bool