'''Wrapper for segment.h

Generated with:
./ctypesgen.py --cpp gcc -E -I/c/OSGeo4W/include -I/c/OSGeo4W/apps/msys/include      -I/c/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include -I/c/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include -D__GLIBC_HAVE_LONG_LONG -lgrass_segment.7.0.1 c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/segment.h c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h -o OBJ.i686-pc-mingw32/segment.py

Do not modify this file.
'''

__docformat__ =  'restructuredtext'


_libs = {}
_libdirs = []

from ctypes_preamble import *
from ctypes_preamble import _variadic_function
from ctypes_loader import *

add_library_search_dirs([])

# Begin libraries

_libs["grass_segment.7.0.1"] = load_library("grass_segment.7.0.1")

# 1 libraries
# End libraries

# No modules

# c:\\osgeo4w\\usr\\src\\grass701\\dist.i686-pc-mingw32\\include\\grass\\segment.h: 14
class struct_aq(Structure):
    pass

struct_aq.__slots__ = [
    'cur',
    'younger',
    'older',
]
struct_aq._fields_ = [
    ('cur', c_int),
    ('younger', POINTER(struct_aq)),
    ('older', POINTER(struct_aq)),
]

# c:\\osgeo4w\\usr\\src\\grass701\\dist.i686-pc-mingw32\\include\\grass\\segment.h: 45
class struct_scb(Structure):
    pass

struct_scb.__slots__ = [
    'buf',
    'dirty',
    'age',
    'n',
]
struct_scb._fields_ = [
    ('buf', String),
    ('dirty', c_char),
    ('age', POINTER(struct_aq)),
    ('n', c_int),
]

# c:\\osgeo4w\\usr\\src\\grass701\\dist.i686-pc-mingw32\\include\\grass\\segment.h: 61
class struct_anon_6(Structure):
    pass

struct_anon_6.__slots__ = [
    'open',
    'nrows',
    'ncols',
    'len',
    'srows',
    'scols',
    'srowscols',
    'size',
    'spr',
    'spill',
    'fast_adrs',
    'scolbits',
    'srowbits',
    'segbits',
    'fast_seek',
    'lenbits',
    'sizebits',
    'address',
    'seek',
    'fname',
    'fd',
    'scb',
    'load_idx',
    'nfreeslots',
    'freeslot',
    'agequeue',
    'youngest',
    'oldest',
    'nseg',
    'cur',
    'offset',
]
struct_anon_6._fields_ = [
    ('open', c_int),
    ('nrows', c_int64),
    ('ncols', c_int64),
    ('len', c_int),
    ('srows', c_int),
    ('scols', c_int),
    ('srowscols', c_int),
    ('size', c_int),
    ('spr', c_int),
    ('spill', c_int),
    ('fast_adrs', c_int),
    ('scolbits', c_int64),
    ('srowbits', c_int64),
    ('segbits', c_int64),
    ('fast_seek', c_int),
    ('lenbits', c_int),
    ('sizebits', c_int),
    ('address', CFUNCTYPE(UNCHECKED(c_int), )),
    ('seek', CFUNCTYPE(UNCHECKED(c_int), )),
    ('fname', String),
    ('fd', c_int),
    ('scb', POINTER(struct_scb)),
    ('load_idx', POINTER(c_int)),
    ('nfreeslots', c_int),
    ('freeslot', POINTER(c_int)),
    ('agequeue', POINTER(struct_aq)),
    ('youngest', POINTER(struct_aq)),
    ('oldest', POINTER(struct_aq)),
    ('nseg', c_int),
    ('cur', c_int),
    ('offset', c_int),
]

SEGMENT = struct_anon_6 # c:\\osgeo4w\\usr\\src\\grass701\\dist.i686-pc-mingw32\\include\\grass\\segment.h: 61

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 4
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_open'):
    Segment_open = _libs['grass_segment.7.0.1'].Segment_open
    Segment_open.restype = c_int
    Segment_open.argtypes = [POINTER(SEGMENT), String, c_int64, c_int64, c_int, c_int, c_int, c_int]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 5
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_close'):
    Segment_close = _libs['grass_segment.7.0.1'].Segment_close
    Segment_close.restype = c_int
    Segment_close.argtypes = [POINTER(SEGMENT)]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 6
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_flush'):
    Segment_flush = _libs['grass_segment.7.0.1'].Segment_flush
    Segment_flush.restype = c_int
    Segment_flush.argtypes = [POINTER(SEGMENT)]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 7
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_format'):
    Segment_format = _libs['grass_segment.7.0.1'].Segment_format
    Segment_format.restype = c_int
    Segment_format.argtypes = [c_int, c_int64, c_int64, c_int, c_int, c_int]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 8
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_format_nofill'):
    Segment_format_nofill = _libs['grass_segment.7.0.1'].Segment_format_nofill
    Segment_format_nofill.restype = c_int
    Segment_format_nofill.argtypes = [c_int, c_int64, c_int64, c_int, c_int, c_int]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 9
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_get'):
    Segment_get = _libs['grass_segment.7.0.1'].Segment_get
    Segment_get.restype = c_int
    Segment_get.argtypes = [POINTER(SEGMENT), POINTER(None), c_int64, c_int64]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 10
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_get_row'):
    Segment_get_row = _libs['grass_segment.7.0.1'].Segment_get_row
    Segment_get_row.restype = c_int
    Segment_get_row.argtypes = [POINTER(SEGMENT), POINTER(None), c_int64]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 11
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_init'):
    Segment_init = _libs['grass_segment.7.0.1'].Segment_init
    Segment_init.restype = c_int
    Segment_init.argtypes = [POINTER(SEGMENT), c_int, c_int]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 12
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_put'):
    Segment_put = _libs['grass_segment.7.0.1'].Segment_put
    Segment_put.restype = c_int
    Segment_put.argtypes = [POINTER(SEGMENT), POINTER(None), c_int64, c_int64]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 13
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_put_row'):
    Segment_put_row = _libs['grass_segment.7.0.1'].Segment_put_row
    Segment_put_row.restype = c_int
    Segment_put_row.argtypes = [POINTER(SEGMENT), POINTER(None), c_int64]

# c:/osgeo4w/usr/src/grass701/dist.i686-pc-mingw32/include/grass/defs/segment.h: 14
if hasattr(_libs['grass_segment.7.0.1'], 'Segment_release'):
    Segment_release = _libs['grass_segment.7.0.1'].Segment_release
    Segment_release.restype = c_int
    Segment_release.argtypes = [POINTER(SEGMENT)]

aq = struct_aq # c:\\osgeo4w\\usr\\src\\grass701\\dist.i686-pc-mingw32\\include\\grass\\segment.h: 14

scb = struct_scb # c:\\osgeo4w\\usr\\src\\grass701\\dist.i686-pc-mingw32\\include\\grass\\segment.h: 45

# No inserted files

