Skip to content

Instantly share code, notes, and snippets.

@vs-mobiletools-engineering-service2
Created April 24, 2023 15:15
Show Gist options
  • Save vs-mobiletools-engineering-service2/e49baf11619d46379df86c48891da697 to your computer and use it in GitHub Desktop.
Save vs-mobiletools-engineering-service2/e49baf11619d46379df86c48891da697 to your computer and use it in GitHub Desktop.
stable-api-comparison/tvos-api-diff.md
title description author ms.author ms.date ms.topic ms.assetid ms.prod
Xamarin.TVOS SDK API diff: 16.1.1 vs 16.5.0
List of API changes between Xamarin.TVOS versions 16.1.1 and 16.5.0.
spouliot
sepoulio
4/24/2023
article
7defa1ed-b8c1-2f4b-1015-57a9e4196d3a
xamarin

Xamarin.TVOS SDK API diff: 16.1.1 vs 16.5.0

Namespace AVFoundation

Type Changed: AVFoundation.AVAssetWriter

Obsoleted properties:

 [Obsolete ("Use the 'Inputs' property instead.")]
 public virtual AVAssetWriterInput[] inputs { get; }

Added property:

public virtual AVAssetWriterInput[] Inputs { get; }

Type Changed: AVFoundation.AVAudioSession

