@tsonic/dotnet-types
Version:
TypeScript declarations and metadata for .NET 10.0 assemblies
167 lines (154 loc) • 11.2 kB
TypeScript
// Auto-generated by generatedts on 2025-11-02T09:57:25Z - do not edit by hand.
type int = number & { __brand: "int" };
type uint = number & { __brand: "uint" };
type byte = number & { __brand: "byte" };
type sbyte = number & { __brand: "sbyte" };
type short = number & { __brand: "short" };
type ushort = number & { __brand: "ushort" };
type long = number & { __brand: "long" };
type ulong = number & { __brand: "ulong" };
type float = number & { __brand: "float" };
type double = number & { __brand: "double" };
type decimal = number & { __brand: "decimal" };
declare namespace System.Collections.Concurrent {
class AlternateLookup<TKey, TValue, TAlternateKey> {
readonly Dictionary: System.Collections.Concurrent.ConcurrentDictionary<TKey, TValue>;
Item: TValue;
ContainsKey(key: TAlternateKey): boolean;
TryAdd(key: TAlternateKey, value: TValue): boolean;
TryGetValue(key: TAlternateKey, value: TValue): boolean;
TryGetValue(key: TAlternateKey, actualKey: TKey, value: TValue): boolean;
TryRemove(key: TAlternateKey, value: TValue): boolean;
TryRemove(key: TAlternateKey, actualKey: TKey, value: TValue): boolean;
}
class BlockingCollection<T> implements ReadonlyArray<T>, System.Collections.IEnumerable, System.Collections.ICollection, System.IDisposable, ReadonlyArray<T> {
constructor();
constructor(boundedCapacity: int);
constructor(collection: System.Collections.Concurrent.IProducerConsumerCollection<T>, boundedCapacity: int);
constructor(collection: System.Collections.Concurrent.IProducerConsumerCollection<T>);
readonly BoundedCapacity: int;
readonly IsAddingCompleted: boolean;
readonly IsCompleted: boolean;
readonly Count: int;
Add(item: T): void;
Add(item: T, cancellationToken: System.Threading.CancellationToken): void;
TryAdd(item: T): boolean;
TryAdd(item: T, timeout: System.TimeSpan): boolean;
TryAdd(item: T, millisecondsTimeout: int): boolean;
TryAdd(item: T, millisecondsTimeout: int, cancellationToken: System.Threading.CancellationToken): boolean;
Take(): T;
Take(cancellationToken: System.Threading.CancellationToken): T;
TryTake(item: T): boolean;
TryTake(item: T, timeout: System.TimeSpan): boolean;
TryTake(item: T, millisecondsTimeout: int): boolean;
TryTake(item: T, millisecondsTimeout: int, cancellationToken: System.Threading.CancellationToken): boolean;
static AddToAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T): int;
static AddToAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, cancellationToken: System.Threading.CancellationToken): int;
static TryAddToAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T): int;
static TryAddToAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, timeout: System.TimeSpan): int;
static TryAddToAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, millisecondsTimeout: int): int;
static TryAddToAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, millisecondsTimeout: int, cancellationToken: System.Threading.CancellationToken): int;
static TakeFromAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T): int;
static TakeFromAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, cancellationToken: System.Threading.CancellationToken): int;
static TryTakeFromAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T): int;
static TryTakeFromAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, timeout: System.TimeSpan): int;
static TryTakeFromAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, millisecondsTimeout: int): int;
static TryTakeFromAny(collections: ReadonlyArray<System.Collections.Concurrent.BlockingCollection<>>, item: T, millisecondsTimeout: int, cancellationToken: System.Threading.CancellationToken): int;
CompleteAdding(): void;
Dispose(): void;
ToArray(): ReadonlyArray<T>;
CopyTo(array: ReadonlyArray<T>, index: int): void;
GetConsumingEnumerable(): ReadonlyArray<T>;
GetConsumingEnumerable(cancellationToken: System.Threading.CancellationToken): ReadonlyArray<T>;
}
class ConcurrentBag<T> implements System.Collections.Concurrent.IProducerConsumerCollection<T>, ReadonlyArray<T>, System.Collections.IEnumerable, System.Collections.ICollection, ReadonlyArray<T> {
constructor();
constructor(collection: ReadonlyArray<T>);
readonly Count: int;
readonly IsEmpty: boolean;
Add(item: T): void;
TryTake(result: T): boolean;
TryPeek(result: T): boolean;
CopyTo(array: ReadonlyArray<T>, index: int): void;
ToArray(): ReadonlyArray<T>;
Clear(): void;
GetEnumerator(): System.Collections.Generic.IEnumerator<T>;
}
class ConcurrentDictionary<TKey, TValue> implements System.Collections.Generic.IDictionary<TKey, TValue>, System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey, TValue>>, ReadonlyArray<System.Collections.Generic.KeyValuePair<TKey, TValue>>, System.Collections.IEnumerable, System.Collections.IDictionary, System.Collections.ICollection, System.Collections.Generic.IReadOnlyDictionary<TKey, TValue>, ReadonlyArray<System.Collections.Generic.KeyValuePair<TKey, TValue>> {
constructor();
constructor(concurrencyLevel: int, capacity: int);
constructor(collection: ReadonlyArray<System.Collections.Generic.KeyValuePair<TKey, TValue>>);
constructor(comparer: System.Collections.Generic.IEqualityComparer<TKey>);
constructor(collection: ReadonlyArray<System.Collections.Generic.KeyValuePair<TKey, TValue>>, comparer: System.Collections.Generic.IEqualityComparer<TKey>);
constructor(concurrencyLevel: int, collection: ReadonlyArray<System.Collections.Generic.KeyValuePair<TKey, TValue>>, comparer: System.Collections.Generic.IEqualityComparer<TKey>);
constructor(concurrencyLevel: int, capacity: int, comparer: System.Collections.Generic.IEqualityComparer<TKey>);
Item: TValue;
readonly Comparer: System.Collections.Generic.IEqualityComparer<TKey>;
readonly Count: int;
readonly IsEmpty: boolean;
readonly Keys: System.Collections.Generic.ICollection<TKey>;
readonly Values: System.Collections.Generic.ICollection<TValue>;
GetAlternateLookup<TAlternateKey>(): System.Collections.Concurrent.AlternateLookup<TKey, TValue, TAlternateKey>;
TryGetAlternateLookup<TAlternateKey>(lookup: System.Collections.Concurrent.AlternateLookup<TKey, TValue, TAlternateKey>): boolean;
TryAdd(key: TKey, value: TValue): boolean;
ContainsKey(key: TKey): boolean;
TryRemove(key: TKey, value: TValue): boolean;
TryRemove(item: System.Collections.Generic.KeyValuePair<TKey, TValue>): boolean;
TryGetValue(key: TKey, value: TValue): boolean;
TryUpdate(key: TKey, newValue: TValue, comparisonValue: TValue): boolean;
Clear(): void;
ToArray(): ReadonlyArray<System.Collections.Generic.KeyValuePair<TKey, TValue>>;
GetEnumerator(): System.Collections.Generic.IEnumerator<System.Collections.Generic.KeyValuePair<TKey, TValue>>;
GetOrAdd(key: TKey, valueFactory: System.Func<TKey, TValue>): TValue;
GetOrAdd<TArg>(key: TKey, valueFactory: System.Func<TKey, TArg, TValue>, factoryArgument: TArg): TValue;
GetOrAdd(key: TKey, value: TValue): TValue;
AddOrUpdate<TArg>(key: TKey, addValueFactory: System.Func<TKey, TArg, TValue>, updateValueFactory: System.Func<TKey, TValue, TArg, TValue>, factoryArgument: TArg): TValue;
AddOrUpdate(key: TKey, addValueFactory: System.Func<TKey, TValue>, updateValueFactory: System.Func<TKey, TValue, TValue>): TValue;
AddOrUpdate(key: TKey, addValue: TValue, updateValueFactory: System.Func<TKey, TValue, TValue>): TValue;
}
class ConcurrentStack<T> implements System.Collections.Concurrent.IProducerConsumerCollection<T>, ReadonlyArray<T>, System.Collections.IEnumerable, System.Collections.ICollection, ReadonlyArray<T> {
constructor();
constructor(collection: ReadonlyArray<T>);
readonly IsEmpty: boolean;
readonly Count: int;
Clear(): void;
CopyTo(array: ReadonlyArray<T>, index: int): void;
Push(item: T): void;
PushRange(items: ReadonlyArray<T>): void;
PushRange(items: ReadonlyArray<T>, startIndex: int, count: int): void;
TryPeek(result: T): boolean;
TryPop(result: T): boolean;
TryPopRange(items: ReadonlyArray<T>): int;
TryPopRange(items: ReadonlyArray<T>, startIndex: int, count: int): int;
ToArray(): ReadonlyArray<T>;
GetEnumerator(): System.Collections.Generic.IEnumerator<T>;
}
enum EnumerablePartitionerOptions {
None = 0,
NoBuffering = 1
}
class OrderablePartitioner<TSource> extends System.Collections.Concurrent.Partitioner<TSource> {
readonly KeysOrderedInEachPartition: boolean;
readonly KeysOrderedAcrossPartitions: boolean;
readonly KeysNormalized: boolean;
GetOrderablePartitions(partitionCount: int): System.Collections.Generic.IList<System.Collections.Generic.IEnumerator<System.Collections.Generic.KeyValuePair<long, TSource>>>;
GetOrderableDynamicPartitions(): ReadonlyArray<System.Collections.Generic.KeyValuePair<long, TSource>>;
GetPartitions(partitionCount: int): System.Collections.Generic.IList<System.Collections.Generic.IEnumerator<TSource>>;
GetDynamicPartitions(): ReadonlyArray<TSource>;
}
class Partitioner {
static Create<TSource>(list: System.Collections.Generic.IList<TSource>, loadBalance: boolean): System.Collections.Concurrent.OrderablePartitioner<TSource>;
static Create<TSource>(array: ReadonlyArray<TSource>, loadBalance: boolean): System.Collections.Concurrent.OrderablePartitioner<TSource>;
static Create<TSource>(source: ReadonlyArray<TSource>): System.Collections.Concurrent.OrderablePartitioner<TSource>;
static Create<TSource>(source: ReadonlyArray<TSource>, partitionerOptions: System.Collections.Concurrent.EnumerablePartitionerOptions): System.Collections.Concurrent.OrderablePartitioner<TSource>;
static Create(fromInclusive: long, toExclusive: long): System.Collections.Concurrent.OrderablePartitioner<System.Tuple<long, long>>;
static Create(fromInclusive: long, toExclusive: long, rangeSize: long): System.Collections.Concurrent.OrderablePartitioner<System.Tuple<long, long>>;
static Create(fromInclusive: int, toExclusive: int): System.Collections.Concurrent.OrderablePartitioner<System.Tuple<int, int>>;
static Create(fromInclusive: int, toExclusive: int, rangeSize: int): System.Collections.Concurrent.OrderablePartitioner<System.Tuple<int, int>>;
}
class Partitioner<TSource> {
readonly SupportsDynamicPartitions: boolean;
GetPartitions(partitionCount: int): System.Collections.Generic.IList<System.Collections.Generic.IEnumerator<TSource>>;
GetDynamicPartitions(): ReadonlyArray<TSource>;
}
}