AtsConstants Methods
Class Methods 14 members
Constants for ATS (Aspire Type System) type IDs and capability IDs.
Creates an array type ID for the given element type.
public static class AtsConstants{ public static string ArrayTypeId( string elementType) { // ... }}Parameters
elementType string The element type ID. Returns
string The array type ID. Creates a Dict type ID for the given key and value types.
public static class AtsConstants{ public static string DictTypeId( string keyType, string valueType) { // ... }}Parameters
keyType string The key type ID. valueType string The value type ID. Returns
string The Dict type ID. Creates an enum type ID for the given enum type full name.
public static class AtsConstants{ public static string EnumTypeId( string enumFullName) { // ... }}Parameters
enumFullName string The full name of the enum type. Returns
string The enum type ID. Gets the type category for a type ID. Note: This method cannot distinguish DTOs from Handles based on type ID alone. Use the scanner's type mapping to determine if a handle type is actually a DTO.
public static class AtsConstants{ public static AtsTypeCategory GetCategory( string? typeId, bool isCallback = false) { // ... }}Parameters
typeId string? The ATS type ID. isCallback bool optional True if this is a callback parameter. Returns
AtsTypeCategory The type category. Gets the type category for a CLR type.
public static class AtsConstants{ public static AtsTypeCategory GetCategory( Type type) { // ... }}Parameters
type Type The CLR type. Returns
AtsTypeCategory The type category. Checks if a type ID represents an array type.
public static class AtsConstants{ public static bool IsArray( string? typeId) { // ... }}Parameters
typeId string? The ATS type ID to check. Returns
bool True if the type is an array. Checks if a type ID represents a Dict type.
public static class AtsConstants{ public static bool IsDict( string? typeId) { // ... }}Parameters
typeId string? The ATS type ID to check. Returns
bool True if the type is a Dict. Checks if a type ID represents an enum type.
public static class AtsConstants{ public static bool IsEnum( string? typeId) { // ... }}Parameters
typeId string? The ATS type ID to check. Returns
bool True if the type is an enum. Checks if a type ID represents a handle type (has Assembly/Type format).
public static class AtsConstants{ public static bool IsHandle( string? typeId) { // ... }}Parameters
typeId string? The ATS type ID to check. Returns
bool True if the type is a handle. Checks if a type ID represents a List type.
public static class AtsConstants{ public static bool IsList( string? typeId) { // ... }}Parameters
typeId string? The ATS type ID to check. Returns
bool True if the type is a List. Checks if a type ID represents a primitive type.
public static class AtsConstants{ public static bool IsPrimitive( string? typeId) { // ... }}Parameters
typeId string? The ATS type ID to check. Returns
bool True if the type is a primitive. Checks if a CLR type is a primitive ATS type.
public static class AtsConstants{ public static bool IsPrimitiveType( Type type) { // ... }}Parameters
type Type The CLR type to check. Returns
bool True if the type is a primitive. Checks if a dictionary type is readonly.
public static class AtsConstants{ public static bool IsReadOnlyDictType( Type type) { // ... }}Parameters
type Type Creates a List type ID for the given element type.
public static class AtsConstants{ public static string ListTypeId( string elementType) { // ... }}Parameters
elementType string The element type ID. Returns
string The List type ID.