Package ij.plugin

Class FolderOpener

  • All Implemented Interfaces:
    PlugIn

    public class FolderOpener
    extends java.lang.Object
    implements PlugIn
    Implements the File/Import/Image Sequence command, which opens a folder of images as a stack.
    • Constructor Summary

      Constructors 
      Constructor Description
      FolderOpener()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean excludedFileType​(java.lang.String name)  
      static java.lang.String[] getFilteredList​(java.lang.String[] list, java.lang.String filter, java.lang.String title)  
      static ImagePlus open​(java.lang.String path)
      Opens the images in the specified directory as a stack.
      static ImagePlus open​(java.lang.String path, int width, int height, java.lang.String options)
      Opens the images in the specified directory as a widthxheight stack.
      static ImagePlus open​(java.lang.String path, java.lang.String options)
      Opens the images in the specified directory as a stack.
      void openAsVirtualStack​(boolean b)  
      ImagePlus openFolder​(java.lang.String path)
      Opens the images in the specified directory as a stack.
      void run​(java.lang.String arg)
      This method is called when the plugin is loaded.
      void sortByMetaData​(boolean b)  
      java.lang.String[] sortFileList​(java.lang.String[] list)
      Sorts file names containing numerical components.
      void sortFileNames​(boolean b)  
      java.lang.String[] trimFileList​(java.lang.String[] rawlist)
      Removes names that start with "." or end with ".db", ".txt", ".lut", "roi", ".pty", ".hdr", ".py", etc.
      static boolean useInfo​(java.lang.String info)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FolderOpener

        public FolderOpener()
    • Method Detail

      • open

        public static ImagePlus open​(java.lang.String path)
        Opens the images in the specified directory as a stack. Displays directory chooser and options dialogs if the argument is null.
      • open

        public static ImagePlus open​(java.lang.String path,
                                     java.lang.String options)
        Opens the images in the specified directory as a stack. Opens the images as a virtual stack if the 'options' string contains 'virtual' or 'use'. Add ' file=abc' to the options string to only open images with, for example, 'abc' in their name. Add ' noMetaSort' to disable sorting of DICOM stacks by series number (0020,0011). Displays directory chooser and options dialogs if the the 'path' argument is null.
      • open

        public static ImagePlus open​(java.lang.String path,
                                     int width,
                                     int height,
                                     java.lang.String options)
        Opens the images in the specified directory as a widthxheight stack. Opens the images as a virtual stack if the 'options' string contains 'virtual' or 'use'. Add ' file=abc' to the options string to only open images with, for example, 'abc' in their name. Add ' noMetaSort' to disable sorting of DICOM stacks by series number (0020,0011).
      • openFolder

        public ImagePlus openFolder​(java.lang.String path)
        Opens the images in the specified directory as a stack. Displays directory chooser and options dialogs if the argument is null.
      • run

        public void run​(java.lang.String arg)
        Description copied from interface: PlugIn
        This method is called when the plugin is loaded. 'arg', which may be blank, is the argument specified for this plugin in IJ_Props.txt.
        Specified by:
        run in interface PlugIn
      • useInfo

        public static boolean useInfo​(java.lang.String info)
      • getFilteredList

        public static java.lang.String[] getFilteredList​(java.lang.String[] list,
                                                         java.lang.String filter,
                                                         java.lang.String title)
      • trimFileList

        public java.lang.String[] trimFileList​(java.lang.String[] rawlist)
        Removes names that start with "." or end with ".db", ".txt", ".lut", "roi", ".pty", ".hdr", ".py", etc.
      • excludedFileType

        public static boolean excludedFileType​(java.lang.String name)
      • openAsVirtualStack

        public void openAsVirtualStack​(boolean b)
      • sortFileNames

        public void sortFileNames​(boolean b)
      • sortByMetaData

        public void sortByMetaData​(boolean b)
      • sortFileList

        public java.lang.String[] sortFileList​(java.lang.String[] list)
        Sorts file names containing numerical components.
        See Also:
        Author: Norbert Vischer