![]() |
![]() |
![]() |
Libbeagle Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
#define BEAGLE_HIT (x) BeagleHit; BeagleHit * beagle_hit_ref (BeagleHit *hit
); void beagle_hit_unref (BeagleHit *hit
); const char * beagle_hit_get_uri (BeagleHit *hit
); const char * beagle_hit_get_type (BeagleHit *hit
); const char * beagle_hit_get_mime_type (BeagleHit *hit
); const char * beagle_hit_get_file_type (BeagleHit *hit
); const char * beagle_hit_get_source (BeagleHit *hit
); const char * beagle_hit_get_parent_uri (BeagleHit *hit
); BeagleTimestamp * beagle_hit_get_timestamp (BeagleHit *hit
); double beagle_hit_get_score (BeagleHit *hit
); gboolean beagle_hit_get_one_property (BeagleHit *hit
,const char *key
,const char **value
); GSList * beagle_hit_get_properties (BeagleHit *hit
,const char *key
); GSList * beagle_hit_get_all_properties (BeagleHit *hit
);
BeagleHit * beagle_hit_ref (BeagleHit *hit
);
Increases the reference count of the BeagleHit.
void beagle_hit_unref (BeagleHit *hit
);
Decreases the reference count of the BeagleHit. When its reference count drops to 0, it is freed.
|
a BeagleHit. |
const char * beagle_hit_get_uri (BeagleHit *hit
);
Fetches the URI of the given BeagleHit.
const char * beagle_hit_get_type (BeagleHit *hit
);
Fetches the type of the given BeagleHit.
const char * beagle_hit_get_mime_type (BeagleHit *hit
);
Fetches the mime type of the given BeagleHit.
const char * beagle_hit_get_file_type (BeagleHit *hit
);
For hits based on files, fetches the type of file for the given BeagleHit.
const char * beagle_hit_get_source (BeagleHit *hit
);
Fetches the source of the given BeagleHit.
const char * beagle_hit_get_parent_uri (BeagleHit *hit
);
Fetches the parent URI of the given BeagleHit.
BeagleTimestamp * beagle_hit_get_timestamp (BeagleHit *hit
);
Fetches the timestamp of the given BeagleHit.
double beagle_hit_get_score (BeagleHit *hit
);
Fetches the score of the given BeagleHit.
gboolean beagle_hit_get_one_property (BeagleHit *hit
,const char *key
,const char **value
);
Puts the value of the property key
of the given BeagleHit in the string pointed to by value
.
The value of value
is set to NULL if FALSE is returned.
This is a shortcut method for getting the value of a property when you know ahead of time that only one property for a given key exists. This function will fail if the key isn't found or if there is more than one value for a given key.
|
a BeagleHit |
|
a string |
|
pointer to a string where value is stored |
Returns : |
TRUE if exactly one property with key was found, else FALSE.
|
GSList * beagle_hit_get_properties (BeagleHit *hit
,const char *key
);
Fetches all values of the property key
of the given BeagleHit.
|
a BeagleHit |
|
a string |
Returns : |
A list of values (char *) of the of property key . The values
contained within the list should not be freed.
|