cdc.impex.imports.CheckedWorkbookImporter Maven / Gradle / Ivy
The newest version!
package cdc.impex.imports;
import cdc.impex.ImpExStatus;
import cdc.issues.Issue;
import cdc.issues.IssuesHandler;
import cdc.util.lang.Checks;
public class CheckedWorkbookImporter extends CheckedSheetImporter implements WorkbookImporter {
public CheckedWorkbookImporter() {
status = ImpExStatus.INIT;
}
@Override
protected void checkStatus(ImpExStatus expected) {
Checks.isTrue(this.status == expected, "Invalid status " + status + ", expected " + expected);
}
@Override
public void beginImport(String systemId,
IssuesHandler issuesHandler) {
checkStatus(ImpExStatus.INIT);
status = ImpExStatus.WORKBOOK;
}
@Override
public void endImport(String systemId,
IssuesHandler issuesHandler) {
checkStatus(ImpExStatus.WORKBOOK);
status = ImpExStatus.INIT;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy