summaryrefslogtreecommitdiff
path: root/app/src/androidTest/java/de/test/antennapod/util/syndication/feedgenerator/FeedGenerator.java
blob: fe5afd84724425c04b31a77422bca84450507c18 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package de.test.antennapod.util.syndication.feedgenerator;

import de.danoeh.antennapod.core.feed.Feed;

import java.io.IOException;
import java.io.OutputStream;

/**
 * Generates a machine-readable, platform-independent representation of a Feed object.
 */
public interface FeedGenerator {

    /**
     * Creates a machine-readable, platform-independent representation of a given
     * Feed object and writes it to the given OutputStream.
     * <p/>
     * The representation might not be compliant with its specification if the feed
     * is missing certain attribute values. This is intentional because the FeedGenerator is
     * used for creating test data.
     *
     * @param feed         The feed that should be written. Must not be null.
     * @param outputStream The output target that the feed will be written to. The outputStream is not closed after
     *                     the method's execution Must not be null.
     * @param encoding     The encoding to use. Must not be null.
     * @param flags        Optional argument for enabling implementation-dependent features.
     */
    public void writeFeed(Feed feed, OutputStream outputStream, String encoding, long flags) throws IOException;
}