Transformer.Valid C# (CSharp) Method

Valid() public method

This method is used to determine if the type specified can be transformed. This will use the Matcher to find a suitable transform, if one exists then this returns true, if not then this returns false. This is used during serialization to determine how to convert a field or method parameter.
public Valid ( Class, type ) : bool
type Class, /// the type to determine whether its transformable ///
return bool
   public bool Valid(Class type) {
      return Lookup(type) != null;
   }
   /// <summary>

Usage Example

Example #1
0
 /// <summary>
 /// This method is used to determine if the type specified can be
 /// transformed. This will use the <c>Matcher</c> to find a
 /// suitable transform, if one exists then this returns true, if
 /// not then this returns false. This is used during serialization
 /// to determine how to convert a field or method parameter.
 /// </summary>
 /// <param name="type">
 /// the type to determine whether its transformable
 /// </param>
 /// <returns>
 /// true if the type specified can be transformed by this
 /// </returns>
 public bool Valid(Class type)
 {
     return(transform.Valid(type));
 }