## LibinsaneApi

LibinsaneApi

## Functions

const char * | libinsane_api_get_version ()
LibinsaneApi * | libinsane_api_new_safebet ()
LibinsaneApi * | libinsane_api_new_from_string ()
GList * | libinsane_api_list_devices ()
LibinsaneItem * | libinsane_api_get_device ()
void | libinsane_api_cleanup ()

## Types and Values

enum | LibinsaneDeviceLocations
#define | LIBINSANE_API_TYPE

## Description

## Functions

### libinsane_api_get_version ()

    const char *
    libinsane_api_get_version (void);

### libinsane_api_new_safebet ()

    LibinsaneApi *
    libinsane_api_new_safebet (GError **error);

Instantiate the safest list of API for most cases. See lis_safebet

#### Returns

the new reference to `self` .

[transfer full]

### libinsane_api_new_from_string ()

    LibinsaneApi *
    libinsane_api_new_from_string (const char *desc,
                                   GError **error);

Instantiate a new list of API based on a provided string.

`param` desc see `lis_str2impls()`

#### Returns

the new reference to `self` .

[transfer full]

### libinsane_api_list_devices ()

    GList *
    libinsane_api_list_devices (LibinsaneApi *self,
                                LibinsaneDeviceLocations locations,
                                GError **error);

#### Returns

list of available devices (LibinsaneDeviceDescriptors objects).

[element-type Libinsane.DeviceDescriptor][transfer full]

### libinsane_api_get_device ()

    LibinsaneItem *
    libinsane_api_get_device (LibinsaneApi *self,
                              const char *dev_id,
                              GError **error);

#### Returns

LibinsaneItem object.

[transfer full]

### libinsane_api_cleanup ()

    void
    libinsane_api_cleanup (LibinsaneApi *self);

## Types and Values

### enum LibinsaneDeviceLocations

#### Members

LIBINSANE_DEVICE_LOCATIONS_ANY |  |
LIBINSANE_DEVICE_LOCATIONS_LOCAL_ONLY |  |

### LIBINSANE_API_TYPE

    #define             LIBINSANE_API_TYPE