java.lang.Object
java.lang.Record
technology.sola.engine.assets.list.AssetList
- Record Components:
audioAssets- the list ofAudioClipassetsfontAssets- the list ofFontassetsguiAssets- the list ofGuiJsonDocumentassetsimageAssets- the list ofSolaImageassetssceneAssets- the list ofSceneassetsspriteSheetAssets- the list ofSpriteSheetassets
- All Implemented Interfaces:
Asset
@NullMarked
public record AssetList(List<AssetList.AssetDetails<AudioClip>> audioAssets, List<AssetList.AssetDetails<Font>> fontAssets, List<AssetList.AssetDetails<GuiJsonDocument>> guiAssets, List<AssetList.AssetDetails<SolaImage>> imageAssets, List<AssetList.AssetDetails<Scene>> sceneAssets, List<AssetList.AssetDetails<SpriteSheet>> spriteSheetAssets)
extends Record
implements Asset
AssetList is an
Asset that contains a list of other assets to be loaded.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordAssetList.AssetDetails<T extends Asset>AssetDetails contains details for loading assets on startup of theSola. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionAssetList(List<AssetList.AssetDetails<AudioClip>> audioAssets, List<AssetList.AssetDetails<Font>> fontAssets, List<AssetList.AssetDetails<GuiJsonDocument>> guiAssets, List<AssetList.AssetDetails<SolaImage>> imageAssets, List<AssetList.AssetDetails<Scene>> sceneAssets, List<AssetList.AssetDetails<SpriteSheet>> spriteSheetAssets) Creates an instance of aAssetListrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theaudioAssetsrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefontAssetsrecord component.Returns the value of theguiAssetsrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of theimageAssetsrecord component.Returns the value of thesceneAssetsrecord component.Returns the value of thespriteSheetAssetsrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
ID
The id of the main asset list.- See Also:
-
PATH
The path to the main asset list.- See Also:
-
-
Constructor Details
-
AssetList
public AssetList(List<AssetList.AssetDetails<AudioClip>> audioAssets, List<AssetList.AssetDetails<Font>> fontAssets, List<AssetList.AssetDetails<GuiJsonDocument>> guiAssets, List<AssetList.AssetDetails<SolaImage>> imageAssets, List<AssetList.AssetDetails<Scene>> sceneAssets, List<AssetList.AssetDetails<SpriteSheet>> spriteSheetAssets) Creates an instance of aAssetListrecord class.- Parameters:
audioAssets- the value for theaudioAssetsrecord componentfontAssets- the value for thefontAssetsrecord componentguiAssets- the value for theguiAssetsrecord componentimageAssets- the value for theimageAssetsrecord componentsceneAssets- the value for thesceneAssetsrecord componentspriteSheetAssets- the value for thespriteSheetAssetsrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
audioAssets
Returns the value of theaudioAssetsrecord component.- Returns:
- the value of the
audioAssetsrecord component
-
fontAssets
Returns the value of thefontAssetsrecord component.- Returns:
- the value of the
fontAssetsrecord component
-
guiAssets
Returns the value of theguiAssetsrecord component.- Returns:
- the value of the
guiAssetsrecord component
-
imageAssets
Returns the value of theimageAssetsrecord component.- Returns:
- the value of the
imageAssetsrecord component
-
sceneAssets
Returns the value of thesceneAssetsrecord component.- Returns:
- the value of the
sceneAssetsrecord component
-
spriteSheetAssets
Returns the value of thespriteSheetAssetsrecord component.- Returns:
- the value of the
spriteSheetAssetsrecord component
-