Class SaltValidator
- java.lang.Object
-
- org.corpus_tools.pepper.impl.PepperModuleImpl
-
- org.corpus_tools.pepper.impl.PepperManipulatorImpl
-
- org.corpus_tools.pepper.modules.coreModules.SaltValidator
-
- All Implemented Interfaces:
Thread.UncaughtExceptionHandler,PepperManipulator,PepperModule
public class SaltValidator extends PepperManipulatorImpl
This class analyzes a Salt model and prints out a report about conflicts in the Salt model.- Author:
- Florian Zipser
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSaltValidator.ValidatorMapperChecks whether eachSCorpusobject contains either aSCorpusobject or aSDocumentobject.
-
Field Summary
-
Fields inherited from class org.corpus_tools.pepper.impl.PepperModuleImpl
isMultithreaded, moduleController, resources, saltProject, sCorpusGraph, symbolicName, temproraries
-
Fields inherited from interface org.corpus_tools.pepper.modules.PepperModule
ENDING_ALL_FILES, ENDING_FOLDER, ENDING_LEAF_FOLDER, ENDING_TAB, ENDING_TXT, ENDING_XML
-
-
Constructor Summary
Constructors Constructor Description SaltValidator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PepperMappercreatePepperMapper(org.corpus_tools.salt.graph.Identifier sElementId)OVERRIDE THIS METHOD FOR CUSTOMIZED MAPPING.SelfTestDescgetSelfTestDesc()This method is called by the Pepper framework to run an integration test for module.-
Methods inherited from class org.corpus_tools.pepper.impl.PepperModuleImpl
activate, done, done, end, getComponentContext, getCorpusGraph, getDesc, getDocumentId2DC, getFingerprint, getMapperControllers, getMapperThreadGroup, getModuleController, getModuleType, getName, getProgress, getProgress, getProperties, getResources, getSaltProject, getStartProblems, getSupplierContact, getSupplierHomepage, getSymbolicName, getTemproraries, getVersion, isMultithreaded, isReadyToStart, proposeImportOrder, setCorpusGraph, setDesc, setIsMultithreaded, setMapperThreadGroup, setName, setPepperModuleController, setPepperModuleController_basic, setProperties, setResources, setSaltProject, setSupplierContact, setSupplierHomepage, setSymbolicName, setTemproraries, setVersion, start, start, toString, uncaughtException
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.corpus_tools.pepper.modules.PepperModule
done, done, end, getComponentContext, getCorpusGraph, getDesc, getFingerprint, getModuleController, getModuleType, getName, getProgress, getProgress, getProperties, getResources, getSaltProject, getStartProblems, getSupplierContact, getSupplierHomepage, getSymbolicName, getTemproraries, getVersion, isMultithreaded, isReadyToStart, proposeImportOrder, setCorpusGraph, setDesc, setIsMultithreaded, setPepperModuleController, setPepperModuleController_basic, setProperties, setResources, setSaltProject, setSupplierContact, setSupplierHomepage, setSymbolicName, setTemproraries, setVersion, start, start
-
-
-
-
Method Detail
-
createPepperMapper
public PepperMapper createPepperMapper(org.corpus_tools.salt.graph.Identifier sElementId)
Description copied from class:PepperModuleImplOVERRIDE THIS METHOD FOR CUSTOMIZED MAPPING. This method creates a customizedPepperMapperobject and returns it. You can here do some additional initialisations. Thinks like setting theIdentifierof theSDocumentorSCorpusobject and theURIresource is done by the framework (or more in detail in methodPepperModule.start()). The parametersElementId, if aPepperMapperobject should be created in case of the object to map is either anSDocumentobject or anSCorpusobject of the mapper should be initialized differently.
Note: Override this method.- Specified by:
createPepperMapperin interfacePepperModule- Overrides:
createPepperMapperin classPepperModuleImpl- Parameters:
sElementId-Identifierof theSCorpusorSDocumentto be processed.- Returns:
PepperMapperobject to do the mapping task for object connected to givenIdentifier
-
getSelfTestDesc
public SelfTestDesc getSelfTestDesc()
Description copied from interface:PepperModuleThis method is called by the Pepper framework to run an integration test for module. When the method returns null, it means that no integration test is supported. Otherwise, theSelfTestDescobject needs to provide an input corpus path and an output corpus path. When this module is:- an importer:
SelfTestDesc.getInputCorpusPath()should contain the format to be imported.SelfTestDesc.getExpectedCorpusPath()should contain the expected salt project (for control). - a manipulator:
SelfTestDesc.getInputCorpusPath()should contain a salt project which is the module's input.SelfTestDesc.getExpectedCorpusPath()should contain the expected salt project (for control). - an exporter:
SelfTestDesc.getInputCorpusPath()should contain a salt project which is the module's input.SelfTestDesc.getExpectedCorpusPath()should contain the expected corpus in output format.
return new IntegrationTestDesc(inputPath, outputPath);
When this module is an importer or a manipulator the methodSelfTestDesc.compare(SaltProject, SaltProject)is called to compare output salt project with expected salt project. When the module is an exporter the methodSelfTestDesc.compare(URI, URI)is called to compare the created output folder with an expected one. By default this method checks whether the file structure and each file is equal.- Specified by:
getSelfTestDescin interfacePepperModule- Overrides:
getSelfTestDescin classPepperModuleImpl- Returns:
- test description
- an importer:
-
-