AssetTypeRegistry

public class AssetTypeRegistry

Registry for managing assettype registration. Provides methods to register and query assettype items.

java.lang.Object > AssetTypeRegistry

Field Summary

setupPacket

private AssetEditorSetupAssetTypes setupPacket

Field setupPacket.

extension

final String extension

Field extension.

assetTypeHandler

final AssetTypeHandler assetTypeHandler

Field assetTypeHandler.

types

final List types

Field types.

Method Detail

AssetTypeRegistry

public public AssetTypeRegistry ()

Method AssetTypeRegistry.

getRegisteredAssetTypeHandlers

public AssetTypeHandler> getRegisteredAssetTypeHandlers ()

Method getRegisteredAssetTypeHandlers.

registerAssetType

public void registerAssetType (@Nonnull final AssetTypeHandler assetType)

Method registerAssetType.

Parameters:
@Nonnull final AssetTypeHandler assetType

IllegalArgumentException

public new IllegalArgumentException ("An asset type with id '" + assetType.getConfig()

Method IllegalArgumentException.

Parameters:
"An asset type with id '" + assetType.getConfig(

unregisterAssetType

public void unregisterAssetType (@Nonnull final AssetTypeHandler assetType)

Method unregisterAssetType.

Parameters:
@Nonnull final AssetTypeHandler assetType

getAssetTypeHandler

public AssetTypeHandler getAssetTypeHandler (final String id)

Method getAssetTypeHandler.

Parameters:
final String id

getAssetTypeHandlerForPath

public AssetTypeHandler getAssetTypeHandlerForPath (@Nonnull final Path path)

Method getAssetTypeHandlerForPath.

Parameters:
@Nonnull final Path path

isPathInAssetTypeFolder

public boolean isPathInAssetTypeFolder (@Nonnull final Path path)

Method isPathInAssetTypeFolder.

Parameters:
@Nonnull final Path path

tryGetAssetTypeHandler

public AssetTypeHandler tryGetAssetTypeHandler (@Nonnull final Path assetPath, @Nonnull final EditorClient editorClient, final int requestToken)

Method tryGetAssetTypeHandler.

Parameters:
@Nonnull final Path assetPath
@Nonnull final EditorClient editorClient
final int requestToken

sendPacket

public void sendPacket (@Nonnull final EditorClient editorClient)

Method sendPacket.

Parameters:
@Nonnull final EditorClient editorClient

setupPacket

public void setupPacket ()

Method setupPacket.

AssetEditorSetupAssetTypes

public new AssetEditorSetupAssetTypes (types.toArray(AssetEditorAssetType[]::new)

Method AssetEditorSetupAssetTypes.

Parameters:
types.toArray(AssetEditorAssetType[]::new types.toArray(AssetEditorAssetType[]::new