ur_rna.RNAstructureUI.utilities

## Class ImageGrabber

- java.lang.Object
- - ur_rna.RNAstructureUI.utilities.ImageGrabber

- All Implemented Interfaces:
    java.io.Serializable

      public class ImageGrabber
      extends java.lang.Object
      implements java.io.Serializable

  A class that creates images in various contexts for the RNAstructure GUI.
  See Also:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `private static long` | `serialVersionUID`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ImageGrabber()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static java.awt.image.BufferedImage` | `getImage(java.lang.String path)` Create an image.
    `static javax.swing.ImageIcon` | `getImageIcon(java.lang.String path)` Create an image icon.
    `static javax.swing.JLabel` | `getImageLabel(java.lang.String path)` Create an image label.
    `static java.awt.image.BufferedImage` | `tryGetImage(java.lang.String path)` Create an image.
    `static javax.swing.ImageIcon` | `tryGetImageIcon(java.lang.String path)` Create an image icon.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### serialVersionUID

          private static final long serialVersionUID

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### ImageGrabber

          public ImageGrabber()

  - ### Method Detail

    - #### getImage

          public static java.awt.image.BufferedImage getImage(java.lang.String path)
                                                       throws java.io.IOException

      Create an image.
      Parameters:
        `path` - The path to the image.
      Returns:
        The image.
      Throws:
        `java.io.IOException` - If an image cannot be read correctly. Since all image paths are hard coded, this should never be thrown.

    - #### getImageIcon

          public static javax.swing.ImageIcon getImageIcon(java.lang.String path)
                                                    throws java.io.IOException

      Create an image icon.
      Parameters:
        `path` - The path to the image.
      Returns:
        The image icon.
      Throws:
        `java.io.IOException` - If an image cannot be read correctly. Since all image paths are hard coded, this should never be thrown.

    - #### getImageLabel

          public static javax.swing.JLabel getImageLabel(java.lang.String path)
                                                  throws java.io.IOException

      Create an image label.
      Parameters:
        `path` - The path to the image.
      Returns:
        The image label.
      Throws:
        `java.io.IOException` - If an image cannot be read correctly. Since all image paths are hard coded, this should never be thrown.

    - #### tryGetImage

          public static java.awt.image.BufferedImage tryGetImage(java.lang.String path)

      Create an image.
      Parameters:
        `path` - The path to the image.
      Returns:
        The image, or null if an image cannot be read due to an IO error.

    - #### tryGetImageIcon

          public static javax.swing.ImageIcon tryGetImageIcon(java.lang.String path)

      Create an image icon.
      Parameters:
        `path` - The path to the image.
      Returns:
        The image icon, nor null if it is missing or cannot be read.