# This file was automatically generated by SWIG (http://www.swig.org).
# Version 4.0.2
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.

from sys import version_info as _swig_python_version_info
if _swig_python_version_info < (2, 7, 0):
    raise RuntimeError("Python 2.7 or later required")

# Import the low-level C/C++ module
if __package__ or "." in __name__:
    from . import _clinkgrammar
else:
    import _clinkgrammar

try:
    import builtins as __builtin__
except ImportError:
    import __builtin__

def _swig_repr(self):
    try:
        strthis = "proxy of " + self.this.__repr__()
    except __builtin__.Exception:
        strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)


def _swig_setattr_nondynamic_instance_variable(set):
    def set_instance_attr(self, name, value):
        if name == "thisown":
            self.this.own(value)
        elif name == "this":
            set(self, name, value)
        elif hasattr(self, name) and isinstance(getattr(type(self), name), property):
            set(self, name, value)
        else:
            raise AttributeError("You cannot add instance attributes to %s" % self)
    return set_instance_attr


def _swig_setattr_nondynamic_class_variable(set):
    def set_class_attr(cls, name, value):
        if hasattr(cls, name) and not isinstance(getattr(cls, name), property):
            set(cls, name, value)
        else:
            raise AttributeError("You cannot add class attributes to %s" % cls)
    return set_class_attr


def _swig_add_metaclass(metaclass):
    """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass"""
    def wrapper(cls):
        return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy())
    return wrapper


