LongValidator.CanValidate(Type) Método
Definição
Importante
Algumas informações dizem respeito a um produto pré-lançado que pode ser substancialmente modificado antes de ser lançado. A Microsoft não faz garantias, de forma expressa ou implícita, em relação à informação aqui apresentada.
Determina se o tipo do objeto pode ser validado.
public:
override bool CanValidate(Type ^ type);
public override bool CanValidate(Type type);
override this.CanValidate : Type -> bool
Public Overrides Function CanValidate (type As Type) As Boolean
Parâmetros
- type
- Type
O tipo de objeto.
Devoluções
true se o type parâmetro corresponder a um Int64 valor; caso contrário, false.
Exemplos
O exemplo de código seguinte demonstra como usar o CanValidate método. Este exemplo de código faz parte de um exemplo maior fornecido para a LongValidator classe.
// Determine if the object to validate can be validated.
Console.WriteLine("CanValidate: {0}",
myLongValidator.CanValidate(testLong.GetType()));
' Determine if the object to validate can be validated.
Console.WriteLine("CanValidate: {0}", _
myLongValidator.CanValidate(testLong.GetType()))