Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ ConvertTo() [1/2]

override? object System.ComponentModel.GuidConverter.ConvertTo ( ITypeDescriptorContext? context,
CultureInfo? culture,
object? value,
Type destinationType )
inlinevirtual

Reimplemented from System.ComponentModel.TypeConverter.

Definition at line 36 of file GuidConverter.cs.

37 {
38 if (destinationType == typeof(InstanceDescriptor) && value is Guid)
39 {
40 ConstructorInfo constructor = typeof(Guid).GetConstructor(new Type[1] { typeof(string) });
41 return new InstanceDescriptor(constructor, new object[1] { value.ToString() });
42 }
43 return base.ConvertTo(context, culture, value, destinationType);
44 }

References System.culture, and System.value.