class _SwigNonDynamicMeta(type):
    """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
    __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)


class Parse_Options(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _clinkgrammar.delete_Parse_Options

# Register Parse_Options in _clinkgrammar:
_clinkgrammar.Parse_Options_swigregister(Parse_Options)

class Exp(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _clinkgrammar.delete_Exp

    def __repr__(self):
       return lg_exp_stringify(self)


# Register Exp in _clinkgrammar:
_clinkgrammar.Exp_swigregister(Exp)


def lg_exp_resolve(*args) -> "Exp *":
    return _clinkgrammar.lg_exp_resolve(*args)

def linkgrammar_get_version() -> "char const *":
    return _clinkgrammar.linkgrammar_get_version()

def linkgrammar_get_dict_version(arg1: "Dictionary") -> "char const *":
    return _clinkgrammar.linkgrammar_get_dict_version(arg1)

def linkgrammar_get_configuration() -> "char const *":
    return _clinkgrammar.linkgrammar_get_configuration()

def linkgrammar_get_dict_locale(arg1: "Dictionary") -> "char const *":
    return _clinkgrammar.linkgrammar_get_dict_locale(arg1)

def linkgrammar_get_dict_max_disjunct_cost(arg1: "Dictionary") -> "double":
    return _clinkgrammar.linkgrammar_get_dict_max_disjunct_cost(arg1)
LG_PANIC_DISJUNCT_COST = _clinkgrammar.LG_PANIC_DISJUNCT_COST

def linkgrammar_get_dict_define(arg1: "Dictionary", arg2: "char const *") -> "char const *":
    return _clinkgrammar.linkgrammar_get_dict_define(arg1, arg2)
lg_Fatal = _clinkgrammar.lg_Fatal
lg_Error = _clinkgrammar.lg_Error
lg_Warn = _clinkgrammar.lg_Warn
lg_Info = _clinkgrammar.lg_Info
lg_Debug = _clinkgrammar.lg_Debug
lg_Trace = _clinkgrammar.lg_Trace
lg_None = _clinkgrammar.lg_None
class lg_errinfo(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr
    severity = property(_clinkgrammar.lg_errinfo_severity_get)
    severity_label = property(_clinkgrammar.lg_errinfo_severity_label_get)
    text = property(_clinkgrammar.lg_errinfo_text_get)

    def formatmsg(self):
        return _lg_error_formatmsg(self)
    __swig_destroy__ = _clinkgrammar.delete_lg_errinfo
    __del__ = lambda self: None


    def __init__(self):
        _clinkgrammar.lg_errinfo_swiginit(self, _clinkgrammar.new_lg_errinfo())

# Register lg_errinfo in _clinkgrammar:
_clinkgrammar.lg_errinfo_swigregister(lg_errinfo)


def lg_error_set_handler(arg1: "lg_error_handler", data: "void *") -> "lg_error_handler":
    return _clinkgrammar.lg_error_set_handler(arg1, data)

def _lg_error_formatmsg(lge: "lg_errinfo") -> "char *":
    return _clinkgrammar._lg_error_formatmsg(lge)

def lg_error_printall(arg1: "lg_error_handler", data: "void *") -> "int":
    return _clinkgrammar.lg_error_printall(arg1, data)

def lg_error_clearall() -> "int":
    return _clinkgrammar.lg_error_clearall()

def lg_error_flush() -> "int":
    return _clinkgrammar.lg_error_flush()

def dictionary_create_lang(lang: "char const *") -> "Dictionary":
    return _clinkgrammar.dictionary_create_lang(lang)

def dictionary_get_lang(arg1: "Dictionary") -> "char const *":
    return _clinkgrammar.dictionary_get_lang(arg1)

def dictionary_delete(arg1: "Dictionary") -> "void":
    return _clinkgrammar.dictionary_delete(arg1)

def dictionary_set_data_dir(path: "char const *") -> "void":
    return _clinkgrammar.dictionary_set_data_dir(path)

def dictionary_get_data_dir() -> "char *":
    return _clinkgrammar.dictionary_get_data_dir()

def linkgrammar_open_data_file(arg1: "char const *") -> "FILE *":
    return _clinkgrammar.linkgrammar_open_data_file(arg1)
VDAL = _clinkgrammar.VDAL

def parse_options_create() -> "Parse_Options":
    return _clinkgrammar.parse_options_create()

def parse_options_delete(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_delete(opts)

def parse_options_set_verbosity(opts: "Parse_Options", verbosity: "int") -> "void":
    return _clinkgrammar.parse_options_set_verbosity(opts, verbosity)

def parse_options_get_verbosity(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_verbosity(opts)

def parse_options_set_debug(opts: "Parse_Options", debug: "char const *") -> "void":
    return _clinkgrammar.parse_options_set_debug(opts, debug)

def parse_options_get_debug(opts: "Parse_Options") -> "char *":
    return _clinkgrammar.parse_options_get_debug(opts)

def parse_options_set_test(opts: "Parse_Options", test: "char const *") -> "void":
    return _clinkgrammar.parse_options_set_test(opts, test)

def parse_options_get_test(opts: "Parse_Options") -> "char *":
    return _clinkgrammar.parse_options_get_test(opts)

def parse_options_set_linkage_limit(opts: "Parse_Options", linkage_limit: "int") -> "void":
    return _clinkgrammar.parse_options_set_linkage_limit(opts, linkage_limit)

def parse_options_get_linkage_limit(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_linkage_limit(opts)

def parse_options_set_disjunct_cost(opts: "Parse_Options", disjunct_cost: "double") -> "void":
    return _clinkgrammar.parse_options_set_disjunct_cost(opts, disjunct_cost)

def parse_options_get_disjunct_cost(opts: "Parse_Options") -> "double":
    return _clinkgrammar.parse_options_get_disjunct_cost(opts)

def parse_options_set_min_null_count(opts: "Parse_Options", null_count: "int") -> "void":
    return _clinkgrammar.parse_options_set_min_null_count(opts, null_count)

def parse_options_get_min_null_count(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_min_null_count(opts)

def parse_options_set_max_null_count(opts: "Parse_Options", null_count: "int") -> "void":
    return _clinkgrammar.parse_options_set_max_null_count(opts, null_count)

def parse_options_get_max_null_count(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_max_null_count(opts)

def parse_options_set_islands_ok(opts: "Parse_Options", islands_ok: "int") -> "void":
    return _clinkgrammar.parse_options_set_islands_ok(opts, islands_ok)

def parse_options_get_islands_ok(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_islands_ok(opts)

def parse_options_set_spell_guess(opts: "Parse_Options", spell_guess: "int") -> "void":
    return _clinkgrammar.parse_options_set_spell_guess(opts, spell_guess)

def parse_options_get_spell_guess(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_spell_guess(opts)

def parse_options_set_short_length(opts: "Parse_Options", short_length: "int") -> "void":
    return _clinkgrammar.parse_options_set_short_length(opts, short_length)

def parse_options_get_short_length(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_short_length(opts)

def parse_options_set_max_parse_time(opts: "Parse_Options", secs: "int") -> "void":
    return _clinkgrammar.parse_options_set_max_parse_time(opts, secs)

def parse_options_get_max_parse_time(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_max_parse_time(opts)

def parse_options_set_cost_model_type(opts: "Parse_Options", cm: "Cost_Model_type") -> "void":
    return _clinkgrammar.parse_options_set_cost_model_type(opts, cm)

def parse_options_get_cost_model_type(opts: "Parse_Options") -> "Cost_Model_type":
    return _clinkgrammar.parse_options_get_cost_model_type(opts)

def parse_options_set_perform_pp_prune(opts: "Parse_Options", pp_prune: "int") -> "void":
    return _clinkgrammar.parse_options_set_perform_pp_prune(opts, pp_prune)

def parse_options_get_perform_pp_prune(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_perform_pp_prune(opts)

def parse_options_set_use_sat_parser(opts: "Parse_Options", use_sat_solver: "int") -> "void":
    return _clinkgrammar.parse_options_set_use_sat_parser(opts, use_sat_solver)

def parse_options_get_use_sat_parser(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_use_sat_parser(opts)

def parse_options_timer_expired(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_timer_expired(opts)

def parse_options_set_all_short_connectors(opts: "Parse_Options", val: "int") -> "void":
    return _clinkgrammar.parse_options_set_all_short_connectors(opts, val)

def parse_options_get_all_short_connectors(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_all_short_connectors(opts)

def parse_options_set_repeatable_rand(opts: "Parse_Options", val: "int") -> "void":
    return _clinkgrammar.parse_options_set_repeatable_rand(opts, val)

def parse_options_get_repeatable_rand(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_repeatable_rand(opts)

def parse_options_reset_resources(opts: "Parse_Options") -> "void":
    return _clinkgrammar.parse_options_reset_resources(opts)

def parse_options_get_dialect(opts: "Parse_Options") -> "char *":
    return _clinkgrammar.parse_options_get_dialect(opts)

def parse_options_set_dialect(opts: "Parse_Options", dialect: "char const *") -> "void":
    return _clinkgrammar.parse_options_set_dialect(opts, dialect)
NO_DISPLAY = _clinkgrammar.NO_DISPLAY
MULTILINE = _clinkgrammar.MULTILINE
BRACKET_TREE = _clinkgrammar.BRACKET_TREE
SINGLE_LINE = _clinkgrammar.SINGLE_LINE
MAX_STYLES = _clinkgrammar.MAX_STYLES

def parse_options_set_display_morphology(opts: "Parse_Options", val: "int") -> "void":
    return _clinkgrammar.parse_options_set_display_morphology(opts, val)

def parse_options_get_display_morphology(opts: "Parse_Options") -> "int":
    return _clinkgrammar.parse_options_get_display_morphology(opts)

def sentence_create(input_string: "char const *", dict: "Dictionary") -> "Sentence":
    return _clinkgrammar.sentence_create(input_string, dict)

def sentence_delete(sent: "Sentence") -> "void":
    return _clinkgrammar.sentence_delete(sent)

def sentence_split(sent: "Sentence", opts: "Parse_Options") -> "int":
    return _clinkgrammar.sentence_split(sent, opts)

def sentence_parse(sent: "Sentence", opts: "Parse_Options") -> "int":
    return _clinkgrammar.sentence_parse(sent, opts)

def sentence_length(sent: "Sentence") -> "int":
    return _clinkgrammar.sentence_length(sent)

def sentence_null_count(sent: "Sentence") -> "int":
    return _clinkgrammar.sentence_null_count(sent)

def sentence_num_linkages_found(sent: "Sentence") -> "int":
    return _clinkgrammar.sentence_num_linkages_found(sent)

def sentence_num_valid_linkages(sent: "Sentence") -> "int":
    return _clinkgrammar.sentence_num_valid_linkages(sent)

def sentence_num_linkages_post_processed(sent: "Sentence") -> "int":
    return _clinkgrammar.sentence_num_linkages_post_processed(sent)

def sentence_num_violations(sent: "Sentence", linkage_num: "LinkageIdx") -> "int":
    return _clinkgrammar.sentence_num_violations(sent, linkage_num)

def sentence_disjunct_cost(sent: "Sentence", linkage_num: "LinkageIdx") -> "double":
    return _clinkgrammar.sentence_disjunct_cost(sent, linkage_num)

def sentence_link_cost(sent: "Sentence", linkage_num: "LinkageIdx") -> "int":
    return _clinkgrammar.sentence_link_cost(sent, linkage_num)

def sentence_display_wordgraph(sent: "Sentence", modestr: "char const *") -> "int":
    return _clinkgrammar.sentence_display_wordgraph(sent, modestr)

def linkage_create(linkage_num: "LinkageIdx", sent: "Sentence", opts: "Parse_Options") -> "Linkage":
    return _clinkgrammar.linkage_create(linkage_num, sent, opts)

def linkage_delete(linkage: "Linkage") -> "void":
    return _clinkgrammar.linkage_delete(linkage)

def linkage_get_num_words(linkage: "Linkage const") -> "size_t":
    return _clinkgrammar.linkage_get_num_words(linkage)

def linkage_get_num_links(linkage: "Linkage const") -> "size_t":
    return _clinkgrammar.linkage_get_num_links(linkage)

def linkage_get_link_lword(linkage: "Linkage const", index: "LinkIdx") -> "WordIdx":
    return _clinkgrammar.linkage_get_link_lword(linkage, index)

def linkage_get_link_rword(linkage: "Linkage const", index: "LinkIdx") -> "WordIdx":
    return _clinkgrammar.linkage_get_link_rword(linkage, index)

def linkage_get_link_length(linkage: "Linkage const", index: "LinkIdx") -> "int":
    return _clinkgrammar.linkage_get_link_length(linkage, index)

def linkage_get_link_label(linkage: "Linkage const", index: "LinkIdx") -> "char const *":
    return _clinkgrammar.linkage_get_link_label(linkage, index)

def linkage_get_link_llabel(linkage: "Linkage const", index: "LinkIdx") -> "char const *":
    return _clinkgrammar.linkage_get_link_llabel(linkage, index)

def linkage_get_link_rlabel(linkage: "Linkage const", index: "LinkIdx") -> "char const *":
    return _clinkgrammar.linkage_get_link_rlabel(linkage, index)

def linkage_get_link_num_domains(linkage: "Linkage const", index: "LinkIdx") -> "int":
    return _clinkgrammar.linkage_get_link_num_domains(linkage, index)

def linkage_get_link_domain_names(linkage: "Linkage const", index: "LinkIdx") -> "char const **":
    return _clinkgrammar.linkage_get_link_domain_names(linkage, index)

def linkage_get_words(linkage: "Linkage const") -> "char const **":
    return _clinkgrammar.linkage_get_words(linkage)

def linkage_get_disjunct_str(linkage: "Linkage const", word_num: "WordIdx") -> "char const *":
    return _clinkgrammar.linkage_get_disjunct_str(linkage, word_num)

def linkage_get_disjunct_cost(linkage: "Linkage const", word_num: "WordIdx") -> "double":
    return _clinkgrammar.linkage_get_disjunct_cost(linkage, word_num)

def linkage_get_word(linkage: "Linkage const", word_num: "WordIdx") -> "char const *":
    return _clinkgrammar.linkage_get_word(linkage, word_num)

def linkage_print_constituent_tree(linkage: "Linkage", mode: "ConstituentDisplayStyle") -> "char *":
    return _clinkgrammar.linkage_print_constituent_tree(linkage, mode)

def linkage_free_constituent_tree_str(str: "char *") -> "void":
    return _clinkgrammar.linkage_free_constituent_tree_str(str)

def linkage_print_diagram(linkage: "Linkage const", display_walls: "int", screen_width: "size_t") -> "char *":
    return _clinkgrammar.linkage_print_diagram(linkage, display_walls, screen_width)

def linkage_free_diagram(str: "char *") -> "void":
    return _clinkgrammar.linkage_free_diagram(str)

def linkage_print_postscript(linkage: "Linkage const", display_walls: "int", print_ps_header: "int") -> "char *":
    return _clinkgrammar.linkage_print_postscript(linkage, display_walls, print_ps_header)

def linkage_free_postscript(str: "char *") -> "void":
    return _clinkgrammar.linkage_free_postscript(str)

def linkage_print_disjuncts(linkage: "Linkage const") -> "char *":
    return _clinkgrammar.linkage_print_disjuncts(linkage)

def linkage_free_disjuncts(str: "char *") -> "void":
    return _clinkgrammar.linkage_free_disjuncts(str)

def linkage_print_links_and_domains(linkage: "Linkage const") -> "char *":
    return _clinkgrammar.linkage_print_links_and_domains(linkage)

def linkage_free_links_and_domains(str: "char *") -> "void":
    return _clinkgrammar.linkage_free_links_and_domains(str)

def linkage_print_pp_msgs(linkage: "Linkage") -> "char *":
    return _clinkgrammar.linkage_print_pp_msgs(linkage)

def linkage_free_pp_msgs(str: "char *") -> "void":
    return _clinkgrammar.linkage_free_pp_msgs(str)

def linkage_unused_word_cost(linkage: "Linkage const") -> "int":
    return _clinkgrammar.linkage_unused_word_cost(linkage)

def linkage_disjunct_cost(linkage: "Linkage const") -> "double":
    return _clinkgrammar.linkage_disjunct_cost(linkage)

def linkage_link_cost(linkage: "Linkage const") -> "int":
    return _clinkgrammar.linkage_link_cost(linkage)

def linkage_get_violation_name(linkage: "Linkage const") -> "char const *":
    return _clinkgrammar.linkage_get_violation_name(linkage)

def linkage_get_word_byte_start(linkage: "Linkage const", w: "WordIdx") -> "WordIdx":
    return _clinkgrammar.linkage_get_word_byte_start(linkage, w)

def linkage_get_word_byte_end(linkage: "Linkage const", w: "WordIdx") -> "WordIdx":
    return _clinkgrammar.linkage_get_word_byte_end(linkage, w)

def linkage_get_word_char_start(linkage: "Linkage const", w: "WordIdx") -> "WordIdx":
    return _clinkgrammar.linkage_get_word_char_start(linkage, w)

def linkage_get_word_char_end(linkage: "Linkage const", w: "WordIdx") -> "WordIdx":
    return _clinkgrammar.linkage_get_word_char_end(linkage, w)

def utf8_strwidth(arg1: "char const *") -> "size_t":
    return _clinkgrammar.utf8_strwidth(arg1)

def dict_display_word_expr(dict: "Dictionary", arg2: "char const *", opts: "Parse_Options") -> "char *":
    return _clinkgrammar.dict_display_word_expr(dict, arg2, opts)

def dict_display_word_info(dict: "Dictionary", arg2: "char const *", opts: "Parse_Options") -> "char *":
    return _clinkgrammar.dict_display_word_info(dict, arg2, opts)

def parse_options_print_total_time(opts: "Parse_Options") -> "void":
    return _clinkgrammar.parse_options_print_total_time(opts)

def _prt_error(*args) -> "int":
    return _clinkgrammar._prt_error(*args)
LEFT_WALL_WORD = _clinkgrammar.LEFT_WALL_WORD
RIGHT_WALL_WORD = _clinkgrammar.RIGHT_WALL_WORD
UNKNOWN_WORD = _clinkgrammar.UNKNOWN_WORD
WILDCARD_WORD = _clinkgrammar.WILDCARD_WORD
MAX_WORD = _clinkgrammar.MAX_WORD
SUBSCRIPT_MARK = _clinkgrammar.SUBSCRIPT_MARK
SUBSCRIPT_DOT = _clinkgrammar.SUBSCRIPT_DOT

def dictionary_lookup_list(arg1: "Dictionary const", arg2: "char const *") -> "Dict_node *":
    return _clinkgrammar.dictionary_lookup_list(arg1, arg2)

def dictionary_lookup_wild(arg1: "Dictionary const", arg2: "char const *") -> "Dict_node *":
    return _clinkgrammar.dictionary_lookup_wild(arg1, arg2)

def free_lookup_list(arg1: "Dictionary const", arg2: "Dict_node_struct") -> "void":
    return _clinkgrammar.free_lookup_list(arg1, arg2)

def dictionary_get_categories(dict: "Dictionary const") -> "Category const *":
    return _clinkgrammar.dictionary_get_categories(dict)

def linkage_get_categories(linkage: "Linkage const", w: "WordIdx") -> "Category_cost const *":
    return _clinkgrammar.linkage_get_categories(linkage, w)

def sentence_unused_disjuncts(arg1: "Sentence") -> "Disjunct **":
    return _clinkgrammar.sentence_unused_disjuncts(arg1)

def disjunct_expression(arg1: "Disjunct *") -> "char *":
    return _clinkgrammar.disjunct_expression(arg1)

def disjunct_categories(arg1: "Disjunct *") -> "Category_cost const *":
    return _clinkgrammar.disjunct_categories(arg1)

def dictionary_word_is_known(dict: "Dictionary const", word: "char const *") -> "int":
    return _clinkgrammar.dictionary_word_is_known(dict, word)
OR_type = _clinkgrammar.OR_type
AND_type = _clinkgrammar.AND_type
CONNECTOR_type = _clinkgrammar.CONNECTOR_type
class Category(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr
    num_words = property(_clinkgrammar.Category_num_words_get)
    name = property(_clinkgrammar.Category_name_get)
    exp = property(_clinkgrammar.Category_exp_get)
    word = property(_clinkgrammar.Category_word_get)

    def __init__(self):
        _clinkgrammar.Category_swiginit(self, _clinkgrammar.new_Category())
    __swig_destroy__ = _clinkgrammar.delete_Category

# Register Category in _clinkgrammar:
_clinkgrammar.Category_swigregister(Category)

class Category_cost(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr
    num = property(_clinkgrammar.Category_cost_num_get)
    cost = property(_clinkgrammar.Category_cost_cost_get)

    def __init__(self):
        _clinkgrammar.Category_cost_swiginit(self, _clinkgrammar.new_Category_cost())
    __swig_destroy__ = _clinkgrammar.delete_Category_cost

# Register Category_cost in _clinkgrammar:
_clinkgrammar.Category_cost_swigregister(Category_cost)


def lg_exp_get_type(exp: "Exp") -> "Exp_type":
    return _clinkgrammar.lg_exp_get_type(exp)

def lg_exp_get_dir(exp: "Exp") -> "char":
    return _clinkgrammar.lg_exp_get_dir(exp)

def lg_exp_get_multi(exp: "Exp") -> "int":
    return _clinkgrammar.lg_exp_get_multi(exp)

def lg_exp_get_cost(exp: "Exp") -> "double":
    return _clinkgrammar.lg_exp_get_cost(exp)

def lg_exp_operand_first(exp: "Exp") -> "Exp const *":
    return _clinkgrammar.lg_exp_operand_first(exp)

def lg_exp_operand_next(exp: "Exp") -> "Exp const *":
    return _clinkgrammar.lg_exp_operand_next(exp)

def lg_exp_get_string(arg1: "Exp") -> "char const *":
    return _clinkgrammar.lg_exp_get_string(arg1)

def lg_exp_stringify(arg1: "Exp") -> "char *":
    return _clinkgrammar.lg_exp_stringify(arg1)
class Dict_node_struct(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr
    string = property(_clinkgrammar.Dict_node_struct_string_get)
    file = property(_clinkgrammar.Dict_node_struct_file_get)
    exp = property(_clinkgrammar.Dict_node_struct_exp_get)

    def __init__(self):
        _clinkgrammar.Dict_node_struct_swiginit(self, _clinkgrammar.new_Dict_node_struct())
    __swig_destroy__ = _clinkgrammar.delete_Dict_node_struct

# Register Dict_node_struct in _clinkgrammar:
_clinkgrammar.Dict_node_struct_swigregister(Dict_node_struct)


def _py_error_default_handler(eh_lge: "lg_errinfo", pedh_data: "int *") -> "void":
    return _clinkgrammar._py_error_default_handler(eh_lge, pedh_data)

def _py_error_set_handler(func_and_data: "PyObject *") -> "PyObject *":
    return _clinkgrammar._py_error_set_handler(func_and_data)

def _py_error_printall(func_and_data: "PyObject *") -> "PyObject *":
    return _clinkgrammar._py_error_printall(func_and_data)

def delete_lg_errinfo(lge: "lg_errinfo") -> "void":
    return _clinkgrammar.delete_lg_errinfo(lge)

def _py_incref(x: "PyObject *") -> "void":
    return _clinkgrammar._py_incref(x)

def _py_decref(x: "PyObject *") -> "void":
    return _clinkgrammar._py_decref(x)


