Class V23Transcoder
java.lang.Object
com.illumon.iris.gui.workspace.compatability.V23Transcoder
- All Implemented Interfaces:
WorkspaceTranscoder
This transcoder fixes an early bug in the v01 transcoder that did not correctly convert all
of the SavedFilterManager model filters.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvertWorkspace(SavedWorkspace workspace, Path destination, boolean isStandalone) Convert the specified workspace toWorkspaceTranscoder.getToVersion().intgetMostRecentWorkspace(String pathStr) Get the most recent workspace this transcoder understands at the specified path.intgetWorkspaces(String pathStr, WorkspaceManager.SaveType saveType) Get all of the workspaces this transcoder understands at the specified path.tryGetSavedWorkspace(Path path) Try to create a SavedWorkspace at this transcoder version from the specified path.
-
Constructor Details
-
V23Transcoder
public V23Transcoder(com.fishlib.io.logger.Logger log)
-
-
Method Details
-
getFromVersion
public int getFromVersion()- Specified by:
getFromVersionin interfaceWorkspaceTranscoder- Returns:
- The workspace version this transcoder converts from.
-
getToVersion
public int getToVersion()- Specified by:
getToVersionin interfaceWorkspaceTranscoder- Returns:
- The workspace version this transcoder converts to.
-
getMostRecentWorkspace
Description copied from interface:WorkspaceTranscoderGet the most recent workspace this transcoder understands at the specified path.- Specified by:
getMostRecentWorkspacein interfaceWorkspaceTranscoder- Parameters:
pathStr- The path to search in- Returns:
- The most recent workspace this transcoder understands or null if there are none.
-
getWorkspaces
Description copied from interface:WorkspaceTranscoderGet all of the workspaces this transcoder understands at the specified path.- Specified by:
getWorkspacesin interfaceWorkspaceTranscoder- Parameters:
pathStr- The path to search in.saveType- The type of workspace save to get- Returns:
- All of the workspaces this transcoder understands.
-
convertWorkspace
public SavedWorkspace convertWorkspace(SavedWorkspace workspace, Path destination, boolean isStandalone) throws TranscodingException Description copied from interface:WorkspaceTranscoderConvert the specified workspace toWorkspaceTranscoder.getToVersion().- Specified by:
convertWorkspacein interfaceWorkspaceTranscoder- Parameters:
workspace- The workspace to convert. Must be atWorkspaceTranscoder.getFromVersion()destination- The path for writing out the new file, this may be adjusted by the transcoder as necessaryisStandalone- if the console is in standalone mode- Returns:
- A new
SavedWorkspaceat versionWorkspaceTranscoder.getToVersion() - Throws:
TranscodingException- If there was an error during conversion
-
tryGetSavedWorkspace
Description copied from interface:WorkspaceTranscoderTry to create a SavedWorkspace at this transcoder version from the specified path.- Specified by:
tryGetSavedWorkspacein interfaceWorkspaceTranscoder- Parameters:
path- The path to the workspace to try to parse- Returns:
- A SavedWorkspace or null if the workspace couldn't be parsed.
-