libgphoto2 (libgphoto2): libgphoto2_port/libgphoto2_port/gphoto2-port-info-list.h Source File

Main Page | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

# gphoto2-port-info-list.h

    00001 /* gphoto2-port-info-list.h:
    00002  *
    00003  * Copyright © 2001 Lutz Müller <lutz@users.sf.net>
    00004  *
    00005  * This library is free software; you can redistribute it and/or
    00006  * modify it under the terms of the GNU Lesser General Public
    00007  * License as published by the Free Software Foundation; either
    00008  * version 2 of the License, or (at your option) any later version.
    00009  *
    00010  * This library is distributed in the hope that it will be useful,
    00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
    00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    00013  * Lesser General Public License for more details.
    00014  *
    00015  * You should have received a copy of the GNU Lesser General Public
    00016  * License along with this library; if not, write to the
    00017  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    00018  * Boston, MA 02111-1307, USA.
    00019  */
    00020
    00021 #ifndef __GPHOTO2_PORT_INFO_LIST_H__
    00022 #define __GPHOTO2_PORT_INFO_LIST_H__
    00023
    00024 typedef enum {
    00025         GP_PORT_NONE        =      0,
    00026         GP_PORT_SERIAL      = 1 << 0,
    00027         GP_PORT_USB         = 1 << 2,
    00028         GP_PORT_DISK        = 1 << 3,
    00029         GP_PORT_PTPIP       = 1 << 4
    00030 } GPPortType;
    00031
    00032 typedef struct _GPPortInfo GPPortInfo;
    00033 struct _GPPortInfo {
    00034         GPPortType type;
    00035         char name[64];
    00036         char path[64];
    00037
    00038         /* Private */
    00039         char library_filename[1024];
    00040 };
    00041
    00042 #include <gphoto2-port.h>
    00043
    00044 #ifdef __cplusplus
    00045 extern "C" {
    00046 #endif /* __cplusplus */
    00047
    00048 /* Internals are private */
    00049 typedef struct _GPPortInfoList GPPortInfoList;
    00050
    00051 int gp_port_info_list_new  (GPPortInfoList **list);
    00052 int gp_port_info_list_free (GPPortInfoList *list);
    00053
    00054 int gp_port_info_list_append (GPPortInfoList *list, GPPortInfo info);
    00055
    00056 int gp_port_info_list_load (GPPortInfoList *list);
    00057
    00058 int gp_port_info_list_count (GPPortInfoList *list);
    00059
    00060 int gp_port_info_list_lookup_path (GPPortInfoList *list, const char *path);
    00061 int gp_port_info_list_lookup_name (GPPortInfoList *list, const char *name);
    00062
    00063 int gp_port_info_list_get_info (GPPortInfoList *list, int n, GPPortInfo *info);
    00064
    00065 const char *gp_port_message_codeset (const char*);
    00066
    00067 /* DEPRECATED */
    00068 typedef GPPortInfo gp_port_info;
    00069
    00070 #ifdef __cplusplus
    00071 }
    00072 #endif /* __cplusplus */
    00073
    00074 #endif /* __GPHOTO2_PORT_INFO_LIST_H__ */