CAUSE_MAX
};
+extern byte *flow_state_names[];
+extern byte *flow_cause_names[], *flow_cause_names_short[];
+
struct appl_hooks {
void (*open)(struct flow *f, u64 when);
- void (*input)(struct flow *f, int dir, struct pkt *p); /* dir0 = sent by initiator */
+ void (*input)(struct flow *f, int dir, struct pkt *p); /* dir0 = sent by initiator, pkt_len(p)==0 for close */
void (*close)(struct flow *f, int cause, u64 when);
};
void sink_open(struct flow *f, u64 when);
void sink_close(struct flow *f, int cause, u64 when);
void sink_input(struct flow *f, int dir, struct pkt *p);
+
+#define TIMESTAMP_LEN 32
+void format_timestamp(byte *buf, u64 time);
+
+/* http.c */
+
+extern struct appl_hooks appl_http;
+
+/* histogram.c */
+
+void histogram_init(byte *name);
+void histogram_add_stat(byte *name, struct pkt_stats *stat);
+void histogram_add_int(byte *name, int *var);
+void histogram_step(uns time);
+void histogram_cleanup(void);