# encoding: utf-8
# module pyexpat
# from /usr/lib/python3.4/lib-dynload/pyexpat.cpython-34m.so
# by generator 1.135
""" Python wrapper for Expat parser. """

# imports
import pyexpat.errors as errors # <module 'pyexpat.errors'>
import pyexpat.model as model # <module 'pyexpat.model'>

# Variables with simple values

EXPAT_VERSION = 'expat_2.1.0'

native_encoding = 'UTF-8'

XML_PARAM_ENTITY_PARSING_ALWAYS = 2
XML_PARAM_ENTITY_PARSING_NEVER = 0

XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE = 1

# functions

def ErrorString(errno): # real signature unknown; restored from __doc__
    """
    ErrorString(errno) -> string
    Returns string error for given number.
    """
    return ""

def ParserCreate(encoding=None, namespace_separator=None): # real signature unknown; restored from __doc__
    """
    ParserCreate([encoding[, namespace_separator]]) -> parser
    Return a new XML parser object.
    """
    pass

# classes

from .Exception import Exception

class ExpatError(Exception):
    # no doc
    def __init__(self, *args, **kwargs): # real signature unknown
        pass

    __weakref__ = property(lambda self: object(), lambda self, v: None, lambda self: None)  # default
    """list of weak references to the object (if defined)"""



error = ExpatError


from .object import object

class XMLParserType(object):
    """ XML parser """
    def ExternalEntityParserCreate(self, context, encoding=None): # real signature unknown; restored from __doc__
        """
        ExternalEntityParserCreate(context[, encoding])
        Create a parser for parsing an external entity based on the
        information passed to the ExternalEntityRefHandler.
        """
        pass

    def GetBase(self): # real signature unknown; restored from __doc__
        """
        GetBase() -> url
        Return base URL string for the parser.
        """
        pass

    def GetInputContext(self): # real signature unknown; restored from __doc__
        """
        GetInputContext() -> string
        Return the untranslated text of the input that caused the current event.
        If the event was generated by a large amount of text (such as a start tag
        for an element with many attributes), not all of the text may be available.
        """
        return ""

    def Parse(self, data, isfinal=None): # real signature unknown; restored from __doc__
        """
        Parse(data[, isfinal])
        Parse XML data.  `isfinal' should be true at end of input.
        """
        pass

    def ParseFile(self, file): # real signature unknown; restored from __doc__
        """
        ParseFile(file)
        Parse XML data from file-like object.
        """
        pass

    def SetBase(self, base_url): # real signature unknown; restored from __doc__
        """
        SetBase(base_url)
        Set the base URL for the parser.
        """
        pass

    def SetParamEntityParsing(self, flag): # real signature unknown; restored from __doc__
        """
        SetParamEntityParsing(flag) -> success
        Controls parsing of parameter entities (including the external DTD
        subset). Possible flag values are XML_PARAM_ENTITY_PARSING_NEVER,
        XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE and
        XML_PARAM_ENTITY_PARSING_ALWAYS. Returns true if setting the flag
        was successful.
        """
        pass

    def UseForeignDTD(self, flag=None): # real signature unknown; restored from __doc__
        """
        UseForeignDTD([flag])
        Allows the application to provide an artificial external subset if one is
        not specified as part of the document instance.  This readily allows the
        use of a 'default' document type controlled by the application, while still
        getting the advantage of providing document type information to the parser.
        'flag' defaults to True if not provided.
        """
        pass

    def __delattr__(self, *args, **kwargs): # real signature unknown
        """ Implement delattr(self, name). """
        pass

    def __dir__(self, *args, **kwargs): # real signature unknown
        pass

    def __getattribute__(self, *args, **kwargs): # real signature unknown
        """ Return getattr(self, name). """
        pass

    def __init__(self, *args, **kwargs): # real signature unknown
        pass

    def __setattr__(self, *args, **kwargs): # real signature unknown
        """ Implement setattr(self, name, value). """
        pass


# variables with complex values

expat_CAPI = None # (!) real value is ''

features = [
    (
        'sizeof(XML_Char)',
        1,
    ),
    (
        'sizeof(XML_LChar)',
        1,
    ),
    (
        'XML_DTD',
        0,
    ),
    (
        'XML_CONTEXT_BYTES',
        1024,
    ),
    (
        'XML_NS',
        0,
    ),
]

version_info = (
    2,
    1,
    0,
)

__loader__ = None # (!) real value is ''

__spec__ = None # (!) real value is ''

