Interface ICSSValueConverter

All Known Implementing Classes:
AbstractCSSValueConverter, CSSValueBooleanConverterImpl, CSSValueSWTColorConverterImpl, CSSValueSWTCursorConverterImpl, CSSValueSWTFontConverterImpl, CSSValueSWTFontDataConverterImpl, CSSValueSWTGradientConverterImpl, CSSValueSWTImageConverterImpl, CSSValueSWTRGBConverterImpl

public interface ICSSValueConverter
A one-way converter. This interface is not intended to be implemented by clients; clients should subclass AbstractCSSValueConverter.
Version:
1.0.0
Author:
Angelo ZERR
  • Method Details

    • getToType

      Object getToType()
      Returns the type to which this converter can convert. The return type is Object rather than Class to optionally support richer type systems than the one provided by Java reflection.
      Returns:
      the type to which this converter can convert, or null if this converter is untyped
    • convert

      Object convert(CSSValue value, CSSEngine engine, Object context) throws Exception
      Returns the result of the conversion of the given CSSValue value.
      Parameters:
      value - the CSSValue to convert
      context -
      Returns:
      the converted object
      Throws:
      Exception
    • convert

      String convert(Object value, CSSEngine engine, Object context) throws Exception
      Returns String CSSValue of the result of the conversion of the given Object value.
      Parameters:
      value -
      Throws:
      Exception
    • convert

      String convert(Object value, CSSEngine engine, Object context, ICSSValueConverterConfig config) throws Exception
      Returns String CSSValue of the result of the conversion of the given Object value. config can be used to manage format of the CSSValue String to return.
      Throws:
      Exception