org.jcamp.parser.ASDFCheckHandler Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jcamp-dx Show documentation
Show all versions of jcamp-dx Show documentation
The JCAMP-DX project is the reference implemention of the IUPAC JCAMP-DX spectroscopy data standard.
The newest version!
package org.jcamp.parser;
interface ASDFCheckHandler {
public final static int ABORT = 0;
public final static int REPLACE = 1;
public final static int OK = 2;
public final static int IGNORE = 2;
/**
* checks current parsing state for x-sequence and y-value
* if x-sequence is wrong, set current index within state
* to correct value via state.setCurrentIndex(int newIndex)
* if y-value is wrong, set current y-value within state
* to correct value via state.setCurrentY(int newY)
* @param ASDFParsingState state the current parse state
* @return int returns the error handling policy:
* OK|IGNORE: state is correct
* REPLACE: state is modified, do correction
* ABORT: state is unrecoverable, throws JCAMPException
*/
int check(ASDFParseState state);
}