org.mesopotamia
Class ContentLoader
java.lang.Object
org.mesopotamia.LoaderBase
org.mesopotamia.ContentLoader
- All Implemented Interfaces:
- Loader, SourceLoader
public class ContentLoader
- extends LoaderBase
- implements SourceLoader
This loader stores zipped file content to the repository without any processing.
Definition of the loader in database
INSERT INTO LOADER (
LANGUAGE,
LANGUAGE_VERSION,
LEVEL,
LOADER_CLASS,
DESCRIPTION,
REQUIRES_SOURCE,
REQUIRES_ENVIRONMENT
) VALUES (
'language name',
'language version',
'content',
'org.mesopotamia.ContentLoader',
'Loads source content into database',
1,
0
);
- Author:
- Pavel
Method Summary |
java.lang.Object |
getData(int sourceUnitId,
java.lang.Integer scanId)
Returns source unit data as input stream. |
boolean |
load(int scanId,
int sourceUnitId,
Source source,
java.lang.Object environment)
Loads source to repository. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ContentLoader
public ContentLoader(RepositoryLanguage repoLanguage,
LoaderEntry xData)
load
public boolean load(int scanId,
int sourceUnitId,
Source source,
java.lang.Object environment)
- Description copied from interface:
SourceLoader
- Loads source to repository.
- Specified by:
load
in interface SourceLoader
- Returns:
- true if there were no errors during loading
getData
public java.lang.Object getData(int sourceUnitId,
java.lang.Integer scanId)
throws MesopotamiaException
- Returns source unit data as input stream.
- Specified by:
getData
in interface Loader
- Returns:
- Loader data converted to appropriate Java representation.
E.g. array of tokens for token loader.
- Throws:
MesopotamiaException
Copyright © 2005 Hammurapi Group. All Rights Reserved.