Documentation of 'org.joone.edit.NetStorageFormatManager' Java class
NetStorageFormatManager
org.joone.edit

Class NetStorageFormatManager



  • public class NetStorageFormatManager
    extends java.lang.Object
    The NetStorageFormatManager is a contains NetStorageFormats. It is not a Singleton because it could be necessary to deal with different format managers, e.g. one for importing NeuralNets, one for exporting NeuralNets. If one NetStorageFormat matches the file extension of the NeuralNet file, then this NetStorageFormat can be used to store or restore the NeuralNet.
    See Also:
    StorageFormat
    • Constructor Detail

      • NetStorageFormatManager

        public NetStorageFormatManager()
        Create a new NetStorageFormatManager.
    • Method Detail

      • addStorageFormat

        public void addStorageFormat(NetStorageFormat newStorageFormat)
        Add a NetStorageFormat that should be supported by this NetStorageFormatManager.
        Parameters:
        newStorageFormat - new NetStorageFormat to be supported
      • removeStorageFormat

        public void removeStorageFormat(NetStorageFormat oldStorageFormat)
        Remove a StorageFormat that should no longer be supported by this StorageFormatManager. The StorageFormat is excluded in when search for a StorageFormat.
        Parameters:
        oldStorageFormat - old NetStorageFormat no longer to be supported
      • containsStorageFormat

        public boolean containsStorageFormat(NetStorageFormat checkStorageFormat)
        Test, whether a NetStorageFormat is supported by this StorageFormat
      • setDefaultStorageFormat

        public void setDefaultStorageFormat(NetStorageFormat newDefaultStorageFormat)
        Set a NetStorageFormat as the default storage format which is selected in a javax.swing.JFileChooser. The default storage format must be already added with addStorageFormat. Setting the default storage format to null does not automatically remove the StorageFormat from the list of supported StorageFormats.
        Parameters:
        newDefaultStorageFormat - StorageFormat that should be selected in a JFileChooser
      • getDefaultStorageFormat

        public NetStorageFormat getDefaultStorageFormat()
        Return the NetStorageFormat which is used as selected file format in a javax.swing.JFileChooser
        Returns:
        default storage format
      • registerFileFilters

        public void registerFileFilters(javax.swing.JFileChooser fileChooser)
        Register all FileFilters supported by NetStorageFormats
        Parameters:
        fileChooser - javax.swing.JFileChooser to which FileFilters are added
      • findStorageFormat

        public NetStorageFormat findStorageFormat(javax.swing.filechooser.FileFilter findFileFilter)
        Find a NetStorageFormat that can be used according to a FileFilter to store a NeuralNet in a file or restore it from a file respectively.
        Parameters:
        findFileFilter - FileFilter used to identify a NetStorageFormat
        Returns:
        NetStorageFormat, if a matching file extension could be found, false otherwise

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.