-
Notifications
You must be signed in to change notification settings - Fork 0
/
LinkPhase.php
42 lines (36 loc) · 927 Bytes
/
LinkPhase.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
namespace riiak;
use \CComponent;
/**
* The LinkPhase object holds information about a Link phase in a
* map/reduce operation.
* @package riiak
*/
class LinkPhase extends CComponent {
public $bucket;
public $tag;
public $keep;
/**
* Construct a LinkPhase object
*
* @param string $bucket The bucket name
* @param string $tag The tag
* @param bool $keep True to return results of this phase
*/
public function __construct($bucket, $tag, $keep) {
$this->bucket = $bucket;
$this->tag = $tag;
$this->keep = $keep;
}
/**
* Convert the LinkPhase to an associative array. Used internally.
*
* @return array
*/
public function toArray() {
$stepdef = array('bucket' => $this->bucket,
'tag' => $this->tag,
'keep' => $this->keep);
return array('link' => $stepdef);
}
}