Page MenuHomePhorge

PhrequentTimeSlices.php
No OneTemporary

Size
726 B
Referenced Files
None
Subscribers
None

PhrequentTimeSlices.php

<?php
final class PhrequentTimeSlices extends Phobject {
private $objectPHID;
private $isOngoing;
private $ranges;
public function __construct($object_phid, $is_ongoing, array $ranges) {
$this->objectPHID = $object_phid;
$this->isOngoing = $is_ongoing;
$this->ranges = $ranges;
}
public function getObjectPHID() {
return $this->objectPHID;
}
public function getDuration($now) {
foreach ($this->ranges as $range) {
if ($range[1] === null) {
return $now - $range[0];
} else {
return $range[1] - $range[0];
}
}
}
public function getIsOngoing() {
return $this->isOngoing;
}
public function getRanges() {
return $this->ranges;
}
}

File Metadata

Mime Type
text/x-php
Expires
Mon, Jul 7, 7:59 PM (1 d, 17 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
326353
Default Alt Text
PhrequentTimeSlices.php (726 B)

Event Timeline