    001    /*
    002     * Licensed to the Apache Software Foundation (ASF) under one or more
    003     * contributor license agreements.  See the NOTICE file distributed with
    004     * this work for additional information regarding copyright ownership.
    005     * The ASF licenses this file to You under the Apache License, Version 2.0
    006     * (the "License"); you may not use this file except in compliance with
    007     * the License.  You may obtain a copy of the License at
    008     *
    009     *      http://www.apache.org/licenses/LICENSE-2.0
    010     *
    011     * Unless required by applicable law or agreed to in writing, software
    012     * distributed under the License is distributed on an "AS IS" BASIS,
    013     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    014     * See the License for the specific language governing permissions and
    015     * limitations under the License.
    016     */
    017    package org.apache.commons.io.filefilter;
    018
    019    import java.util.List;
    020
    021    /**
    022     * Defines operations for conditional file filters.
    023     *
    024     * @since Commons IO 1.1
    025     * @version $Revision: 619103 $ $Date: 2008-02-06 19:01:17 +0000 (Wed, 06 Feb 2008) $
    026     *
    027     * @author Steven Caswell
    028     */
    029    public interface ConditionalFileFilter {
    030
    031        /**
    032         * Adds the specified file filter to the list of file filters at the end of
    033         * the list.
    034         *
    035         * @param ioFileFilter the filter to be added
    036         * @since Commons IO 1.1
    037         */
    038        public void addFileFilter(IOFileFilter ioFileFilter);
    039
    040        /**
    041         * Returns this conditional file filter's list of file filters.
    042         *
    043         * @return the file filter list
    044         * @since Commons IO 1.1
    045         */
    046        public List<IOFileFilter> getFileFilters();
    047
    048        /**
    049         * Removes the specified file filter.
    050         *
    051         * @param ioFileFilter filter to be removed
    052         * @return <code>true</code> if the filter was found in the list,
    053         * <code>false</code> otherwise
    054         * @since Commons IO 1.1
    055         */
    056        public boolean removeFileFilter(IOFileFilter ioFileFilter);
    057
    058        /**
    059         * Sets the list of file filters, replacing any previously configured
    060         * file filters on this filter.
    061         *
    062         * @param fileFilters the list of filters
    063         * @since Commons IO 1.1
    064         */
    065        public void setFileFilters(List<IOFileFilter> fileFilters);
    066
    067    }