summaryrefslogtreecommitdiffstats
path: root/libdimension/dimension
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2014-04-26 15:08:09 -0400
committerTavian Barnes <tavianator@tavianator.com>2014-04-26 15:08:09 -0400
commit12c4a5eb07f346083a59bc7d18567b2df3ed94ee (patch)
tree638017b057b81d34935048d1b4c4bb7472614d88 /libdimension/dimension
parent0acff566213fdddbc8f4561887aced121f82dc26 (diff)
downloaddimension-12c4a5eb07f346083a59bc7d18567b2df3ed94ee.tar.xz
future: Add a dmnsn_future_is_done() function.
Diffstat (limited to 'libdimension/dimension')
-rw-r--r--libdimension/dimension/future.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/libdimension/dimension/future.h b/libdimension/dimension/future.h
index 9f1f14a..9ba28b1 100644
--- a/libdimension/dimension/future.h
+++ b/libdimension/dimension/future.h
@@ -51,6 +51,13 @@ void dmnsn_future_cancel(dmnsn_future *future);
double dmnsn_future_progress(const dmnsn_future *future);
/**
+ * Find out if a background task is finished.
+ * @param[in] future The background task to examine.
+ * @return true if the task is done, false otherwise.
+ */
+bool dmnsn_future_is_done(const dmnsn_future *future);
+
+/**
* Wait for a certain amount of progress. Always use this rather than
* spinlocking.
* @param[in] future The background task to monitor.