Enum AssetDef.Type
- All Implemented Interfaces:
Comparable<AssetDef.Type>
- Enclosing class:
AssetDef
The art format of an asset, which decides what it is realized into.
-
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic AssetDef.TypeThe format for an explicit JSON token (case-insensitive);null/unknown is#IMAGE.static AssetDef.TypeReturns 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.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
-
Enum Constant Details
-
IMAGE
A single static image (sourceis a PNG/JPG), realized as acom.codename1.gaming.Sprite. -
SHEET
A sprite sheet (a grid of equal frames) played as an animatedcom.codename1.gaming.AnimatedSprite. -
MESH
A 3D mesh (glTF/glb), realized as acom.codename1.gaming.Model.
-
-
Method Details
-
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
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 nameNullPointerException- if the argument is null
-
wireName
The lowercase JSON token for this format ("image"/"sheet"/"mesh"). -
fromWire
The format for an explicit JSON token (case-insensitive);null/unknown is#IMAGE.
-