facet ID term map PAZ-1008
[pazpar2-moved-to-github.git] / src / session.h
index 153c6ad..49e5338 100644 (file)
@@ -113,6 +113,7 @@ struct session {
     facet_limits_t facet_limits;
     int clients_starting;
     struct reclist_sortparms *sorted_results;
+    struct facet_id *facet_id_list;
 };
 
 struct statistics {
@@ -192,11 +193,15 @@ int ingest_record(struct client *cl, const char *rec, int record_no, NMEM nmem);
 int ingest_xml_record(struct client *cl, xmlDoc *xdoc,
                       int record_no, NMEM nmem, int cached_copy);
 void session_alert_watch(struct session *s, int what);
-void add_facet(struct session *s, const char *type, const char *value, int count);
+void add_facet(struct session *s, const char *type, const char *value, int count, struct client *cl);
 
 int session_check_cluster_limit(struct session *se, struct record_cluster *rec);
 
 void perform_termlist(struct http_channel *c, struct session *se, const char *name, int num, int version);
+
+const char *session_lookup_id_facet(struct session *s, struct client *cl,
+                                    const char *type, const char *term);
+
 void session_log(struct session *s, int level, const char *fmt, ...)
 #ifdef __GNUC__
     __attribute__ ((format (printf, 3, 4)))