Source code: org/apache/batik/apps/rasterizer/SVGConverterSource.java
1 /*
2
3 Copyright 2001,2003 The Apache Software Foundation
4
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9 http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16
17 */
18 package org.apache.batik.apps.rasterizer;
19
20 import java.io.IOException;
21 import java.io.InputStream;
22
23 /**
24 * Interface used to handle both Files and URLs in the
25 * <tt>SVGConverter</tt>
26 *
27 * @author <a href="mailto:vhardy@apache.org">Vincent Hardy</a>
28 * @version $Id: SVGConverterSource.java,v 1.5 2004/08/18 07:12:26 vhardy Exp $
29 */
30 public interface SVGConverterSource {
31 /**
32 * Returns the name of the source. That would be the
33 * name for a File or URL
34 */
35 public String getName();
36
37 /**
38 * Gets a <tt>TranscoderInput</tt> for that source
39 */
40 public InputStream openStream() throws IOException;
41
42 /**
43 * Checks if same as source described by srcStr
44 */
45 public boolean isSameAs(String srcStr);
46
47 /**
48 * Checks if source can be read
49 */
50 public boolean isReadable();
51
52 /**
53 * Returns a URI string corresponding to this source
54 */
55 public String getURI();
56 }
57