# Enum AssetDef.Type

java.lang.Object
java.lang.Enum<AssetDef.Type>
com.codename1.gaming.level.AssetDef.Type

All Implemented Interfaces:
  `Comparable<AssetDef.Type>`

Enclosing class:
  `AssetDef`

public static enum AssetDef.Type extends Enum<AssetDef.Type>
The art format of an asset, which decides what it is realized into.

- ## Enum Constant Summary

  Enum Constants
  Enum Constant
  Description
  `IMAGE`
  A single static image (`source` is a PNG/JPG), realized as a `com.codename1.gaming.Sprite`.
  `MESH`
  A 3D mesh (glTF/glb), realized as a `com.codename1.gaming.Model`.
  `SHEET`
  A sprite sheet (a grid of equal frames) played as an animated `com.codename1.gaming.AnimatedSprite`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static AssetDef.Type`
  `fromWire(String name)`
  The format for an explicit JSON token (case-insensitive); `null`/unknown is `#IMAGE`.
  `static AssetDef.Type`
  `valueOf(String name)`
  Returns the enum constant of this type with the specified name.
  `static AssetDef.Type[]`
  `values()`
  Returns an array containing the constants of this enum type, in the order they are declared.
  `String`
  `wireName()`
  The lowercase JSON token for this format (`"image"` / `"sheet"` / `"mesh"`).

  ### Methods inherited from class Enum

  `clone, compareTo, equals, getDeclaringClass, getEnumValues, hashCode, name, ordinal, setEnumValues, toString, valueOf`

  ### Methods inherited from class Object

  `getClass, notify, notifyAll, wait, wait, wait`

- ## Enum Constant Details

  - ### IMAGE

    public static final AssetDef.Type IMAGE
    A single static image (`source` is a PNG/JPG), realized as a `com.codename1.gaming.Sprite`.

  - ### SHEET

    public static final AssetDef.Type SHEET
    A sprite sheet (a grid of equal frames) played as an animated `com.codename1.gaming.AnimatedSprite`.

  - ### MESH

    public static final AssetDef.Type MESH
    A 3D mesh (glTF/glb), realized as a `com.codename1.gaming.Model`.

- ## Method Details

  - ### values

    public static AssetDef.Type[] values()
    Returns an array containing the constants of this enum type, in the order they are declared.
    Returns:
      an array containing the constants of this enum type, in the order they are declared

  - ### valueOf

    public static AssetDef.Type valueOf(String name)
    Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
    Parameters:
      `name` - the name of the enum constant to be returned.
    Returns:
      the enum constant with the specified name
    Throws:
      `IllegalArgumentException` - if this enum type has no constant with the specified name
      `NullPointerException` - if the argument is null

  - ### wireName

    public String wireName()
    The lowercase JSON token for this format (`"image"` / `"sheet"` / `"mesh"`).

  - ### fromWire

    public static AssetDef.Type fromWire(String name)
    The format for an explicit JSON token (case-insensitive); `null`/unknown is `#IMAGE`.