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

it.unibo.tuprolog.parser.PrologLexer.kt Maven / Gradle / Ivy

Go to download

Internal, JS-specific implementation of a Prolog syntax parser supporting dynamic operators definition

There is a newer version: 1.0.4
Show newest version
@file:JsModule("@tuprolog/parser-utils")
@file:JsNonModule

package it.unibo.tuprolog.parser

external class PrologLexer(input: dynamic) {

    fun addOperators(vararg operators: String)
    fun getOperators(): Array
    fun isOperator(string: String): Boolean
    fun unquote(string: String): String
    fun escape(string: String, stringType: StringType): String
    fun getAllTokens(): Array

    fun addErrorListener(listener: dynamic)
    fun removeErrorListeners()

    companion object {
        val grammarFileName: String
        val ruleNames: Array
        val symbolicNames: Array
        val literalNames: Array
        val channelNames: Array
        val modeNames: Array

        val EOF: Int
        val VARIABLE: Int
        val INTEGER: Int
        val HEX: Int
        val OCT: Int
        val BINARY: Int
        val SIGN: Int
        val FLOAT: Int
        val CHAR: Int
        val BOOL: Int
        val LPAR: Int
        val RPAR: Int
        val LSQUARE: Int
        val RSQUARE: Int
        val EMPTY_LIST: Int
        val LBRACE: Int
        val RBRACE: Int
        val EMPTY_SET: Int
        val SQ_STRING: Int
        val DQ_STRING: Int
        val COMMA: Int
        val PIPE: Int
        val CUT: Int
        val FULL_STOP: Int
        val WHITE_SPACES: Int
        val COMMENT: Int
        val LINE_COMMENT: Int
        val OPERATOR: Int
        val ATOM: Int
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy