Class CastHelper
- java.lang.Object
-
- org.pepstock.charba.client.dom.elements.CastHelper
-
public final class CastHelper extends Object
Utility to cast elements created in the other DOM tree engines in CHARBA elements.- Author:
- Andrea "Stock" Stocchero
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Canvas
toCanvas(Object object)
Returns aCanvas
object casting the argument.static Div
toDiv(Object object)
Returns aDiv
object casting the argument.static CanvasGradientItem
toGradient(Object object)
Returns aCanvasGradientItem
object casting the argument.static Img
toImg(Object object)
Returns aImg
object casting the argument.static CanvasPatternItem
toPattern(Object object)
Returns aCanvasPatternItem
object casting the argument.
-
-
-
Method Detail
-
toCanvas
public static Canvas toCanvas(Object object)
Returns aCanvas
object casting the argument.- Parameters:
object
- object to cast to a canvas- Returns:
- a
Canvas
object
-
toDiv
public static Div toDiv(Object object)
Returns aDiv
object casting the argument.- Parameters:
object
- object to cast to a div- Returns:
- a
Div
object
-
toImg
public static Img toImg(Object object)
Returns aImg
object casting the argument.- Parameters:
object
- object to cast to an image- Returns:
- a
Img
object
-
toPattern
public static CanvasPatternItem toPattern(Object object)
Returns aCanvasPatternItem
object casting the argument.- Parameters:
object
- object to cast to a canvas pattern- Returns:
- a
CanvasPatternItem
object
-
toGradient
public static CanvasGradientItem toGradient(Object object)
Returns aCanvasGradientItem
object casting the argument.- Parameters:
object
- object to cast to a canvas gradient- Returns:
- a
CanvasGradientItem
object
-
-