All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.pkl.thirdparty.commonmark.parser.block.ParserState Maven / Gradle / Ivy

Go to download

Fat Jar containing pkl-cli, pkl-codegen-java, pkl-codegen-kotlin, pkl-config-java, pkl-core, pkl-doc, and their shaded third-party dependencies.

There is a newer version: 0.27.1
Show newest version
package org.pkl.thirdparty.commonmark.parser.block;

import org.pkl.thirdparty.commonmark.parser.SourceLine;

/**
 * State of the parser that is used in block parsers.
 * 

This interface is not intended to be implemented by clients.

*/ public interface ParserState { /** * @return the current source line being parsed (full line) */ SourceLine getLine(); /** * @return the current index within the line (0-based) */ int getIndex(); /** * @return the index of the next non-space character starting from {@link #getIndex()} (may be the same) (0-based) */ int getNextNonSpaceIndex(); /** * The column is the position within the line after tab characters have been processed as 4-space tab stops. * If the line doesn't contain any tabs, it's the same as the {@link #getIndex()}. If the line starts with a tab, * followed by text, then the column for the first character of the text is 4 (the index is 1). * * @return the current column within the line (0-based) */ int getColumn(); /** * @return the indentation in columns (either by spaces or tab stop of 4), starting from {@link #getColumn()} */ int getIndent(); /** * @return true if the current line is blank starting from the index */ boolean isBlank(); /** * @return the deepest open block parser */ BlockParser getActiveBlockParser(); }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy