swift-uwp/Sources/UWP/Generated/Windows.Media+Impl.swift
2024-02-15 17:14:48 -08:00

79 lines
3.5 KiB
Swift

// WARNING: Please don't edit this file. It was generated by Swift/WinRT v0.0.1
// swiftlint:disable all
import Foundation
@_spi(WinRTInternal) @_spi(WinRTImplements) import WindowsFoundation
import CWinRT
public enum __IMPL_Windows_Media {
public enum IMediaFrameBridge : AbiInterfaceBridge {
public typealias CABI = __x_ABI_CWindows_CMedia_CIMediaFrame
public typealias SwiftABI = __ABI_Windows_Media.IMediaFrame
public typealias SwiftProjection = AnyIMediaFrame
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
guard let abi = abi else { return nil }
return IMediaFrameImpl(abi)
}
public static func makeAbi() -> CABI {
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Windows_Media.IMediaFrameVTable) { $0 }
return .init(lpVtbl: vtblPtr)
}
}
fileprivate class IMediaFrameImpl: IMediaFrame, WinRTAbiImpl {
fileprivate typealias Bridge = IMediaFrameBridge
fileprivate let _default: Bridge.SwiftABI
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
_default = Bridge.SwiftABI(fromAbi)
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.duration)
fileprivate var duration : WindowsFoundation.TimeSpan? {
get { try! _default.get_DurationImpl() }
set { try! _default.put_DurationImpl(newValue) }
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.extendedproperties)
fileprivate var extendedProperties : WindowsFoundation.AnyIPropertySet! {
get { try! _default.get_ExtendedPropertiesImpl() }
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.isdiscontinuous)
fileprivate var isDiscontinuous : Bool {
get { try! _default.get_IsDiscontinuousImpl() }
set { try! _default.put_IsDiscontinuousImpl(newValue) }
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.isreadonly)
fileprivate var isReadOnly : Bool {
get { try! _default.get_IsReadOnlyImpl() }
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.relativetime)
fileprivate var relativeTime : WindowsFoundation.TimeSpan? {
get { try! _default.get_RelativeTimeImpl() }
set { try! _default.put_RelativeTimeImpl(newValue) }
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.systemrelativetime)
fileprivate var systemRelativeTime : WindowsFoundation.TimeSpan? {
get { try! _default.get_SystemRelativeTimeImpl() }
set { try! _default.put_SystemRelativeTimeImpl(newValue) }
}
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.type)
fileprivate var type : String {
get { try! _default.get_TypeImpl() }
}
private lazy var _IClosable: __ABI_Windows_Foundation.IClosable! = getInterfaceForCaching()
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.close)
fileprivate func close() throws {
try _IClosable.CloseImpl()
}
}
}