| Top |
If any properties of the query change such that matches may change, the "notify" signal will be emitted, potentially without a detail string. Views which are using this query should re-evaluate their matches on receiving this signal.
See also: FolksSearchView
guint folks_query_is_match (FolksQuery *self,FolksIndividual *individual);
Determines whether a given FolksIndividual matches this query.
This returns a match strength, which is on an arbitrary scale which is not part of libfolks’ public API. These strengths should not be stored by user applications, or examined numerically — they should only be used for pairwise strength comparisons.
This function is intended to be used in the FolksSearchView implementation only. Use "individuals" to retrieve search results.
a positive integer if the individual matches this query, or zero if they do not match; higher numbers indicate a better match
Since: 0.11.0
gchar ** folks_query_get_match_fields (FolksQuery *self,gint *result_length1);
Get and return the current value of the "match-fields" property.
The names of the fields to match within
The names of valid fields are available via folks_persona_store_detail_key().
The ordering of the fields determines the order they are checked for matches, which can have performance implications (these should ideally be ordered from most- to least-likely to match).
Also note that more fields (particularly rarely-matched fields) will negatively impact performance, so only include important fields.
Default value is FOLKS_QUERY_MATCH_FIELDS_NAMES.
Since: 0.11.0
struct FolksQuery {
GObject parent_instance;
FolksQueryPrivate * priv;
};
A contact query.
If any properties of the query change such that matches may change, the "notify" signal will be emitted, potentially without a detail string. Views which are using this query should re-evaluate their matches on receiving this signal.
See also: FolksSearchView
Since: 0.11.0
struct FolksQueryClass {
GObjectClass parent_class;
guint (*is_match) (FolksQuery* self, FolksIndividual* individual);
gchar** (*get_match_fields) (FolksQuery* self, gint* result_length1);
void (*set_match_fields) (FolksQuery* self, gchar** value, gint value_length1);
};
The class structure for FOLKS_TYPE_QUERY. All the fields in this structure are private and should never be accessed directly.
virtual method called by |
||
getter method for the abstract property "match-fields" |
||