Obsoleted properties:

 [Obsolete ("Use 'AVAudioSessionCategory' enum values instead.")]
 public static Foundation.NSString CategoryAmbient { get; }
 [Obsolete ("Use 'AVAudioSessionCategory' enum values instead.")]
 public static Foundation.NSString CategoryMultiRoute { get; }
 [Obsolete ("Use 'AVAudioSessionCategory' enum values instead.")]
 public static Foundation.NSString CategoryPlayAndRecord { get; }
 [Obsolete ("Use 'AVAudioSessionCategory' enum values instead.")]
 public static Foundation.NSString CategoryPlayback { get; }
 [Obsolete ("Use 'AVAudioSessionCategory' enum values instead.")]
 public static Foundation.NSString CategoryRecord { get; }
 [Obsolete ("Use 'AVAudioSessionCategory' enum values instead.")]
 public static Foundation.NSString CategorySoloAmbient { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeDefault { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeGameChat { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeMeasurement { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeMoviePlayback { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeSpokenAudio { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeVideoChat { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeVideoRecording { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString ModeVoiceChat { get; }
 [Obsolete ("Use 'AVAudioSessionMode' enum values instead.")]
 public static Foundation.NSString VoicePrompt { get; }

Added methods:

public Foundation.NSError SetActive (bool active, AVAudioSessionSetActiveOptions options);
public bool SetCategory (AVAudioSessionCategory category, AVAudioSessionCategoryOptions options, out Foundation.NSError outError);
public Foundation.NSError SetCategory (AVAudioSessionCategory category, AVAudioSessionMode mode, AVAudioSessionCategoryOptions options);
public Foundation.NSError SetCategory (AVAudioSessionCategory category, string mode, AVAudioSessionCategoryOptions options);
public bool SetCategory (AVAudioSessionCategory category, AVAudioSessionMode mode, AVAudioSessionCategoryOptions options, out Foundation.NSError outError);
public bool SetCategory (AVAudioSessionCategory category, string mode, AVAudioSessionCategoryOptions options, out Foundation.NSError outError);
public bool SetCategory (AVAudioSessionCategory category, AVAudioSessionMode mode, AVAudioSessionRouteSharingPolicy policy, AVAudioSessionCategoryOptions options, out Foundation.NSError outError);
public bool SetCategory (AVAudioSessionCategory category, string mode, AVAudioSessionRouteSharingPolicy policy, AVAudioSessionCategoryOptions options, out Foundation.NSError outError);
public bool SetMode (AVAudioSessionMode mode, out Foundation.NSError error);

Type Changed: AVFoundation.AVAudioSinkNode

Obsoleted constructors:

 [Obsolete ("Use the overload that takes a delegate that does not take a 'ref AudioBuffers' instead. Assigning a value to the 'inputData' parameter in the callback has no effect.")]
 public AVAudioSinkNode (AVAudioSinkNodeReceiverHandler receiverHandler);

Added constructors:

public AVAudioSinkNode (AVAudioSinkNodeReceiverHandler2 receiverHandler);
public AVAudioSinkNode (AVAudioSinkNodeReceiverHandlerRaw receiverHandler);

Type Changed: AVFoundation.AVMetadata

Obsoleted properties:

 [Obsolete ("Use 'AVMetadataFormat' enum values.")]
 public static Foundation.NSString FormatHlsMetadata { get; }
 [Obsolete ("Use 'AVMetadataFormat' enum values.")]
 public static Foundation.NSString FormatID3Metadata { get; }
 [Obsolete ("Use 'AVMetadataFormat' enum values.")]
 public static Foundation.NSString FormatQuickTimeUserData { get; }
 [Obsolete ("Use 'AVMetadataFormat' enum values.")]
 public static Foundation.NSString FormatiTunesMetadata { get; }
 [Obsolete ("Use 'AVMetadataFormat' enum values.")]
 public static Foundation.NSString KFormatISOUserData { get; }

Type Changed: AVFoundation.AVPlayer

Obsoleted properties:

 [Obsolete ("Use 'AVPlayerWaitingReason' enum instead.")]
 public static Foundation.NSString AVPlayerWaitingForCoordinatedPlaybackReason { get; }
 [Obsolete ("Use 'AVPlayerWaitingReason' enum instead.")]
 public static Foundation.NSString WaitingDuringInterstitialEventReason { get; }
 [Obsolete ("Use 'AVPlayerWaitingReason' enum instead.")]
 public static Foundation.NSString WaitingToMinimizeStallsReason { get; }
 [Obsolete ("Use 'AVPlayerWaitingReason' enum instead.")]
 public static Foundation.NSString WaitingWhileEvaluatingBufferingRateReason { get; }
 [Obsolete ("Use 'AVPlayerWaitingReason' enum instead.")]
 public static Foundation.NSString WaitingWithNoItemToPlayReason { get; }

New Type: AVFoundation.AVAudioSessionCategoryExtensions

public static class AVAudioSessionCategoryExtensions {
	// methods
	public static Foundation.NSString GetConstant (this AVAudioSessionCategory self);
	public static AVAudioSessionCategory GetValue (Foundation.NSString constant);
}

New Type: AVFoundation.AVAudioSessionMode

[Serializable]
public enum AVAudioSessionMode {
	Default = 0,
	GameChat = 4,
	Measurement = 3,
	MoviePlayback = 5,
	SpokenAudio = 7,
	VideoChat = 6,
	VideoRecording = 2,
	VoiceChat = 1,
	VoicePrompt = 8,
}

New Type: AVFoundation.AVAudioSessionModeExtensions

public static class AVAudioSessionModeExtensions {
	// methods
	public static Foundation.NSString GetConstant (this AVAudioSessionMode self);
	public static AVAudioSessionMode GetValue (Foundation.NSString constant);
}

New Type: AVFoundation.AVAudioSinkNodeReceiverHandler2

public sealed delegate AVAudioSinkNodeReceiverHandler2 : System.MulticastDelegate {
	// constructors
	public AVAudioSinkNodeReceiverHandler2 (object object, IntPtr method);
	// methods
	public virtual System.IAsyncResult BeginInvoke (AudioToolbox.AudioTimeStamp timestamp, uint frameCount, AudioToolbox.AudioBuffers inputData, System.AsyncCallback callback, object object);
	public virtual int EndInvoke (System.IAsyncResult result);
	public virtual int Invoke (AudioToolbox.AudioTimeStamp timestamp, uint frameCount, AudioToolbox.AudioBuffers inputData);
}

New Type: AVFoundation.AVAudioSinkNodeReceiverHandlerRaw

public sealed delegate AVAudioSinkNodeReceiverHandlerRaw : System.MulticastDelegate {
	// constructors
	public AVAudioSinkNodeReceiverHandlerRaw (object object, IntPtr method);
	// methods
	public virtual System.IAsyncResult BeginInvoke (IntPtr timestamp, uint frameCount, IntPtr inputData, System.AsyncCallback callback, object object);
	public virtual int EndInvoke (System.IAsyncResult result);
	public virtual int Invoke (IntPtr timestamp, uint frameCount, IntPtr inputData);
}

Namespace CoreAnimation

Type Changed: CoreAnimation.CAAnimation

Obsoleted properties:

 [Obsolete ("The name has been fixed, use 'AnimationDiscrete' instead.")]
 public static Foundation.NSString AnimationDescrete { get; }

Type Changed: CoreAnimation.CAGradientLayer

Obsoleted properties:

 [Obsolete ("Use 'CAGradientLayerType.Axial' enum instead.")]
 public static Foundation.NSString GradientLayerAxial { get; }

Type Changed: CoreAnimation.CAMetalLayer

Added property:

public virtual Foundation.NSDictionary DeveloperHudProperties { get; set; }

Namespace CoreBluetooth

Type Changed: CoreBluetooth.CBCentralManager

Obsoleted properties:

 [Obsolete ("Use 'CBConnectPeripheralOptions' instead.")]
 public static Foundation.NSString OptionNotifyOnConnectionKey { get; }
 [Obsolete ("Use 'CBConnectPeripheralOptions' instead.")]
 public static Foundation.NSString OptionNotifyOnDisconnectionKey { get; }
 [Obsolete ("Use 'CBConnectPeripheralOptions' instead.")]
 public static Foundation.NSString OptionNotifyOnNotificationKey { get; }

Namespace CoreFoundation

Type Changed: CoreFoundation.CFSocket

Added properties:

public System.Net.IPEndPoint Address { get; }
public System.Net.IPEndPoint RemoteAddress { get; }

Added method:

public void Invalidate ();

Namespace CoreGraphics

Type Changed: CoreGraphics.CGImagePropertiesGps

Added properties:

public string LatitudeRef { get; set; }
public string LongitudeRef { get; set; }

Namespace Foundation

Type Changed: Foundation.NSAttributedString

Obsoleted methods:

 [Obsolete ("Use 'GetData' instead.")]
 public NSData GetDataFromRange (NSRange range, NSAttributedStringDocumentAttributes documentAttributes, ref NSError error);
 [Obsolete ("Use 'GetData' instead.")]
 public virtual NSData GetDataFromRange (NSRange range, NSDictionary attributes, ref NSError error);
 [Obsolete ("Use 'GetFileWrapper' instead.")]
 public NSFileWrapper GetFileWrapperFromRange (NSRange range, NSAttributedStringDocumentAttributes documentAttributes, ref NSError error);
 [Obsolete ("Use 'GetFileWrapper' instead.")]
 public virtual NSFileWrapper GetFileWrapperFromRange (NSRange range, NSDictionary attributes, ref NSError error);

Added methods:

public NSData GetData (NSRange range, NSAttributedStringDocumentAttributes options, out NSError error);
public NSData GetData (NSRange range, NSDictionary options, out NSError error);
public NSFileWrapper GetFileWrapper (NSRange range, NSAttributedStringDocumentAttributes options, out NSError error);
public NSFileWrapper GetFileWrapper (NSRange range, NSDictionary options, out NSError error);

Type Changed: Foundation.NSBundle

Obsoleted properties:

 [Obsolete ("Use the 'AllBundles' property instead.")]
 public static NSBundle[] _AllBundles { get; }

Added property:

public static NSBundle[] AllBundles { get; }

Type Changed: Foundation.NSItemProvider

Added methods:

public NSProgress LoadObject<T> (System.Action<T,Foundation.NSError> completionHandler);
public System.Threading.Tasks.Task<T> LoadObjectAsync<T> ();
public System.Threading.Tasks.Task<T> LoadObjectAsync<T> (out NSProgress result);

Type Changed: Foundation.NSKeyValueObservingOptions

Added value:

None = 0,

Type Changed: Foundation.NSOperatingSystemVersion

Added constructors:

public NSOperatingSystemVersion (nint major);
public NSOperatingSystemVersion (nint major, nint minor);

Added interfaces:

System.IComparable
System.IEquatable<NSOperatingSystemVersion>

Added methods:

public int CompareTo (NSOperatingSystemVersion otherVersion);
public virtual int CompareTo (object obj);
public virtual bool Equals (NSOperatingSystemVersion other);
public override bool Equals (object obj);
public override int GetHashCode ();
public static bool op_Equality (NSOperatingSystemVersion os1, NSOperatingSystemVersion os2);
public static bool op_Inequality (NSOperatingSystemVersion os1, NSOperatingSystemVersion os2);

Type Changed: Foundation.NSRunLoop

Obsoleted properties:

 [Obsolete ("Use the 'NSRunLoopMode' enum instead.")]
 public static NSString NSDefaultRunLoopMode { get; }
 [Obsolete ("Use the 'NSRunLoopMode' enum instead.")]
 public static NSString NSRunLoopCommonModes { get; }
 [Obsolete ("Use the 'NSRunLoopMode' enum instead.")]
 public static NSString UITrackingRunLoopMode { get; }

Type Changed: Foundation.NSUrl

Added properties:

public static NSString FileIdentifierKey { get; }
public static NSString VolumeMountFromLocationKey { get; }
public static NSString VolumeSubtypeKey { get; }
public static NSString VolumeTypeNameKey { get; }

Type Changed: Foundation.NSValue

Added property:

public virtual CoreMedia.CMVideoDimensions CMVideoDimensionsValue { get; }

Added method:

public static NSValue FromCMVideoDimensions (CoreMedia.CMVideoDimensions value);

Namespace HomeKit

Type Changed: HomeKit.HMTimerTrigger

Added constructor:

public HMTimerTrigger (string name, Foundation.NSDate fireDate, Foundation.NSDateComponents recurrence);

Namespace ImageIO

Type Changed: ImageIO.CGImageProperties

Added property:

public static Foundation.NSString OpenExrCompression { get; }

Namespace JavaScriptCore

Type Changed: JavaScriptCore.JSContext

Added property:

public virtual bool Inspectable { get; set; }

Namespace MapKit

Type Changed: MapKit.MKOverlayRenderer

Added method:

public static nfloat MKRoadWidthAtZoomScale (nfloat zoomScale);

Type Changed: MapKit.MKOverlayView

Obsoleted methods:

 [Obsolete ("Use 'MKOverlayRenderer.MKRoadWidthAtZoomScale' instead.")]
 public static nfloat MKRoadWidthAtZoomScale (nfloat zoomScale);

Namespace MediaAccessibility

New Type: MediaAccessibility.MAVideoAccommodations

public static class MAVideoAccommodations {
	// properties
	public static Foundation.NSString DimFlashingLightsChangedNotification { get; }
	// methods
	public static bool IsDimFlashingLightsEnabled ();

	// inner types
	public static class Notifications {
		// methods
		public static Foundation.NSObject ObserveDimFlashingLightsChanged (System.EventHandler<Foundation.NSNotificationEventArgs> handler);
		public static Foundation.NSObject ObserveDimFlashingLightsChanged (Foundation.NSObject objectToObserve, System.EventHandler<Foundation.NSNotificationEventArgs> handler);
	}
}

Namespace Metal

Type Changed: Metal.IMTLRenderCommandEncoder_Extensions

Added methods:

public static void SetScissorRects (this IMTLRenderCommandEncoder This, MTLScissorRect[] scissorRects);
public static void SetTileBuffers (this IMTLRenderCommandEncoder This, IMTLBuffer[] buffers, nuint[] offsets, Foundation.NSRange range);
public static void SetTileSamplerStates (this IMTLRenderCommandEncoder This, IMTLSamplerState[] samplers, float[] lodMinClamps, float[] lodMaxClamps, Foundation.NSRange range);
public static void SetViewports (this IMTLRenderCommandEncoder This, MTLViewport[] viewports);

Namespace MetalKit

Type Changed: MetalKit.MTKTextureLoaderOptions

Modified properties:

-public bool? GenerateMipmaps { get; set; }
+public bool? GenerateMipmaps { get; }

Namespace Network

Type Changed: Network.NWDataTransferReport

Obsoleted methods:

 [Obsolete ("Use the 'GetPathRadioType' property instead.")]
 public NWInterfaceRadioType get_path_radio_type (uint pathIndex);

Added method:

public NWInterfaceRadioType GetPathRadioType (uint pathIndex);

Type Changed: Network.NWQuicStreamType

Added value:

Datagram = 3,

Namespace ObjCRuntime

Type Changed: ObjCRuntime.BlockLiteral

Added interface:

System.IDisposable

Added property:

public object Context { get; }

Added method:

public virtual void Dispose ();

Type Changed: ObjCRuntime.Constants

Modified fields:

-public const string SdkVersion = "16.1";
+public const string SdkVersion = "16.4";
-public const string Version = "16.1.1";
+public const string Version = "16.5.0";

Namespace Photos

Type Changed: Photos.PHFetchResult

Obsoleted properties:

 [Obsolete ("Use the 'FirstObject' property instead.")]
 public virtual Foundation.NSObject firstObject { get; }

Added property:

public virtual Foundation.NSObject FirstObject { get; }

Namespace SceneKit

Type Changed: SceneKit.SCNHitTest

Obsoleted properties:

 [Obsolete ("Use 'SearchModeKey' instead.")]
 public static Foundation.NSString OptionSearchModeKey { get; }

Namespace StoreKit

Type Changed: StoreKit.StoreProductParameters

Modified properties:

-public string AdNetworkSourceAppStoreIdentifier { get; set; }
+public string AdNetworkSourceAppStoreIdentifier { get; }
-public string AdNetworkVersion { get; set; }
+public string AdNetworkVersion { get; }
-public string ProductIdentifier { get; set; }
+public string ProductIdentifier { get; }
-public string ProviderToken { get; set; }
+public string ProviderToken { get; }

Namespace System.Net.Http

Type Changed: System.Net.Http.NSUrlSessionHandler

Obsoleted properties:

 [Obsolete ("This property will be ignored in .NET 8.")]
 public bool BypassBackgroundSessionCheck { get; set; }

Namespace UIKit

Type Changed: UIKit.NSTextList

Added constructors:

public NSTextList (string format);
public NSTextList (NSTextListMarkerFormats format);

Obsoleted properties:

 [Obsolete ("Use 'CustomMarkerFormat' instead.")]
 public virtual string MarkerFormat { get; }

Added property:

public string CustomMarkerFormat { get; }

Type Changed: UIKit.NSTextListMarkerFormats

Added value:

CustomString = -1,

Type Changed: UIKit.NSTextListOptions

Added value:

None = 0,

Type Changed: UIKit.UIButtonConfiguration

Added properties:

public virtual UILineBreakMode SubtitleLineBreakMode { get; set; }
public virtual UILineBreakMode TitleLineBreakMode { get; set; }

Type Changed: UIKit.UIConfigurationColorTransformer

Obsoleted properties:

 [Obsolete ("Use the 'MonochromeTint' property instead.")]
 public static IntPtr _MonochromeTint { get; }
 [Obsolete ("Use the 'PreferredTint' property instead.")]
 public static IntPtr _PreferredTint { get; }

Type Changed: UIKit.UIFont

Obsoleted properties:

 [Obsolete ("Use the 'XHeight' property instead.")]
 public virtual nfloat xHeight { get; }

Added property:

public virtual nfloat XHeight { get; }

Type Changed: UIKit.UISearchBar

Added property:

public virtual bool Enabled { get; set; }

New Type: UIKit.UIFontWeightConstants

public static class UIFontWeightConstants {
	// properties
	public static nfloat Black { get; }
	public static nfloat Bold { get; }
	public static nfloat Heavy { get; }
	public static nfloat Light { get; }
	public static nfloat Medium { get; }
	public static nfloat Regular { get; }
	public static nfloat Semibold { get; }
	public static nfloat Thin { get; }
	public static nfloat UltraLight { get; }
}

New Type: UIKit.UIFontWeightExtensions

public static class UIFontWeightExtensions {
	// methods
	public static nfloat GetWeight (this UIFontWeight weight);
}

Namespace VideoSubscriberAccount

Type Changed: VideoSubscriberAccount.VSUserAccount

Added property:

public virtual bool SignedOut { get; set; }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment