Share via


Xamarin.TVOS SDK API diff: 12.1.0 vs 12.2.1

mscorlib.dll

Namespace System

Type Changed: System.String

Added methods:

public bool Contains (char value);
public bool Contains (char value, StringComparison comparisonType);
public bool Contains (string value, StringComparison comparisonType);
public bool EndsWith (char value);
public int GetHashCode (StringComparison comparisonType);
public int IndexOf (char value, StringComparison comparisonType);
public static string Join<T> (char separator, System.Collections.Generic.IEnumerable<T> values);
public static string Join (char separator, object[] values);
public static string Join (char separator, string[] value);
public static string Join (char separator, string[] value, int startIndex, int count);
public string Replace (string oldValue, string newValue, StringComparison comparisonType);
public string Replace (string oldValue, string newValue, bool ignoreCase, Globalization.CultureInfo culture);
public string[] Split (char separator, StringSplitOptions options);
public string[] Split (string separator, StringSplitOptions options);
public string[] Split (char separator, int count, StringSplitOptions options);
public string[] Split (string separator, int count, StringSplitOptions options);
public bool StartsWith (char value);
public string Trim (char trimChar);
public string TrimEnd ();
public string TrimEnd (char trimChar);
public string TrimStart ();
public string TrimStart (char trimChar);

Type Changed: System.StringComparer

Added method:

public static StringComparer FromComparison (StringComparison comparisonType);

Namespace System.Buffers

Removed Type System.Buffers.IRetainable

Removed Type System.Buffers.MemoryHandle

Namespace System.Collections

Type Changed: System.Collections.BitArray

Added methods:

public BitArray LeftShift (int count);
public BitArray RightShift (int count);

Namespace System.Collections.ObjectModel

Type Changed: System.Collections.ObjectModel.KeyedCollection`2

Added method:

public bool TryGetValue (TKey key, out TItem item);

Namespace System.Globalization

New Type: System.Globalization.GlobalizationExtensions

public static class GlobalizationExtensions {
	// methods
	public static System.StringComparer GetStringComparer (this CompareInfo compareInfo, CompareOptions options);
}

Namespace System.Reflection

Type Changed: System.Reflection.BindingFlags

Added value:

DoNotWrapExceptions = 33554432,

Namespace System.Reflection.Emit

New Type: System.Reflection.Emit.DynamicMethod

public abstract class DynamicMethod : System.Reflection.MethodInfo, System.Reflection.ICustomAttributeProvider, System.Runtime.InteropServices._MemberInfo, System.Runtime.InteropServices._MethodBase {
	// constructors
	public DynamicMethod (string name, System.Type returnType, System.Type[] parameterTypes);
	public DynamicMethod (string name, System.Type returnType, System.Type[] parameterTypes, bool restrictedSkipVisibility);
	public DynamicMethod (string name, System.Type returnType, System.Type[] parameterTypes, System.Reflection.Module m);
	public DynamicMethod (string name, System.Type returnType, System.Type[] parameterTypes, System.Type owner);
	public DynamicMethod (string name, System.Type returnType, System.Type[] parameterTypes, System.Reflection.Module m, bool skipVisibility);
	public DynamicMethod (string name, System.Type returnType, System.Type[] parameterTypes, System.Type owner, bool skipVisibility);
	public DynamicMethod (string name, System.Reflection.MethodAttributes attributes, System.Reflection.CallingConventions callingConvention, System.Type returnType, System.Type[] parameterTypes, System.Reflection.Module m, bool skipVisibility);
	public DynamicMethod (string name, System.Reflection.MethodAttributes attributes, System.Reflection.CallingConventions callingConvention, System.Type returnType, System.Type[] parameterTypes, System.Type owner, bool skipVisibility);
	// properties
	public override System.Reflection.MethodAttributes Attributes { get; }
	public override System.Reflection.CallingConventions CallingConvention { get; }
	public override System.Type DeclaringType { get; }
	public bool InitLocals { get; set; }
	public override System.Reflection.MethodImplAttributes MethodImplementationFlags { get; }
	public override string Name { get; }
	public override System.Reflection.ParameterInfo ReturnParameter { get; }
	public override System.Type ReturnType { get; }
	// methods
	public ILGenerator GetILGenerator ();
	public ILGenerator GetILGenerator (int streamSize);
	public override System.Reflection.ParameterInfo[] GetParameters ();
}

Namespace System.Runtime

New Type: System.Runtime.ProfileOptimization

public static class ProfileOptimization {
	// methods
	public static void SetProfileRoot (string directoryPath);
	public static void StartProfile (string profile);
}

Namespace System.Runtime.CompilerServices

Type Changed: System.Runtime.CompilerServices.ConditionalWeakTable`2

Added interfaces:

System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TKey,TValue>>
System.Collections.IEnumerable

New Type: System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder

public struct AsyncValueTaskMethodBuilder {
	// properties
	public System.Threading.Tasks.ValueTask Task { get; }
	// methods
	public void AwaitOnCompleted<TAwaiter, TStateMachine> (ref TAwaiter awaiter, ref TStateMachine stateMachine);
	public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine> (ref TAwaiter awaiter, ref TStateMachine stateMachine);
	public static AsyncValueTaskMethodBuilder Create ();
	public void SetException (System.Exception exception);
	public void SetResult ();
	public void SetStateMachine (IAsyncStateMachine stateMachine);
	public void Start<TStateMachine> (ref TStateMachine stateMachine);
}

New Type: System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable

public struct ConfiguredValueTaskAwaitable {
	// methods
	public ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter GetAwaiter ();

	// inner types
	public struct ConfiguredValueTaskAwaiter, ICriticalNotifyCompletion, INotifyCompletion {
		// properties
		public bool IsCompleted { get; }
		// methods
		public void GetResult ();
		public virtual void OnCompleted (System.Action continuation);
		public virtual void UnsafeOnCompleted (System.Action continuation);
	}
}

New Type: System.Runtime.CompilerServices.ValueTaskAwaiter

public struct ValueTaskAwaiter, ICriticalNotifyCompletion, INotifyCompletion {
	// properties
	public bool IsCompleted { get; }
	// methods
	public void GetResult ();
	public virtual void OnCompleted (System.Action continuation);
	public virtual void UnsafeOnCompleted (System.Action continuation);
}

Namespace System.Threading

Type Changed: System.Threading.LazyInitializer

Added method:

public static T EnsureInitialized<T> (ref T target, ref object syncLock, System.Func<T> valueFactory);

New Type: System.Threading.Lock

public class Lock {
	// constructors
	public Lock ();
	// methods
	public void Acquire ();
	public void Release ();
}

New Type: System.Threading.LockHolder

public struct LockHolder, System.IDisposable {
	// methods
	public virtual void Dispose ();
	public static LockHolder Hold (Lock l);
}

Namespace System.Threading.Tasks

Type Changed: System.Threading.Tasks.Task

Added methods:

public static System.Threading.Tasks.Task<TResult> CreateUnwrapPromise<TResult> (Task outerTask, bool lookForOce);
public virtual void MarkAborted (System.Threading.ThreadAbortException e);

Type Changed: System.Threading.Tasks.ValueTask`1

Added constructor:

public ValueTask`1 (System.Threading.Tasks.Sources.IValueTaskSource<TResult> source, short token);

Removed method:

public static System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder<TResult> CreateAsyncMethodBuilder ();

Added method:

public System.Threading.Tasks.ValueTask<TResult> Preserve ();

New Type: System.Threading.Tasks.ValueTask

public struct ValueTask, System.IEquatable<ValueTask> {
	// constructors
	public ValueTask (Task task);
	public ValueTask (Sources.IValueTaskSource source, short token);
	// properties
	public bool IsCanceled { get; }
	public bool IsCompleted { get; }
	public bool IsCompletedSuccessfully { get; }
	public bool IsFaulted { get; }
	// methods
	public Task AsTask ();
	public System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable ConfigureAwait (bool continueOnCapturedContext);
	public override bool Equals (object obj);
	public virtual bool Equals (ValueTask other);
	public System.Runtime.CompilerServices.ValueTaskAwaiter GetAwaiter ();
	public override int GetHashCode ();
	public ValueTask Preserve ();
	public static bool op_Equality (ValueTask left, ValueTask right);
	public static bool op_Inequality (ValueTask left, ValueTask right);
}

New Namespace System.Threading.Tasks.Sources

New Type: System.Threading.Tasks.Sources.IValueTaskSource

public interface IValueTaskSource {
	// methods
	public virtual void GetResult (short token);
	public virtual ValueTaskSourceStatus GetStatus (short token);
	public virtual void OnCompleted (System.Action<object> continuation, object state, short token, ValueTaskSourceOnCompletedFlags flags);
}

New Type: System.Threading.Tasks.Sources.IValueTaskSource`1

public interface IValueTaskSource`1 {
	// methods
	public virtual TResult GetResult (short token);
	public virtual ValueTaskSourceStatus GetStatus (short token);
	public virtual void OnCompleted (System.Action<object> continuation, object state, short token, ValueTaskSourceOnCompletedFlags flags);
}

New Type: System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags

[Serializable]
[Flags]
public enum ValueTaskSourceOnCompletedFlags {
	FlowExecutionContext = 2,
	None = 0,
	UseSchedulingContext = 1,
}

New Type: System.Threading.Tasks.Sources.ValueTaskSourceStatus

[Serializable]
public enum ValueTaskSourceStatus {
	Canceled = 3,
	Faulted = 2,
	Pending = 0,
	Succeeded = 1,
}

System.Core.dll

Namespace System.Security.Cryptography

New Type: System.Security.Cryptography.IncrementalHash

public sealed class IncrementalHash : System.IDisposable {
	// properties
	public HashAlgorithmName AlgorithmName { get; }
	// methods
	public void AppendData (byte[] data);
	public void AppendData (byte[] data, int offset, int count);
	public static IncrementalHash CreateHMAC (HashAlgorithmName hashAlgorithm, byte[] key);
	public static IncrementalHash CreateHash (HashAlgorithmName hashAlgorithm);
	public virtual void Dispose ();
	public byte[] GetHashAndReset ();
}

