summary |
shortlog |
log |
commit | commitdiff |
tree |
github
raw |
patch |
inline | side by side (from parent 1:
f1df16d)
to process intermediate request results
* public function send()
* {
* while ($this->socketPerform()) {
* public function send()
* {
* while ($this->socketPerform()) {
- * $this->handleRequests();
* if (!$this->socketSelect()) {
* throw new HttpSocketExcpetion;
* }
* }
* if (!$this->socketSelect()) {
* throw new HttpSocketExcpetion;
* }
* }
- * $this->handleRequests();
- * private function handleRequests()
+ * protected final function socketPerform()
+ * $result = parent::socketPerform();
* foreach ($this->getFinishedRequests() as $r) {
* $this->detach($r);
* // handle response of finished request
* }
* foreach ($this->getFinishedRequests() as $r) {
* $this->detach($r);
* // handle response of finished request
* }
public function send()
{
while ($this->socketPerform()) {
public function send()
{
while ($this->socketPerform()) {
- $this->handleRequests();
if (!$this->socketSelect()) {
throw new HttpSocketException;
}
}
if (!$this->socketSelect()) {
throw new HttpSocketException;
}
}
- $this->handleRequests();
- private function handleRequests()
+ protected final function socketPerform()
+ $result = parent::socketPerform();
+
echo ".";
foreach ($this->getFinishedRequests() as $r) {
echo "=", $r->getResponseCode(), "=";
$this->detach($r);
}
echo ".";
foreach ($this->getFinishedRequests() as $r) {
echo "=", $r->getResponseCode(), "=";
$this->detach($r);
}