flickcurl.h | flickcurl.h | |||
---|---|---|---|---|
skipping to change at line 73 | skipping to change at line 73 | |||
#define FLICKCURL_DEPRECATED | #define FLICKCURL_DEPRECATED | |||
#else | #else | |||
#define FLICKCURL_DEPRECATED __attribute__((deprecated)) | #define FLICKCURL_DEPRECATED __attribute__((deprecated)) | |||
#endif | #endif | |||
#else | #else | |||
#define FLICKCURL_DEPRECATED | #define FLICKCURL_DEPRECATED | |||
#endif | #endif | |||
/** | /** | |||
* flickcurl_field_value_type: | * flickcurl_field_value_type: | |||
* @VALUE_TYPE_PHOTO_ID: photo ID | ||||
* @VALUE_TYPE_PHOTO_URI: photo URI | ||||
* @VALUE_TYPE_UNIXTIME: a unixtime | * @VALUE_TYPE_UNIXTIME: a unixtime | |||
* @VALUE_TYPE_BOOLEAN: boolean | * @VALUE_TYPE_BOOLEAN: boolean | |||
* @VALUE_TYPE_DATETIME: date time | * @VALUE_TYPE_DATETIME: date time | |||
* @VALUE_TYPE_FLOAT: floating point number | * @VALUE_TYPE_FLOAT: floating point number | |||
* @VALUE_TYPE_INTEGER: integer | * @VALUE_TYPE_INTEGER: integer | |||
* @VALUE_TYPE_STRING: string | * @VALUE_TYPE_STRING: string | |||
* @VALUE_TYPE_URI: URI | * @VALUE_TYPE_URI: URI | |||
* @VALUE_TYPE_PERSON_ID: person ID | * @VALUE_TYPE_PERSON_ID: person ID | |||
* @VALUE_TYPE_PHOTO_ID: internal | ||||
* @VALUE_TYPE_PHOTO_URI: internal | ||||
* @VALUE_TYPE_MEDIA_TYPE: internal | ||||
* @VALUE_TYPE_NONE: internal | * @VALUE_TYPE_NONE: internal | |||
* @VALUE_TYPE_LAST: internal offset to last in enum list | * @VALUE_TYPE_LAST: internal offset to last in enum list | |||
* | * | |||
* Field data types | * Field data types | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
VALUE_TYPE_NONE, /* empty field */ | VALUE_TYPE_NONE, /* empty field */ | |||
VALUE_TYPE_PHOTO_ID, /* internal */ | VALUE_TYPE_PHOTO_ID, /* internal */ | |||
VALUE_TYPE_PHOTO_URI, /* internal */ | VALUE_TYPE_PHOTO_URI, /* internal */ | |||
VALUE_TYPE_UNIXTIME, | VALUE_TYPE_UNIXTIME, | |||
VALUE_TYPE_BOOLEAN, | VALUE_TYPE_BOOLEAN, | |||
VALUE_TYPE_DATETIME, | VALUE_TYPE_DATETIME, | |||
VALUE_TYPE_FLOAT, | VALUE_TYPE_FLOAT, | |||
VALUE_TYPE_INTEGER, | VALUE_TYPE_INTEGER, | |||
VALUE_TYPE_STRING, | VALUE_TYPE_STRING, | |||
VALUE_TYPE_URI, | VALUE_TYPE_URI, | |||
VALUE_TYPE_PERSON_ID, /* internal */ | VALUE_TYPE_PERSON_ID, /* internal */ | |||
VALUE_TYPE_LAST = VALUE_TYPE_PERSON_ID | VALUE_TYPE_MEDIA_TYPE, /* internal */ | |||
VALUE_TYPE_LAST = VALUE_TYPE_MEDIA_TYPE | ||||
} flickcurl_field_value_type; | } flickcurl_field_value_type; | |||
/** | /** | |||
* flickcurl_photo_field_type: | * flickcurl_photo_field_type: | |||
* @PHOTO_FIELD_dateuploaded: date uploaded | * @PHOTO_FIELD_dateuploaded: date uploaded | |||
* @PHOTO_FIELD_farm: farm number | * @PHOTO_FIELD_farm: farm number | |||
* @PHOTO_FIELD_isfavorite: is favorite boolean | * @PHOTO_FIELD_isfavorite: is favorite boolean | |||
* @PHOTO_FIELD_license: license | * @PHOTO_FIELD_license: license | |||
* @PHOTO_FIELD_originalformat: original format | * @PHOTO_FIELD_originalformat: original format | |||
* @PHOTO_FIELD_rotation: rotation | * @PHOTO_FIELD_rotation: rotation | |||
skipping to change at line 147 | skipping to change at line 149 | |||
* @PHOTO_FIELD_location_locality: location locality | * @PHOTO_FIELD_location_locality: location locality | |||
* @PHOTO_FIELD_location_county: location county | * @PHOTO_FIELD_location_county: location county | |||
* @PHOTO_FIELD_location_region: location region | * @PHOTO_FIELD_location_region: location region | |||
* @PHOTO_FIELD_location_country: location country | * @PHOTO_FIELD_location_country: location country | |||
* @PHOTO_FIELD_location_placeid: location place ID | * @PHOTO_FIELD_location_placeid: location place ID | |||
* @PHOTO_FIELD_neighborhood_placeid: neighborhood place ID | * @PHOTO_FIELD_neighborhood_placeid: neighborhood place ID | |||
* @PHOTO_FIELD_locality_placeid: locality place ID | * @PHOTO_FIELD_locality_placeid: locality place ID | |||
* @PHOTO_FIELD_county_placeid: county place ID | * @PHOTO_FIELD_county_placeid: county place ID | |||
* @PHOTO_FIELD_region_placeid: region place ID | * @PHOTO_FIELD_region_placeid: region place ID | |||
* @PHOTO_FIELD_country_placeid: country place ID | * @PHOTO_FIELD_country_placeid: country place ID | |||
* @PHOTO_FIELD_location_woeid: location WOE ID | ||||
* @PHOTO_FIELD_neighborhood_woeid: neighborhood WOE ID | ||||
* @PHOTO_FIELD_locality_woeid: locality WOE ID | ||||
* @PHOTO_FIELD_county_woeid: county WOE ID | ||||
* @PHOTO_FIELD_region_woeid: region WOE ID | ||||
* @PHOTO_FIELD_country_woeid: country WOE ID | ||||
* @PHOTO_FIELD_usage_candownload: can download | ||||
* @PHOTO_FIELD_usage_canblog: can blog | ||||
* @PHOTO_FIELD_usage_canprint: can print | ||||
* @PHOTO_FIELD_none: internal | * @PHOTO_FIELD_none: internal | |||
* @PHOTO_FIELD_FIRST: internal offset to first in enum list | * @PHOTO_FIELD_FIRST: internal offset to first in enum list | |||
* @PHOTO_FIELD_LAST: internal offset to last in enum list | * @PHOTO_FIELD_LAST: internal offset to last in enum list | |||
* | * | |||
* Fields of a flickcurl_photo* | * Fields of a flickcurl_photo* | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
PHOTO_FIELD_none, | PHOTO_FIELD_none, | |||
PHOTO_FIELD_dateuploaded, | PHOTO_FIELD_dateuploaded, | |||
PHOTO_FIELD_farm, | PHOTO_FIELD_farm, | |||
skipping to change at line 203 | skipping to change at line 214 | |||
PHOTO_FIELD_locality_placeid, | PHOTO_FIELD_locality_placeid, | |||
PHOTO_FIELD_county_placeid, | PHOTO_FIELD_county_placeid, | |||
PHOTO_FIELD_region_placeid, | PHOTO_FIELD_region_placeid, | |||
PHOTO_FIELD_country_placeid, | PHOTO_FIELD_country_placeid, | |||
PHOTO_FIELD_location_woeid, | PHOTO_FIELD_location_woeid, | |||
PHOTO_FIELD_neighborhood_woeid, | PHOTO_FIELD_neighborhood_woeid, | |||
PHOTO_FIELD_locality_woeid, | PHOTO_FIELD_locality_woeid, | |||
PHOTO_FIELD_county_woeid, | PHOTO_FIELD_county_woeid, | |||
PHOTO_FIELD_region_woeid, | PHOTO_FIELD_region_woeid, | |||
PHOTO_FIELD_country_woeid, | PHOTO_FIELD_country_woeid, | |||
PHOTO_FIELD_usage_candownload, | ||||
PHOTO_FIELD_usage_canblog, | ||||
PHOTO_FIELD_usage_canprint, | ||||
PHOTO_FIELD_FIRST = PHOTO_FIELD_dateuploaded, | PHOTO_FIELD_FIRST = PHOTO_FIELD_dateuploaded, | |||
PHOTO_FIELD_LAST = PHOTO_FIELD_country_woeid, | PHOTO_FIELD_LAST = PHOTO_FIELD_usage_canprint | |||
} flickcurl_photo_field_type; | } flickcurl_photo_field_type; | |||
/** | /** | |||
* @flickcurl: | * flickcurl: | |||
* | * | |||
* Flickcurl session object created by flickcurl_new() and destroyed by fli | * Flickcurl session object created by flickcurl_new() and destroyed | |||
ckcurl_free() | * by flickcurl_free() | |||
*/ | */ | |||
typedef struct flickcurl_s flickcurl; | typedef struct flickcurl_s flickcurl; | |||
/* Forward structure references */ | /* Forward structure references */ | |||
struct flickcurl_s; | struct flickcurl_s; | |||
struct flickcurl_photo_s; | struct flickcurl_photo_s; | |||
/** | /** | |||
* flickcurl_arg: | * flickcurl_arg: | |||
* @name: Argument name | * @name: Argument name | |||
skipping to change at line 374 | skipping to change at line 389 | |||
* @perm_comment: who can add comments to the photo and it's notes. one of: 0 nobody, 1 friends & family, 2 contacts, 3 everybody | * @perm_comment: who can add comments to the photo and it's notes. one of: 0 nobody, 1 friends & family, 2 contacts, 3 everybody | |||
* @perm_addmeta: who can add notes and tags to the photo. one of: 0 nobody / just the owner, 1 friends & family, 2 contacts, 3 everybody | * @perm_addmeta: who can add notes and tags to the photo. one of: 0 nobody / just the owner, 1 friends & family, 2 contacts, 3 everybody | |||
* | * | |||
* Permissions as used by flickcurl_photos_getPerms() and | * Permissions as used by flickcurl_photos_getPerms() and | |||
* flickcurl_photos_setPerms() which use public, friend, family, | * flickcurl_photos_setPerms() which use public, friend, family, | |||
* perm_comment and perm-addmeta. flickr.photos.geo.setPerms() uses | * perm_comment and perm-addmeta. flickr.photos.geo.setPerms() uses | |||
* public, contact, friend and family. | * public, contact, friend and family. | |||
* | * | |||
* A Photo permission. | * A Photo permission. | |||
*/ | */ | |||
typedef struct | typedef struct { | |||
{ | ||||
int is_public; | int is_public; | |||
int is_contact; | int is_contact; | |||
int is_friend; | int is_friend; | |||
int is_family; | int is_family; | |||
int perm_comment; | int perm_comment; | |||
int perm_addmeta; | int perm_addmeta; | |||
} flickcurl_perms; | } flickcurl_perms; | |||
/** | /** | |||
* flickcurl_location: | * flickcurl_location: | |||
* @latitude: The latitude from -90 to 90 | * @latitude: The latitude from -90 to 90 | |||
* @longitude: The longitude from -180 to 180 | * @longitude: The longitude from -180 to 180 | |||
* @accuracy: Recorded accuracy level of the location. | * @accuracy: Recorded accuracy level of the location. | |||
* World level is 1, Country is ~3, Region ~6, City ~11, Street | * World level is 1, Country is ~3, Region ~6, City ~11, Street | |||
* ~16. Current range is 1-16. Defaults to 16 if not specified. (<0 for n one) | * ~16. Current range is 1-16. Defaults to 16 if not specified. (<0 for n one) | |||
* | * | |||
* A Photo Location. | * A Photo Location. | |||
*/ | */ | |||
typedef struct | typedef struct { | |||
{ | ||||
double latitude; | double latitude; | |||
double longitude; | double longitude; | |||
int accuracy; | int accuracy; | |||
} flickcurl_location; | } flickcurl_location; | |||
/** | /** | |||
* flickcurl_place_type: | * flickcurl_place_type: | |||
* @FLICKCURL_PLACE_LOCATION: a general location | * @FLICKCURL_PLACE_LOCATION: a general location | |||
* @FLICKCURL_PLACE_NEIGHBORHOOD: neighborhood (narrowest place) | * @FLICKCURL_PLACE_NEIGHBORHOOD: neighborhood (narrowest place) | |||
* @FLICKCURL_PLACE_LOCALITY: locality | * @FLICKCURL_PLACE_LOCALITY: locality | |||
skipping to change at line 438 | skipping to change at line 451 | |||
* @type: Location type of index 0 (the location) usually | * @type: Location type of index 0 (the location) usually | |||
* FLICKCURL_PLACE_LOCATION but may be wider | * FLICKCURL_PLACE_LOCATION but may be wider | |||
* @woe_ids: Array of WOE IDs | * @woe_ids: Array of WOE IDs | |||
* | * | |||
* A Place. | * A Place. | |||
* | * | |||
* Index 0 in the array is the location itself. flickcurl_get_place_type_la bel() | * Index 0 in the array is the location itself. flickcurl_get_place_type_la bel() | |||
* can give labels for the array indexes of type #flickcurl_place_type. | * can give labels for the array indexes of type #flickcurl_place_type. | |||
* | * | |||
*/ | */ | |||
typedef struct | typedef struct { | |||
{ | ||||
char* names[FLICKCURL_PLACE_LAST+1]; | char* names[FLICKCURL_PLACE_LAST+1]; | |||
char* ids[FLICKCURL_PLACE_LAST+1]; | char* ids[FLICKCURL_PLACE_LAST+1]; | |||
char* urls[FLICKCURL_PLACE_LAST+1]; | char* urls[FLICKCURL_PLACE_LAST+1]; | |||
flickcurl_place_type type; | flickcurl_place_type type; | |||
char* woe_ids[FLICKCURL_PLACE_LAST+1]; | char* woe_ids[FLICKCURL_PLACE_LAST+1]; | |||
} flickcurl_place; | } flickcurl_place; | |||
/** | /** | |||
* flickcurl_tag: | * flickcurl_tag: | |||
* @photo: Associated photo object if any | * @photo: Associated photo object if any | |||
skipping to change at line 491 | skipping to change at line 503 | |||
* | * | |||
* Field of a photo structure | * Field of a photo structure | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
char* string; | char* string; | |||
flickcurl_photo_field_type integer; | flickcurl_photo_field_type integer; | |||
flickcurl_field_value_type type; | flickcurl_field_value_type type; | |||
} flickcurl_photo_field; | } flickcurl_photo_field; | |||
/** | /** | |||
* flickcurl_video: | ||||
* @ready: video is ready flag | ||||
* @failed: video failed | ||||
* @pending: video pending | ||||
* @duration: video duration in seconds | ||||
* @width: video width | ||||
* @height: video height | ||||
* | ||||
* A video. | ||||
* | ||||
**/ | ||||
typedef struct { | ||||
int ready; | ||||
int failed; | ||||
int pending; | ||||
int duration; | ||||
int width; | ||||
int height; | ||||
} flickcurl_video; | ||||
/** | ||||
* flickcurl_photo: | * flickcurl_photo: | |||
* @id: photo ID | * @id: photo/video ID | |||
* @uri: photo page URI | * @uri: photo/video page URI | |||
* @tags: array of tags (may be NULL) | * @tags: array of tags (may be NULL) | |||
* @tags_count: size of tags array | * @tags_count: size of tags array | |||
* @fields: photo fields | * @fields: metadata fields | |||
* @place: photot place | * @place: place | |||
* @video: video (may be NULL) | ||||
* @media_type: "photo" or "video" | ||||
* | * | |||
* A photo. | * A photo or video. | |||
* | * | |||
*/ | */ | |||
typedef struct flickcurl_photo_s { | typedef struct flickcurl_photo_s { | |||
char *id; | char *id; | |||
char *uri; | char *uri; | |||
flickcurl_tag** tags; | flickcurl_tag** tags; | |||
int tags_count; | int tags_count; | |||
flickcurl_photo_field fields[PHOTO_FIELD_LAST + 1]; | flickcurl_photo_field fields[PHOTO_FIELD_LAST + 1]; | |||
flickcurl_place* place; | flickcurl_place* place; | |||
flickcurl_video* video; | ||||
char *media_type; | ||||
} flickcurl_photo; | } flickcurl_photo; | |||
/** | /** | |||
* flickcurl_license: | * flickcurl_license: | |||
* @id: license ID | * @id: license ID | |||
* @url: license URL | * @url: license URL | |||
* @name: license short name | * @name: license short name | |||
* | * | |||
* A photo license. | * A photo license. | |||
* | * | |||
skipping to change at line 831 | skipping to change at line 870 | |||
* @accuracy: Recorded accuracy level of the location information. Current range is 1-16 | * @accuracy: Recorded accuracy level of the location information. Current range is 1-16 | |||
* @safe_search: Safe search setting: 1 safe, 2 moderate, 3 restricted. | * @safe_search: Safe search setting: 1 safe, 2 moderate, 3 restricted. | |||
* @content_type: Content Type setting: 1 for photos only, 2 for screenshot s only, 3 for 'other' only, 4 for all types. (or NULL) | * @content_type: Content Type setting: 1 for photos only, 2 for screenshot s only, 3 for 'other' only, 4 for all types. (or NULL) | |||
* @machine_tags: Machine tag search syntax | * @machine_tags: Machine tag search syntax | |||
* @machine_tag_mode: Either 'any' for an OR combination of tags, or 'all' for an AND combination. Defaults to 'any' if not specified. | * @machine_tag_mode: Either 'any' for an OR combination of tags, or 'all' for an AND combination. Defaults to 'any' if not specified. | |||
* @group_id: The id of a group who's pool to search. If specified, only m atching photos posted to the group's pool will be returned. (or NULL) | * @group_id: The id of a group who's pool to search. If specified, only m atching photos posted to the group's pool will be returned. (or NULL) | |||
* @extras: A comma-delimited list of extra information to fetch for each r eturned record. Currently supported fields are: <code>license</code>, <code >date_upload</code>, <code>date_taken</code>, <code>owner_name</code>, <cod e>icon_server</code>, <code>original_format</code>, <code>last_update</code >, <code>geo</code>, <code>tags</code>, <code>machine_tags</code>. (or NULL ) | * @extras: A comma-delimited list of extra information to fetch for each r eturned record. Currently supported fields are: <code>license</code>, <code >date_upload</code>, <code>date_taken</code>, <code>owner_name</code>, <cod e>icon_server</code>, <code>original_format</code>, <code>last_update</code >, <code>geo</code>, <code>tags</code>, <code>machine_tags</code>. (or NULL ) | |||
* @per_page: Number of photos to return per page. If this argument is omit ted, it defaults to 100. The maximum allowed value is 500. (or NULL) | * @per_page: Number of photos to return per page. If this argument is omit ted, it defaults to 100. The maximum allowed value is 500. (or NULL) | |||
* @page: The page of results to return. If this argument is omitted, it de faults to 1. (or NULL) | * @page: The page of results to return. If this argument is omitted, it de faults to 1. (or NULL) | |||
* @place_id: A Flickr place id. (only used if bbox argument isn't present) . Experimental. Geo queries require some sort of limiting agent in order t o prevent the database from crying. This is basically like the check agains t "parameterless searches" for queries without a geo component. A tag, fo r instance, is considered a limiting agent as are user defined min_date_tak en and min_date_upload parameters - If no limiting factor is passed we retu rn only photos added in the last 12 hours (though we may extend the limit i n the future) (or NULL) | * @place_id: A Flickr place id. (only used if bbox argument isn't present) . Experimental. Geo queries require some sort of limiting agent in order t o prevent the database from crying. This is basically like the check agains t "parameterless searches" for queries without a geo component. A tag, fo r instance, is considered a limiting agent as are user defined min_date_tak en and min_date_upload parameters - If no limiting factor is passed we retu rn only photos added in the last 12 hours (though we may extend the limit i n the future) (or NULL) | |||
* @media: "photos" or "videos" (or NULL) | ||||
* | * | |||
* Search parameters for flickcurl_photos_search() | * Search parameters for flickcurl_photos_search() | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
char* user_id; | char* user_id; | |||
char* tags; | char* tags; | |||
char* tag_mode; | char* tag_mode; | |||
char* text; | char* text; | |||
int min_upload_date; | int min_upload_date; | |||
int max_upload_date; | int max_upload_date; | |||
skipping to change at line 857 | skipping to change at line 897 | |||
int accuracy; | int accuracy; | |||
int safe_search; | int safe_search; | |||
int content_type; | int content_type; | |||
char* machine_tags; | char* machine_tags; | |||
char* machine_tag_mode; | char* machine_tag_mode; | |||
char* group_id; | char* group_id; | |||
char* extras; | char* extras; | |||
int per_page; | int per_page; | |||
int page; | int page; | |||
char* place_id; | char* place_id; | |||
char* media; | ||||
} flickcurl_search_params; | } flickcurl_search_params; | |||
/** | /** | |||
* flickcurl_photoset: | * flickcurl_photoset: | |||
* @id: photoset ID | * @id: photoset ID | |||
* @primary: primary photo ID | * @primary: primary photo ID | |||
* @secret: secret | * @secret: secret | |||
* @server: server | * @server: server | |||
* @farm: farm | * @farm: farm | |||
* @photos_count: count of photos in set | * @photos_count: count of photos in set | |||
skipping to change at line 891 | skipping to change at line 932 | |||
char *description; | char *description; | |||
} flickcurl_photoset; | } flickcurl_photoset; | |||
/** | /** | |||
* flickcurl_size: | * flickcurl_size: | |||
* @label: label | * @label: label | |||
* @width: width in pixels | * @width: width in pixels | |||
* @height: height in pixels | * @height: height in pixels | |||
* @source: raw image source URL | * @source: raw image source URL | |||
* @url: url of photo page | * @url: url of photo page | |||
* @media: 'photo' or 'video' | ||||
* | * | |||
* A photo at a size. | * A photo at a size. | |||
* | * | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
char *label; | char *label; | |||
int width; | int width; | |||
int height; | int height; | |||
char *source; | char *source; | |||
char *url; | char *url; | |||
char* media; | ||||
} flickcurl_size; | } flickcurl_size; | |||
/** | /** | |||
* flickcurl_ticket: | * flickcurl_ticket: | |||
* @id: ticket ID | * @id: ticket ID | |||
* @photoID: photoID | * @photoID: photoID | |||
* @complete: complete flag | * @complete: complete flag | |||
* @invalid: invalid flag | * @invalid: invalid flag | |||
* | * | |||
* An aysnchronous photo upload ticket. | * An aysnchronous photo upload ticket. | |||
skipping to change at line 953 | skipping to change at line 996 | |||
int bandwidth_remainingbytes; | int bandwidth_remainingbytes; | |||
int bandwidth_remainingkb; | int bandwidth_remainingkb; | |||
int filesize_maxbytes; | int filesize_maxbytes; | |||
int filesize_maxkb; | int filesize_maxkb; | |||
int sets_created; | int sets_created; | |||
char* sets_remaining; | char* sets_remaining; | |||
} flickcurl_user_upload_status; | } flickcurl_user_upload_status; | |||
/** | ||||
* flickcurl_serializer: | ||||
* | ||||
* Serializer from Photo and metadata to RDF triples | ||||
*/ | ||||
struct flickcurl_serializer_s; | ||||
/** | ||||
* flickcurl_term_type: | ||||
* @FLICKCURL_TERM_TYPE_RESOURCE: resource/URI term | ||||
* @FLICKCURL_TERM_TYPE_BLANK: blank node/anonymous term | ||||
* @FLICKCURL_TERM_TYPE_LITERAL: literal term | ||||
* | ||||
* Triple part types | ||||
* | ||||
* These are the same as raptor_identifier_type values. | ||||
*/ | ||||
typedef enum { | ||||
FLICKCURL_TERM_TYPE_RESOURCE = 1, | ||||
FLICKCURL_TERM_TYPE_BLANK = 2, | ||||
FLICKCURL_TERM_TYPE_LITERAL = 5 | ||||
} flickcurl_term_type; | ||||
/** | ||||
* flickcurl_serializer_factory: | ||||
* @version: API version | ||||
* @emit_namespace: (V1) emit namespace callback | ||||
* @emit_triple: (V1) emit a triple | ||||
* @emit_finish: (V1) finish emitting | ||||
* | ||||
* Triples serializer factory | ||||
* | ||||
* API version 1 is all that is supported. | ||||
*/ | ||||
typedef struct { | ||||
int version; | ||||
void (*emit_namespace)(void* user_data, const char* prefix, size_t prefix | ||||
_len, const char* uri, size_t uri_len); | ||||
void (*emit_triple)(void* user_data, | ||||
const char* subject, int subject_type, | ||||
const char* predicate_nspace, const char* predicate_n | ||||
ame, | ||||
const char *object, int object_type, | ||||
const char *datatype_uri); | ||||
void (*emit_finish)(void* user_data); | ||||
} flickcurl_serializer_factory; | ||||
typedef struct flickcurl_serializer_s flickcurl_serializer; | ||||
FLICKCURL_API | ||||
flickcurl_serializer* flickcurl_new_serializer(flickcurl* fc, void* data, f | ||||
lickcurl_serializer_factory* factory); | ||||
FLICKCURL_API | ||||
void flickcurl_free_serializer(flickcurl_serializer* serializer); | ||||
FLICKCURL_API | ||||
int flickcurl_serialize_photo(flickcurl_serializer* fcs, flickcurl_photo* p | ||||
hoto); | ||||
/* callback handlers */ | /* callback handlers */ | |||
/** | /** | |||
* flickcurl_message_handler | * flickcurl_message_handler | |||
* @user_data: user data pointer | * @user_data: user data pointer | |||
* @message: error message | * @message: error message | |||
* | * | |||
* Flickcurl Message handler callback. | * Flickcurl Message handler callback. | |||
*/ | */ | |||
typedef void (*flickcurl_message_handler)(void *user_data, const char *mess age); | typedef void (*flickcurl_message_handler)(void *user_data, const char *mess age); | |||
skipping to change at line 1074 | skipping to change at line 1171 | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_free_ticket(flickcurl_ticket *ticket); | void flickcurl_free_ticket(flickcurl_ticket *ticket); | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_free_tickets(flickcurl_ticket **tickets_object); | void flickcurl_free_tickets(flickcurl_ticket **tickets_object); | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_free_user_upload_status(flickcurl_user_upload_status *u); | void flickcurl_free_user_upload_status(flickcurl_user_upload_status *u); | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_free_place(flickcurl_place* place); | void flickcurl_free_place(flickcurl_place* place); | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_free_places(flickcurl_place** places_object); | void flickcurl_free_places(flickcurl_place** places_object); | |||
FLICKCURL_API | ||||
void flickcurl_free_video(flickcurl_video *video); | ||||
/* utility methods */ | /* utility methods */ | |||
/* get an image URL for a photo in some size */ | /* get an image URL for a photo in some size */ | |||
FLICKCURL_API | FLICKCURL_API | |||
char* flickcurl_photo_as_source_uri(flickcurl_photo *photo, const char c); | char* flickcurl_photo_as_source_uri(flickcurl_photo *photo, const char c); | |||
/* get labels for various field/types */ | /* get labels for various field/types */ | |||
FLICKCURL_API | FLICKCURL_API | |||
const char* flickcurl_get_photo_field_label(flickcurl_photo_field_type fiel d); | const char* flickcurl_get_photo_field_label(flickcurl_photo_field_type fiel d); | |||
FLICKCURL_API | FLICKCURL_API | |||
const char* flickcurl_get_person_field_label(flickcurl_person_field_type fi eld); | const char* flickcurl_get_person_field_label(flickcurl_person_field_type fi eld); | |||
FLICKCURL_API | FLICKCURL_API | |||
const char* flickcurl_get_field_value_type_label(flickcurl_field_value_type datatype); | const char* flickcurl_get_field_value_type_label(flickcurl_field_value_type datatype); | |||
FLICKCURL_API | FLICKCURL_API | |||
const char* flickcurl_get_context_type_field_label(flickcurl_context_type t ype); | const char* flickcurl_get_context_type_field_label(flickcurl_context_type t ype); | |||
FLICKCURL_API | ||||
const char* flickcurl_get_content_type_label(int content_type); | ||||
FLICKCURL_API | ||||
int flickcurl_get_content_type_from_string(const char* content_type_string) | ||||
; | ||||
FLICKCURL_API | ||||
const char* flickcurl_get_safety_level_label(int safety_level); | ||||
FLICKCURL_API | ||||
int flickcurl_get_safety_level_from_string(const char* safety_level_string) | ||||
; | ||||
/** | /** | |||
* set_config_var_handler: | * set_config_var_handler: | |||
* @userdata: user data pointer | * @userdata: user data pointer | |||
* @key: key | * @key: key | |||
* @value: value | * @value: value | |||
* | * | |||
* Handler to get variables returned from an 'INI' style configuration file | * Handler to get variables returned from an 'INI' style configuration file | |||
*/ | */ | |||
typedef void (*set_config_var_handler)(void* userdata, const char* key, con st char* value); | typedef void (*set_config_var_handler)(void* userdata, const char* key, con st char* value); | |||
FLICKCURL_API | FLICKCURL_API | |||
skipping to change at line 1359 | skipping to change at line 1467 | |||
int flickcurl_photosets_comments_deleteComment(flickcurl* fc, const char* c omment_id); | int flickcurl_photosets_comments_deleteComment(flickcurl* fc, const char* c omment_id); | |||
FLICKCURL_API | FLICKCURL_API | |||
int flickcurl_photosets_comments_editComment(flickcurl* fc, const char* com ment_id, const char* comment_text); | int flickcurl_photosets_comments_editComment(flickcurl* fc, const char* com ment_id, const char* comment_text); | |||
FLICKCURL_API | FLICKCURL_API | |||
flickcurl_comment** flickcurl_photosets_comments_getList(flickcurl* fc, con st char* photoset_id); | flickcurl_comment** flickcurl_photosets_comments_getList(flickcurl* fc, con st char* photoset_id); | |||
/* flickr.prefs */ | /* flickr.prefs */ | |||
FLICKCURL_API | FLICKCURL_API | |||
int flickcurl_prefs_getContentType(flickcurl* fc); | int flickcurl_prefs_getContentType(flickcurl* fc); | |||
FLICKCURL_API | FLICKCURL_API | |||
int flickcurl_prefs_getGeoPerms(flickcurl* fc); | ||||
FLICKCURL_API | ||||
int flickcurl_prefs_getHidden(flickcurl* fc); | int flickcurl_prefs_getHidden(flickcurl* fc); | |||
FLICKCURL_API | FLICKCURL_API | |||
int flickcurl_prefs_getPrivacy(flickcurl* fc); | int flickcurl_prefs_getPrivacy(flickcurl* fc); | |||
FLICKCURL_API | FLICKCURL_API | |||
int flickcurl_prefs_getSafetyLevel(flickcurl* fc); | int flickcurl_prefs_getSafetyLevel(flickcurl* fc); | |||
/* flickr.reflection */ | /* flickr.reflection */ | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_free_method(flickcurl_method *method); | void flickcurl_free_method(flickcurl_method *method); | |||
FLICKCURL_API | FLICKCURL_API | |||
skipping to change at line 1432 | skipping to change at line 1542 | |||
char** flickcurl_array_split(const char *str, char delim); | char** flickcurl_array_split(const char *str, char delim); | |||
FLICKCURL_API | FLICKCURL_API | |||
void flickcurl_array_free(char *array[]); | void flickcurl_array_free(char *array[]); | |||
/* ignore these */ | /* ignore these */ | |||
/** | /** | |||
* FLICKCURL_DEPRECATED: | * FLICKCURL_DEPRECATED: | |||
* | * | |||
* deprecated | * deprecated | |||
*/ | */ | |||
/** | /** | |||
* flickcurl_category_s: | * flickcurl_category_s: | |||
* @id: ignore | * @id: ignore | |||
* @name: ignore | * @name: ignore | |||
* @path: ignore | * @path: ignore | |||
* @count: ignore | * @count: ignore | |||
* @categories: ignore | * @categories: ignore | |||
* @categories_count: ignore | * @categories_count: ignore | |||
* @groups: ignore | * @groups: ignore | |||
* @groups_count: ignore | * @groups_count: ignore | |||
* | * | |||
* category_s | * category_s | |||
*/ | */ | |||
/** | /** | |||
* flickcurl_photo_s: | * flickcurl_photo_s: | |||
* | * | |||
* photo_s | * photo_s | |||
*/ | */ | |||
/** | /** | |||
* flickcurl_s: | * flickcurl_s: | |||
* | * | |||
* flickcurl | * flickcurl_s | |||
*/ | ||||
/** | ||||
* flickcurl_serializer_s: | ||||
* | ||||
* flickcurl_serializer_s | ||||
*/ | */ | |||
#ifdef __cplusplus | #ifdef __cplusplus | |||
} | } | |||
#endif | #endif | |||
#endif | #endif | |||
End of changes. 28 change blocks. | ||||
19 lines changed or deleted | 143 lines changed or added | |||