System.dll

Namespace System

New Type: System.StringNormalizationExtensions

public static class StringNormalizationExtensions {
	// methods
	public static bool IsNormalized (this string strInput);
	public static bool IsNormalized (this string strInput, Text.NormalizationForm normalizationForm);
	public static string Normalize (this string strInput);
	public static string Normalize (this string strInput, Text.NormalizationForm normalizationForm);
}

Namespace System.Diagnostics

New Type: System.Diagnostics.StackFrameExtensions

public static class StackFrameExtensions {
	// methods
	public static IntPtr GetNativeIP (this StackFrame stackFrame);
	public static IntPtr GetNativeImageBase (this StackFrame stackFrame);
	public static bool HasILOffset (this StackFrame stackFrame);
	public static bool HasMethod (this StackFrame stackFrame);
	public static bool HasNativeImage (this StackFrame stackFrame);
	public static bool HasSource (this StackFrame stackFrame);
}

Namespace System.Net

Type Changed: System.Net.FtpWebRequest

Added properties:

public override Cache.RequestCachePolicy CachePolicy { get; set; }
public static Cache.RequestCachePolicy DefaultCachePolicy { get; set; }

Namespace System.Text.RegularExpressions

Type Changed: System.Text.RegularExpressions.CaptureCollection

Added interfaces:

System.Collections.Generic.ICollection<Capture>
System.Collections.Generic.IEnumerable<Capture>
System.Collections.Generic.IList<Capture>
System.Collections.Generic.IReadOnlyCollection<Capture>
System.Collections.Generic.IReadOnlyList<Capture>
System.Collections.IList

Added method:

public virtual void CopyTo (Capture[] array, int arrayIndex);

Type Changed: System.Text.RegularExpressions.GroupCollection

Added interfaces:

System.Collections.Generic.ICollection<Group>
System.Collections.Generic.IEnumerable<Group>
System.Collections.Generic.IList<Group>
System.Collections.Generic.IReadOnlyCollection<Group>
System.Collections.Generic.IReadOnlyList<Group>
System.Collections.IList

Added method:

public virtual void CopyTo (Group[] array, int arrayIndex);

Type Changed: System.Text.RegularExpressions.MatchCollection

Added interfaces:

System.Collections.Generic.ICollection<Match>
System.Collections.Generic.IEnumerable<Match>
System.Collections.Generic.IList<Match>
System.Collections.Generic.IReadOnlyCollection<Match>
System.Collections.Generic.IReadOnlyList<Match>
System.Collections.IList

Added method:

public virtual void CopyTo (Match[] array, int arrayIndex);

Type Changed: System.Text.RegularExpressions.Regex

Modified fields:

 ---[NonSerialized]
 ---public readonly System.TimeSpan InfiniteMatchTimeout;

Modified methods:

-protected bool UseOptionR ()
+protected bool UseOptionR ()

New Namespace System.Security

New Type: System.Security.SecureStringMarshal

public static class SecureStringMarshal {
	// methods
	public static IntPtr SecureStringToCoTaskMemAnsi (SecureString s);
	public static IntPtr SecureStringToCoTaskMemUnicode (SecureString s);
	public static IntPtr SecureStringToGlobalAllocAnsi (SecureString s);
	public static IntPtr SecureStringToGlobalAllocUnicode (SecureString s);
}

System.Runtime.Serialization.dll

Namespace System.Runtime.Serialization

New Type: System.Runtime.Serialization.DataContractSerializerExtensions

public static class DataContractSerializerExtensions {
	// methods
	public static ISerializationSurrogateProvider GetSerializationSurrogateProvider (this DataContractSerializer serializer);
	public static void SetSerializationSurrogateProvider (this DataContractSerializer serializer, ISerializationSurrogateProvider provider);
}

New Type: System.Runtime.Serialization.ISerializationSurrogateProvider

public interface ISerializationSurrogateProvider {
	// methods
	public virtual object GetDeserializedObject (object obj, System.Type targetType);
	public virtual object GetObjectToSerialize (object obj, System.Type targetType);
	public virtual System.Type GetSurrogateType (System.Type type);
}

System.Xml.Linq.dll

Namespace System.Xml.XPath

New Type: System.Xml.XPath.XDocumentExtensions

public static class XDocumentExtensions {
	// methods
	public static IXPathNavigable ToXPathNavigable (this System.Xml.Linq.XNode node);
}

Xamarin.TVOS.dll

Namespace Foundation

Type Changed: Foundation.NSErrorException

Added property:

public override string Message { get; }

Namespace ObjCRuntime

Type Changed: ObjCRuntime.Constants

Modified fields:

-public const string Version = "12.1.0";
+public const string Version = "12.2.1";

Type Changed: ObjCRuntime.Runtime

Added method:

public static void ReleaseBlockOnMainThread (IntPtr block);