XamlValueConverter<TConverterBase> XamlValueConverter<TConverterBase> XamlValueConverter<TConverterBase> XamlValueConverter<TConverterBase> Class

Definizione

Fornisce una superficie API comune per le tecniche che generano valori di inizializzazione o serializzazione per XAML in base a un input diverso dal tipo di destinazione finale.Provides a common API surface for techniques that generate initialization or serialization values for XAML based on input other than the eventual destination type. Include le estensioni di markup e i convertitori di tipi.This includes markup extensions and type converters.

generic <typename TConverterBase>
 where TConverterBase : classpublic ref class XamlValueConverter : IEquatable<System::Xaml::Schema::XamlValueConverter<TConverterBase> ^>
public class XamlValueConverter<TConverterBase> : IEquatable<System.Xaml.Schema.XamlValueConverter<TConverterBase>> where TConverterBase : class
type XamlValueConverter<'ConverterBase (requires 'ConverterBase : null)> = class
    interface IEquatable<XamlValueConverter<'ConverterBase>>
Public Class XamlValueConverter(Of TConverterBase)
Implements IEquatable(Of XamlValueConverter(Of TConverterBase))

Parametri di tipo

TConverterBase

Classe base CLR per il convertitore specifico rappresentato dall'oggetto XamlValueConverter<TConverterBase>.The CLR base class for the particular converter that this XamlValueConverter<TConverterBase> represents. Si tratta in genere di uno dei seguenti elementi: TypeConverter, MarkupExtension o ValueSerializer.Typically this is one of the following: TypeConverter; MarkupExtension; ValueSerializer;

Ereditarietà
XamlValueConverter<TConverterBase>XamlValueConverter<TConverterBase>XamlValueConverter<TConverterBase>XamlValueConverter<TConverterBase>
Implementazioni
IEquatable<XamlValueConverter<TConverterBase>>

Commenti

Istanze di questo tipo vengono restituite dai metodi dello schema XAML API, ad esempio LookupTypeConverter.Instances of this type are returned by methods of the XAML schema API such as LookupTypeConverter. L'implementazione generica di XamlValueConverter<TConverterBase> fornisce un riferimento indiretto per l'assembly System. XAML in modo che il sistema XAML di schema e il tipo base non dispone di creare dipendenze sul valore di diversa tecniche di conversione che sono in genere le implementazioni in altri assembly.The generic implementation of XamlValueConverter<TConverterBase> provides indirection for the System.Xaml assembly so that the basic XAML schema and type system does not have to take dependencies on different value conversion techniques that are typically implementations in other assemblies.

Oggetto XamlValueConverter<TConverterBase> può essere costruito con un tipo di implementazione null, ma ad una XamlValueConverter<TConverterBase> restituirà null per CreateInstance.A XamlValueConverter<TConverterBase> can be constructed with a null implementation type, but such a XamlValueConverter<TConverterBase> will return null for CreateInstance.

Le firme del costruttore per XamlValueConverter<TConverterBase> usano un converterType parametro che fa riferimento al tipo specifico che implementa il comportamento di conversione.Constructor signatures for XamlValueConverter<TConverterBase> use a converterType parameter that references the specific type that implements the conversion behavior. Per un corretto funzionamento XamlValueConverter<TConverterBase> (quello che ha un valore diverso da null ConverterInstance), il converterType tipo dovrà essere eseguire il casting di TConverterBase vincolo.For a properly functioning XamlValueConverter<TConverterBase> (one that has a nonnull ConverterInstance), the converterType type is expected to be castable to the TConverterBase constraint. Una condizione di mancata corrispondenza non viene applicata dai costruttori, ma può produrre un InvalidCastException in fase di esecuzione.A mismatch condition is not enforced by constructors, but might produce an InvalidCastException at run time.

Costruttori

XamlValueConverter<TConverterBase>(Type, XamlType) XamlValueConverter<TConverterBase>(Type, XamlType) XamlValueConverter<TConverterBase>(Type, XamlType) XamlValueConverter<TConverterBase>(Type, XamlType)

