001    package net.sf.logdistiller.publishers;
002    
003    /*
004     * Licensed under the Apache License, Version 2.0 (the "License");
005     * you may not use this file except in compliance with the License.
006     * You may obtain a copy of the License at
007     *
008     *     http://www.apache.org/licenses/LICENSE-2.0
009     *
010     * Unless required by applicable law or agreed to in writing, software
011     * distributed under the License is distributed on an "AS IS" BASIS,
012     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013     * See the License for the specific language governing permissions and
014     * limitations under the License.
015     */
016    
017    import java.util.*;
018    
019    import net.sf.logdistiller.*;
020    
021    /**
022     * Declaration of base publishers that are shipped with <b>LogDistiller</b>.
023     *
024     * @since 0.7
025     */
026    public class BasePublishers
027        extends Publishers
028    {
029        // feed publisher has a dependency on Rome, which must really stay optional (should have been an extension)
030        private final static Publisher FEED_PUBLISHER =
031            new DelegatePublisher( "feed", BasePublishers.class.getPackage().getName() + ".FeedPublisher" );
032    
033        private final static Publisher[] REPORT_TYPES = { new FilePublisher(), new MailPublisher(), FEED_PUBLISHER };
034    
035        private final static List REPORT_TYPES_LIST = Collections.unmodifiableList( Arrays.asList( REPORT_TYPES ) );
036    
037        public List definePublishers()
038        {
039            return REPORT_TYPES_LIST;
040        }
041    }