[TASK] Introduced addLine() to the buffer class.
[TASK] Made createBuffer function protected in ProtocolHandler classes.
This commit is contained in:
@@ -59,6 +59,16 @@ class Misc_Buffer {
|
||||
$this->pruneEmptyLines();
|
||||
}
|
||||
|
||||
/**
|
||||
* Appends data + linebreak to the buffer.
|
||||
* @param string $data
|
||||
* @return void
|
||||
*/
|
||||
public function addLine($data) {
|
||||
$this->buffer .= $data . $this->linebreak;
|
||||
$this->pruneEmptyLines();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the next line in the buffer and removes it from the buffer.
|
||||
* @return string
|
||||
|
||||
Reference in New Issue
Block a user