Class ServerAddressTypeConverter
- Namespace
- IceRpc
- Assembly
- IceRpc.dll
The server address type converter specifies how to convert a string to a serverAddress. It's used by sub-systems such as the Microsoft ConfigurationBinder to bind string values to ServerAddress properties.
public class ServerAddressTypeConverter : TypeConverter
- Inheritance
-
ServerAddressTypeConverter
- Inherited Members
Methods
CanConvertFrom(ITypeDescriptorContext?, Type)
Returns whether this converter can convert an object of the given type into a ServerAddress value, using the specified context.
public override bool CanConvertFrom(ITypeDescriptorContext? context, Type sourceType)
Parameters
context
ITypeDescriptorContextAn ITypeDescriptorContext that provides a format context.
sourceType
TypeA Type that represents the type you want to convert from.
Returns
ConvertFrom(ITypeDescriptorContext?, CultureInfo?, object)
Converts the given object into a ServerAddress value, using the specified context and culture information.
public override object? ConvertFrom(ITypeDescriptorContext? context, CultureInfo? culture, object value)
Parameters
context
ITypeDescriptorContextAn ITypeDescriptorContext that provides a format context.
culture
CultureInfoThe CultureInfo to use as the current culture.
value
objectThe object to convert.
Returns
- object
An object that represents the converted ServerAddress value.