01: /*
02: * This file is part of "SnipSnap Radeox Rendering Engine".
03: *
04: * Copyright (c) 2002 Stephan J. Schmidt, Matthias L. Jugel
05: * All Rights Reserved.
06: *
07: * Please visit http://radeox.org/ for updates and contact.
08: *
09: * --LICENSE NOTICE--
10: * Licensed under the Apache License, Version 2.0 (the "License");
11: * you may not use this file except in compliance with the License.
12: * You may obtain a copy of the License at
13: *
14: * http://www.apache.org/licenses/LICENSE-2.0
15: *
16: * Unless required by applicable law or agreed to in writing, software
17: * distributed under the License is distributed on an "AS IS" BASIS,
18: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19: * See the License for the specific language governing permissions and
20: * limitations under the License.
21: * --LICENSE NOTICE--
22: */
23: package org.radeox.macro.list;
24:
25: import java.io.IOException;
26: import java.io.Writer;
27: import java.util.Collection;
28:
29: import org.radeox.util.Linkable;
30:
31: /**
32: * List formatter interface. List formatters are loaded via the plugin
33: * mechanism.
34: *
35: * @author Matthias L. Jugel
36: * @version $Id: ListFormatter.java 7707 2006-04-12 17:30:19Z
37: * ian@caret.cam.ac.uk $
38: */
39: public interface ListFormatter {
40: public String getName();
41:
42: /**
43: * Display a simple vertical list.
44: *
45: * @param writer
46: * Writer to write the list output to
47: * @param current
48: * the current linkable
49: * @param listComment
50: * String to display before the list
51: * @param c
52: * Collection of Linkables, Snips or Nameables to display
53: * @param emptyText
54: * Text to display if collection is empty
55: * @param showSize
56: * If showSize is true then the size of the collection is displayed
57: */
58: public void format(Writer writer, Linkable current,
59: String listComment, Collection c, String emptyText,
60: boolean showSize) throws IOException;
61: }
|