com.ibm.as400.util.html

Class HTMLFileFilter

  • java.lang.Object
    • com.ibm.as400.util.html.HTMLFileFilter
  • All Implemented Interfaces:
    java.io.FilenameFilter


    public class HTMLFileFilter
    extends java.lang.Object
    implements java.io.FilenameFilter
    The HTMLFileFilter class determines if a File object is a file.

    This example creates a HTMLFileFilter object to determine which IFSJavaFile objects are files.

      // Create an IFSJavaFile object.
      IFSJavaFile root = new IFSJavaFile(system, "/QIBM");
      
      // Create a HTMLFileFilter object.
      HTMLFileFilter filter = new HTMLFileFilter();
      
      // Get the list of File objects.
      File[] files = root.listFiles(filter);
      
    See Also:
    FileListElement
    • Constructor Summary

      Constructors 
      Constructor and Description
      HTMLFileFilter()
      Constructs a default HTMLFileFilter object.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      boolean accept(java.io.File file, java.lang.String filename)
      Determines if a file should be included in a file list.
      • Methods inherited from class java.lang.Object

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

      • HTMLFileFilter

        public HTMLFileFilter()
        Constructs a default HTMLFileFilter object.
    • Method Detail

      • accept

        public boolean accept(java.io.File file,
                     java.lang.String filename)
        Determines if a file should be included in a file list.
        Specified by:
        accept in interface java.io.FilenameFilter
        Parameters:
        file - The directory in which the file was found.
        filename - The name of the file.
        Returns:
        true if the File is a file; false otherwise.