summaryrefslogtreecommitdiff
path: root/includes/Handle.h
diff options
context:
space:
mode:
authorPixel <pixel@nobis-crew.org>2011-11-15 17:00:03 -0800
committerPixel <pixel@nobis-crew.org>2011-11-15 17:00:03 -0800
commite72624ab203439ffea88cd55c145cdbbc57286e4 (patch)
tree5a766c74fa83441ff5ef4a744968eb6c65a7f675 /includes/Handle.h
parent36b12593e6ec34a88bde537a220e7a15f478638c (diff)
Adding a potential event to cancel a forced read/write, such as a timeout.
Diffstat (limited to 'includes/Handle.h')
-rw-r--r--includes/Handle.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/includes/Handle.h b/includes/Handle.h
index cfb004d..0eea93c 100644
--- a/includes/Handle.h
+++ b/includes/Handle.h
@@ -20,6 +20,12 @@ class IOBase;
template<class T>
class IO;
+namespace Events {
+
+class BaseEvent;
+
+};
+
class Handle {
public:
virtual ~Handle() { Assert(m_refCount == 0); }
@@ -42,8 +48,8 @@ class Handle {
virtual off_t wtell() throw (GeneralException);
virtual off_t getSize();
virtual time_t getMTime();
- ssize_t forceRead(void * buf, size_t count) throw (GeneralException);
- ssize_t forceWrite(const void * buf, size_t count) throw (GeneralException);
+ ssize_t forceRead(void * buf, size_t count, Events::BaseEvent * evt = NULL) throw (GeneralException);
+ ssize_t forceWrite(const void * buf, size_t count, Events::BaseEvent * evt = NULL) throw (GeneralException);
protected:
Handle() : m_refCount(0) { }
private: