de.tuberlin.cs.flp.jspwiki.plugin.wikiarchive
Archive
model interface and one type of data source/sink. Importing and exporting from/to external data sources is implicitly implemented by WikiArchive, which uses the Archive
model interface as intermediate data container between the Wiki's internal i/o-handler and any other i/o-handler. Using this architecture, only bidirectional conversions between the Archive
model interface and each data source (including the Wiki itself) need to be implemented. Direct conversions between different types are never needed, as the Archive
model interface acts as intermediate data container. Each WikiArchive needs at least one ArchiveIOHandler registered for type "wiki", Allows the implementation of pluggable i/o-handlers for internal Wiki i/o and any external import/export data source.
|
|||
public static
boolean
|
EXPORT |
||
public static
boolean
|
IMPORT |
|
|||
public
Object
|
createData()
Creates an empty data source to be filled for export.
|
||
public
String
|
dataToString(Object data)
Converts the handled data source to string for export.
|
||
public
String
|
getContentSuffix()
Content suffix for export via HTTP.
|
||
public
String
|
getContentType()
Content type for export via HTTP.
|
||
public
void
|
init(WikiEngine engine, Map config)
Initializes this ArchiveHandler.
|
||
public
String
|
performIO(boolean io, Archive archive, Object data, int mode, Collection exceptions)
Perform either input from the
Archive model interface
into the data source handled by this ArchiveIOHandler.
@param plugin The WikiArchive plugin. |
||
public
void
|
stringToData(String s, Object data)
Converts a string to a handled data source for import.
|
Tagged Values | |
static
|
false
|
documentation#author
|
Jens Gulden
|
documentation#see
|
de.tuberlin.cs.flp.jspwiki.plugin.WikiArchive#initIOHandlers(Object[][])
|
documentation#version
|
0.2.0
|
|
public static final
boolean EXPORT
public static final
boolean IMPORT
|
public
Object
createData()
public
String
dataToString(Object data)
data
-
public
String
getContentSuffix()
public
String
getContentType()
public
void init(WikiEngine engine, Map config)
engine
-
config
-
public
String
performIO(boolean io, Archive archive, Object data, int mode, Collection exceptions)
Archive
model interface
into the data source handled by this ArchiveIOHandler.
@param plugin The WikiArchive plugin.Method Tagged Values | |
documentation#throws
|
IOException if an i/o error occurs
|
io
- Switch between input or output mode, Archive
model interface.
archive
- The Archive
model interface.
data
- The data source handled by this ArchiveIOHandler.
mode
- The processing mode. This is a bit mask with:exceptions
- Collection of entry names that should be treated as exceptions to the behaviour specified by mode
. (Not used.)
public
void stringToData(String s, Object data)
s
-
data
-