|
STXXL
1.4.0
|
Inheritance diagram for stxxl::request:
Collaboration diagram for stxxl::request:Public Member Functions | |
| request (const completion_handler &on_compl, file *file__, void *buffer_, offset_type offset_, size_type bytes_, request_type type_) | |
| virtual | ~request () |
| void | check_alignment () const |
| void | check_errors () throw (stxxl::io_error) |
| Rises an exception if there were error with the I/O. More... | |
| void | error_occured (const char *msg) |
| Inform the request object that an error occurred during the I/O execution. More... | |
| void | error_occured (const std::string &msg) |
| Inform the request object that an error occurred during the I/O execution. More... | |
| void * | get_buffer () const |
| file * | get_file () const |
| offset_type | get_offset () const |
| size_type | get_size () const |
| request_type | get_type () const |
| std::ostream & | print (std::ostream &out) const |
| Dumps properties of a request. More... | |
Public Member Functions inherited from stxxl::request_interface | |
| virtual | ~request_interface () |
| virtual bool | add_waiter (onoff_switch *sw)=0 |
| virtual bool | cancel ()=0 |
| Cancel a request. More... | |
| virtual void | delete_waiter (onoff_switch *sw)=0 |
| virtual const char * | io_type () const =0 |
| Identifies the type of I/O implementation. More... | |
| virtual bool | poll ()=0 |
| Polls the status of the request. More... | |
| virtual void | serve ()=0 |
| virtual void | wait (bool measure_time=true)=0 |
| Suspends calling thread until completion of the request. More... | |
Public Member Functions inherited from stxxl::atomic_counted_object | |
| atomic_counted_object () | |
| new objects have zero reference count More... | |
| atomic_counted_object (const atomic_counted_object &) | |
| coping still creates a new object with zero reference count More... | |
| ~atomic_counted_object () | |
| bool | dec_reference () const |
| Call whenever resetting (i.e. overwriting) a pointer to the object. IMPORTANT: In case of self-assignment, call AFTER inc_reference(). More... | |
| unsigned_type | get_reference_count () const |
| Return the number of references to this object (for debugging) More... | |
| void | inc_reference () const |
| Call whenever setting a pointer to the object. More... | |
| atomic_counted_object & | operator= (const atomic_counted_object &) |
| assignment operator, leaves pointers unchanged More... | |
| bool | unique () const |
| Test if the counted_object is referenced by only one counting_ptr. More... | |
Protected Member Functions | |
| void | check_nref (bool after=false) |
| void | completed () |
Protected Member Functions inherited from stxxl::request_interface | |
| virtual void | notify_waiters ()=0 |
Protected Attributes | |
| void * | buffer |
| size_type | bytes |
| compat_unique_ptr < stxxl::io_error >::result | error |
| file * | file_ |
| offset_type | offset |
| completion_handler | on_complete |
| request_type | type |
Private Member Functions | |
| void | check_nref_failed (bool after) |
Additional Inherited Members | |
Public Types inherited from stxxl::request_interface | |
| typedef stxxl::external_size_type | offset_type |
| enum | request_type { READ, WRITE } |
| typedef stxxl::internal_size_type | size_type |
| stxxl::request::request | ( | const completion_handler & | on_compl, |
| file * | file__, | ||
| void * | buffer_, | ||
| offset_type | offset_, | ||
| size_type | bytes_, | ||
| request_type | type_ | ||
| ) |
Definition at line 22 of file request.cpp.
References stxxl::file::add_request_ref(), file_, stxxl::atomic_counted_object::get_reference_count(), and STXXL_VERBOSE3.
|
virtual |
Definition at line 39 of file request.cpp.
References stxxl::atomic_counted_object::get_reference_count(), and STXXL_VERBOSE3.
| void stxxl::request::check_alignment | ( | ) | const |
Definition at line 52 of file request.cpp.
References BLOCK_ALIGN, buffer, bytes, offset, and STXXL_ERRMSG.
Referenced by stxxl::serving_request::serving_request().
|
inline | |||||||||||||
|
inlineprotected |
Definition at line 96 of file request.h.
Referenced by stxxl::serving_request::serve().
|
private |
Definition at line 68 of file request.cpp.
References buffer, bytes, get_file(), stxxl::atomic_counted_object::get_reference_count(), stxxl::request_interface::io_type(), offset, stxxl::request_interface::READ, STXXL_ERRMSG, and type.
|
protectedvirtual |
Implements stxxl::request_interface.
Reimplemented in stxxl::serving_request.
Definition at line 44 of file request.cpp.
References stxxl::file::delete_request_ref(), file_, stxxl::request_interface::notify_waiters(), and on_complete.
Referenced by stxxl::serving_request::completed().
|
inline |
Inform the request object that an error occurred during the I/O execution.
Definition at line 76 of file request.h.
Referenced by stxxl::serving_request::serve().
|
inline |
|
inline |
|
inline |
Definition at line 64 of file request.h.
Referenced by check_nref_failed(), and print().
|
inline |
|
inline |
|
inline |
Definition at line 68 of file request.h.
Referenced by stxxl::request_queue_impl_qwqr::add_request(), stxxl::request_queue_impl_qwqr::cancel_request(), and print().
|
virtual |
Dumps properties of a request.
Implements stxxl::request_interface.
Definition at line 83 of file request.cpp.
References get_buffer(), get_file(), get_offset(), get_size(), get_type(), and stxxl::request_interface::READ.
Referenced by stxxl::operator<<().
|
protected |
Definition at line 47 of file request.h.
Referenced by check_alignment(), check_nref_failed(), and stxxl::serving_request::serve().
|
protected |
Definition at line 49 of file request.h.
Referenced by check_alignment(), check_nref_failed(), and stxxl::serving_request::serve().
|
protected |
|
protected |
Definition at line 46 of file request.h.
Referenced by completed(), stxxl::serving_request::io_type(), request(), and stxxl::serving_request::serve().
|
protected |
Definition at line 48 of file request.h.
Referenced by check_alignment(), check_nref_failed(), and stxxl::serving_request::serve().
|
protected |
Definition at line 42 of file request.h.
Referenced by completed().
|
protected |
Definition at line 50 of file request.h.
Referenced by check_nref_failed(), and stxxl::serving_request::serve().