5 #include "JAWS/IO_Handler.h"
6 #include "JAWS/Policy.h"
9 // --------------- READ TASK ----------------------
11 JAWS_HTTP_10_Read_Task::JAWS_HTTP_10_Read_Task ()
15 JAWS_HTTP_10_Read_Task::~JAWS_HTTP_10_Read_Task ()
20 JAWS_HTTP_10_Read_Task::handle_put (JAWS_Data_Block
*data
, ACE_Time_Value
*)
22 JAWS_TRACE ("JAWS_HTTP_10_Read_Task::handle_put");
24 JAWS_IO_Handler
*handler
= data
->io_handler ();
25 JAWS_Dispatch_Policy
*policy
= this->policy ();
26 if (policy
== 0) policy
= data
->policy ();
28 JAWS_IO
*io
= policy
->io ();
30 if (data
->length () > 0)
32 if (data
->rd_ptr ()[0] != '\0')
34 JAWS_TRACE ("JAWS_HTTP_10_Read_Task::handle_put, have data");
38 data
->rd_ptr (data
->wr_ptr ());
41 io
->read (handler
, data
, data
->size ());
42 switch (handler
->status ())
44 case JAWS_IO_Handler::READ_OK
:
46 JAWS_TRACE ("JAWS_HTTP_10_Read_Task::handle_put, READ_OK");
50 case JAWS_IO_Handler::READ_ERROR
:
51 case JAWS_IO_Handler::READ_ERROR_A
:
53 JAWS_TRACE ("JAWS_HTTP_10_Read_Task::handle_put, READ_ERROR");