Inizializza una nuova istanza della classe XamlValueConverter<TConverterBase> in base a un convertitore che implementa Type e al tipo di destinazione dell'oggetto XamlValueConverter<TConverterBase>.Initializes a new instance of the XamlValueConverter<TConverterBase> class, based on a converter implementing Type and the target/destination type of the XamlValueConverter<TConverterBase>.

XamlValueConverter<TConverterBase>(Type, XamlType, String) XamlValueConverter<TConverterBase>(Type, XamlType, String) XamlValueConverter<TConverterBase>(Type, XamlType, String) XamlValueConverter<TConverterBase>(Type, XamlType, String)

Inizializza una nuova istanza della classe XamlValueConverter<TConverterBase> in base a un convertitore che implementa Type, al tipo di destinazione dell'oggetto XamlValueConverter<TConverterBase> e a un nome di stringa.Initializes a new instance of the XamlValueConverter<TConverterBase> class, based on a converter implementing Type the target/destination type of the XamlValueConverter<TConverterBase>, and a string name.

Proprietà

ConverterInstance ConverterInstance ConverterInstance ConverterInstance

Ottiene un'istanza creata dell'implementazione del convertitore.Gets a created instance of the converter implementation.

ConverterType ConverterType ConverterType ConverterType

Ottiene l'oggetto Type per la classe che implementa il comportamento del convertitore.Gets the Type for the class that implements the converter behavior.

Name Name Name Name

Ottiene un nome di stringa per l'oggetto XamlValueConverter<TConverterBase>.Gets a string name for this XamlValueConverter<TConverterBase>.

TargetType TargetType TargetType TargetType

Ottiene l'oggetto XamlType di destinazione dell'oggetto XamlValueConverter<TConverterBase>.Gets the target/destination XamlType of the XamlValueConverter<TConverterBase>.

Metodi

CreateInstance() CreateInstance() CreateInstance() CreateInstance()

Restituisce un'istanza dell'implementazione del convertitore.Returns an instance of the converter implementation.

Equals(Object) Equals(Object) Equals(Object) Equals(Object)

Consente di determinare se questa istanza dell'oggetto XamlValueConverter<TConverterBase> e un oggetto specificato, che deve essere anch'esso un oggetto XamlValueConverter<TConverterBase>, hanno lo stesso valore.Determines whether this instance of XamlValueConverter<TConverterBase> and a specified object, which must also be a XamlValueConverter<TConverterBase> object, have the same value.

Equals(XamlValueConverter<TConverterBase>) Equals(XamlValueConverter<TConverterBase>) Equals(XamlValueConverter<TConverterBase>) Equals(XamlValueConverter<TConverterBase>)

Determina se questa istanza di XamlValueConverter<TConverterBase> e un altro oggetto XamlValueConverter<TConverterBase> hanno lo stesso valore.Determines whether this instance of XamlValueConverter<TConverterBase> and another XamlValueConverter<TConverterBase> object have the same value.

GetHashCode() GetHashCode() GetHashCode() GetHashCode()

Restituisce il codice hash per questo oggetto XamlValueConverter<TConverterBase>.Returns the hash code for this XamlValueConverter<TConverterBase>.

GetType() GetType() GetType() GetType()

Ottiene l'oggetto Type dell'istanza corrente.Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

Crea una copia superficiale dell'oggetto Object corrente.Creates a shallow copy of the current Object.

(Inherited from Object)
ToString() ToString() ToString() ToString()

Restituisce un oggetto String che rappresenta l'oggetto XamlValueConverter<TConverterBase>.Returns a String that represents this XamlValueConverter<TConverterBase>.

Operatori

Equality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>) Equality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>) Equality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>) Equality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>)

Determina se due oggetti XamlValueConverter<TConverterBase> specificati hanno lo stesso valore.Determines whether two specified XamlValueConverter<TConverterBase> objects have the same value.

Inequality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>) Inequality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>) Inequality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>) Inequality(XamlValueConverter<TConverterBase>, XamlValueConverter<TConverterBase>)

Determina se due oggetti XamlValueConverter<TConverterBase> specificati hanno valori diversi.Determines whether two specified XamlValueConverter<TConverterBase> objects have different values.

Si applica a