Class ImgProperties

All Implemented Interfaces:
HasHandlers

public class ImgProperties extends ImgHTMLProperties
A set of properties that can be used to create an image.
  • Constructor Details

    • ImgProperties

      public ImgProperties()
    • ImgProperties

      public ImgProperties(JavaScriptObject jsObj)
    • ImgProperties

      public ImgProperties(String src, int width, int height)
  • Method Details

    • getOrCreateRef

      public static ImgProperties getOrCreateRef(JavaScriptObject jsObj)
    • setEventStuff

      public ImgProperties setEventStuff(String eventStuff)
      Specifies the additional event-related attributes to write in the tag.
      Overrides:
      setEventStuff in class ImgHTMLProperties
      Parameters:
      eventStuff - New eventStuff value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
      See Also:
    • getEventStuff

      public String getEventStuff()
      Specifies the additional event-related attributes to write in the tag.
      Overrides:
      getEventStuff in class ImgHTMLProperties
      Returns:
      Current eventStuff value. Default value is null
      See Also:
    • setExtraStuff

      public ImgProperties setExtraStuff(String extraStuff)
      Specifies the additional attributes to write in the tag. Event-related attributes should be added to eventStuff instead to guarantee proper behavior when using SVG via regular .svg image files.
      Overrides:
      setExtraStuff in class ImgHTMLProperties
      Parameters:
      extraStuff - New extraStuff value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
    • getExtraStuff

      public String getExtraStuff()
      Specifies the additional attributes to write in the tag. Event-related attributes should be added to eventStuff instead to guarantee proper behavior when using SVG via regular .svg image files.
      Overrides:
      getExtraStuff in class ImgHTMLProperties
      Returns:
      Current extraStuff value. Default value is null
    • setHeight

      public ImgProperties setHeight(Integer height)
      Specifies the height of the image.
      Overrides:
      setHeight in class ImgHTMLProperties
      Parameters:
      height - New height value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
    • getHeight

      public Integer getHeight()
      Specifies the height of the image.
      Overrides:
      getHeight in class ImgHTMLProperties
      Returns:
      Current height value. Default value is null
    • setImgDir

      public ImgProperties setImgDir(String imgDir)
      Specifies the image-specific image directory to override the default.
      Overrides:
      setImgDir in class ImgHTMLProperties
      Parameters:
      imgDir - New imgDir value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
      See Also:
    • getImgDir

      public String getImgDir()
      Specifies the image-specific image directory to override the default.
      Overrides:
      getImgDir in class ImgHTMLProperties
      Returns:
      Current imgDir value. Default value is null
      See Also:
    • setName

      public ImgProperties setName(String name)
      Specifies the name of the image. This is an identifier unique to the canvas, and subsequent calls to Canvas.getImage() and Canvas.setImage() with this name will act on the image object created using this ImgProperties object.
      Overrides:
      setName in class ImgHTMLProperties
      Parameters:
      name - New name value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
    • getName

      public String getName()
      Specifies the name of the image. This is an identifier unique to the canvas, and subsequent calls to Canvas.getImage() and Canvas.setImage() with this name will act on the image object created using this ImgProperties object.
      Overrides:
      getName in class ImgHTMLProperties
      Returns:
      Current name value. Default value is null
    • setSrc

      public ImgProperties setSrc(String src)
      Specifies the URL of the image local to the skin or application directory.
      Overrides:
      setSrc in class ImgHTMLProperties
      Parameters:
      src - New src value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
      See Also:
    • getSrc

      public String getSrc()
      Specifies the URL of the image local to the skin or application directory.
      Overrides:
      getSrc in class ImgHTMLProperties
      Returns:
      Current src value. Default value is null
      See Also:
    • setWidth

      public ImgProperties setWidth(Integer width)
      Specifies the width of the image.
      Overrides:
      setWidth in class ImgHTMLProperties
      Parameters:
      width - New width value. Default value is null
      Returns:
      ImgProperties instance, for chaining setter calls
    • getWidth

      public Integer getWidth()
      Specifies the width of the image.
      Overrides:
      getWidth in class ImgHTMLProperties
      Returns:
      Current width value. Default value is null