summaryrefslogtreecommitdiff
path: root/libdm/.exported_symbols.DM_1_02_101
diff options
context:
space:
mode:
authorPeter Rajnoha <prajnoha@redhat.com>2015-05-19 13:01:48 +0200
committerPeter Rajnoha <prajnoha@redhat.com>2015-07-03 10:47:09 +0200
commit335707b0e2e657a40ae87fb47dbf744cb53d74fb (patch)
treecd2fefbdb6a21a4ba107d013c3c520cb3caf0a75 /libdm/.exported_symbols.DM_1_02_101
parent82ecfa6f0eea0e09dadc9b6e32f6d1359152997f (diff)
downloadlvm2-335707b0e2e657a40ae87fb47dbf744cb53d74fb.tar.gz
report: add infrastructure to recognize fuzzy reserved names and returning dynamic reserved values
With fuzzy names we mean the names for which it's hard or even impossible to enumerate all possible variations of the name - the name needs to be evaluated. An example of fuzzy name is a name which has a base (substring) which matches and it can contain arbitrary variations around this base. We can cover human language better with fuzzy names as people may use several different names (or sentences) to denote the same thing. With dynamic values we mean the values which are not constants and they need to be evaluated in runtime. An example of dynamic value is a value which depends on current system state (e.g. time, current configuration or any other state which may change and it needs runtime evaluation). There's a handler that can be registered with reporting/selection using dm_report_reserved_handler instance. This is a central point in which the computation/evaluation happens when processing reserved values. Currently, there are two actions declared: DM_REPORT_RESERVED_PARSE_FUZZY_NAME (translates fuzzy name into canonical name) DM_REPORT_RESERVED_GET_DYNAMIC_VALUE (gets value for canonical name) The handler is then registered as value in struct dm_report_reserved_value (see explaining comments besided the struct dm_report_reserved_value in libdevmapper.h). Also, this patch provides support for simple caching of values used during report/selection via dm_report_value_cache_{set,get}. This is supposed to be used mainly in the dm_report_reserved_handler instances to save values among calls so all the handler calls work with the same base value used in computation/evaluation and/or possibly to save resources if the evaluation is more time-consuming. The cache is attached to the dm_report handle and so the cache is dropped one dm_report is dropped.
Diffstat (limited to 'libdm/.exported_symbols.DM_1_02_101')
-rw-r--r--libdm/.exported_symbols.DM_1_02_1012
1 files changed, 2 insertions, 0 deletions
diff --git a/libdm/.exported_symbols.DM_1_02_101 b/libdm/.exported_symbols.DM_1_02_101
new file mode 100644
index 000000000..75089ba8b
--- /dev/null
+++ b/libdm/.exported_symbols.DM_1_02_101
@@ -0,0 +1,2 @@
+dm_report_value_cache_set
+dm_report_value_cache_get