1 /* vim: set sw=8: -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
2 #ifndef _GNM_CONSOLIDATE_H_
3 # define _GNM_CONSOLIDATE_H_
7 #include <tools/tools.h>
13 * These can be both set, both unset or
14 * one of them can be set. Indicates
15 * what sort of consolidation we will
18 CONSOLIDATE_ROW_LABELS
= 1 << 0,
19 CONSOLIDATE_COL_LABELS
= 1 << 1,
22 * If set the row and/or column labels
23 * will be copied to the destination area
25 CONSOLIDATE_COPY_LABELS
= 1 << 2,
27 /* If this is set we put the outcome
28 * of our formulas into the destination
29 * otherwise we put formulas
31 CONSOLIDATE_PUT_VALUES
= 1 << 3
34 struct _GnmConsolidate
{
39 GnmConsolidateMode mode
;
42 unsigned ref_count
; /* boxed type */
45 GType
gnm_consolidate_get_type (void);
46 GnmConsolidate
*gnm_consolidate_new (void);
47 void gnm_consolidate_free (GnmConsolidate
*cs
, gboolean content_only
);
49 void gnm_consolidate_set_function (GnmConsolidate
*cs
, GnmFunc
*fd
);
50 void gnm_consolidate_set_mode (GnmConsolidate
*cs
,
51 GnmConsolidateMode mode
);
53 gboolean
gnm_consolidate_add_source (GnmConsolidate
*cs
, GnmValue
*range
);
54 gboolean
gnm_consolidate_check_destination (GnmConsolidate
*cs
,
55 data_analysis_output_t
*dao
);
57 gboolean
gnm_tool_consolidate_engine (GOCmdContext
*gcc
, data_analysis_output_t
*dao
, gpointer specs
,
58 analysis_tool_engine_t selector
, gpointer result
);
62 #endif /* _GNM_CONSOLIDATE_H_ */