Get archived.

@return [[@doctodo return_type:getArchived]] [[@doctodo return_description:getArchived]]
964141
public function getArchived()
    {
        if (!$this->isArchivable()) {
            return false;
        }
        if (empty($this->owner->{$this->archiveField})) {
            return false;
        }

        return true;
    }
6279
public function current()
    {
        $document = $this->getCursor()->current();

        if ($document instanceof ActiveRecord) {
            $documentToArray = $document->toArray();
            $this->entitySchema = $document->getSchema();
        } else {
            $documentToArray = (array) $document;
        }

        return $this->getAssembler()->assemble(
            $documentToArray,
            $this->entitySchema
        );
    }
583450
public function getArchiveLink(string $archiveFormat = AbstractApi::ARCHIVE_TARBALL,
                                   string $ref = AbstractApi::BRANCH_MASTER): array
    {
        return $this->getApi()->request($this->getApi()->sprintf('/repos/:owner/:repo/:archive_format/:ref',
            $this->getRepositories()->getOwner(), $this->getRepositories()->getRepo(), $archiveFormat, $ref));
    }
679405
public function getData() {
        if ($this->toSort && !empty($this->getOrder())) {
            $this->sortData();
        }

        if ($this->getLimit()) {
            return array_slice($this->data, $this->getOffset(), $this->getLimit());
        } else {
            return $this->data;
        }
    }
422270
def all(self, archived=False, limit=None, page=None):
        """"""
        path = partial(_path, self.adapter)
        if not archived:
            path = _path(self.adapter)
        else:
            path = _path(self.adapter, 'archived')
        return self._get(path, limit=limit, page=page)
466714
protected function extractReturnFile()
    {
        $header = $this->registries[0];

        return [
            'sequence' => (int) $header->file_sequence,
            'emission' => static::parseDate($header->record_date),
            'charging' => $this->extractCharging(),
        ];
    }
783664
final protected function getData()
    {
        if ($this->storage->has($this->ns)) {
            return $this->storage->get($this->ns);
        } else {
            // If can't find in storage, then return default
            return $this->default;
        }
    }
757126
public function archive()
    {
        $lifespan = $this->lifespan();
        $date = is_string($lifespan) ? new DateTime($lifespan) : new DateTime();

        return $this->to($date);
    }
245034
public function toArray()
    {
        $result = parent::toArray();

        $result['hasFile'] = false;

        $fileNameOrSerial = $this->getFileNameFromReport();

        if ($fileNameOrSerial) {
            $result['hasFile'] = $this->isFileReferenced($fileNameOrSerial)
                ? true
                : $this->isFileStoredInQueueStorage($fileNameOrSerial);
        }

        return $result;
    }
351652
public static function get() {
        if ($data = @file_get_contents("https://raw.github.com/tobie/ua-parser/master/regexes.yaml")) {
            if (file_exists(__DIR__."/resources/regexes.yaml")) {
                if (!self::$nobackup) { 
                    if (!self::$silent) { print("backing up old YAML file...\n"); }
                        if (!copy(__DIR__."/resources/regexes.yaml", __DIR__."/resources/regexes.".date("Ymdhis").".yaml")) {
                            if (!self::$silent) { print("back-up failed...\n"); }
                                exit;
                        }
                }
            }
            $fp = fopen(__DIR__."/resources/regexes.yaml", "w");
            fwrite($fp, $data);
            fclose($fp);
            if (!self::$silent) { print("success...\n"); }
        } else {
            if (!self::$silent) { print("failed to get the file...\n"); }
        }
    }
198281
public function getArchiveDay()
    {
        $day = $this->request->param('Day');

        if (preg_match('/^[0-9]{1,2}$/', $day)) {
            if (checkdate($this->getArchiveMonth(), $day, $this->getArchiveYear())) {
                return (int) $day;
            }
        }

        return null;
    }
461900
public function getBytes()
    {
        if ($this->isDirty && $this->bytes) {
            return $this->bytes;
        }
        if ($this->isDirty && $this->filename) {
            return file_get_contents($this->filename);
        }
        if ($this->riakGridFSFile instanceof \RiakGridFSFile) {
            return $this->riakGridFSFile->getBytes();
        }
        return null;
    }
195185
public function getArchiveDate()
    {
        $year = $this->getArchiveYear();
        $month = $this->getArchiveMonth();
        $day = $this->getArchiveDay();

        if ($year) {
            if ($month) {
                $date = sprintf('%s-%s-01', $year, $month);

                if ($day) {
                    $date = sprintf('%s-%s-%s', $year, $month, $day);
                }
            } else {
                $date = sprintf('%s-01-01', $year);
            }

            $obj = DBDatetime::create('date');
            $obj->setValue($date);
            return $obj;
        }

        return null;
    }
1279598
public function getStoreData()
    {
        if (!isset($this->fileDataCache) || empty($this->fileDataCache)) {
            $data = [];

            if ($this->hasStoreData()) {
                $filename = static::FILE_NAME;
                $contents = file_get_contents("{$this->filepath}/{$filename}");

                if (!empty($contents) && $contents !== false) {
                    $data = Yaml::parse($contents);
                }
            }

            $this->fileDataCache = $data;
        }

        return $this->fileDataCache;
    }
741354
public function archive()
    {
        return $this->client->apiCall('channels.archive', [
            'channel' => $this->getId(),
        ])->then(function () {
            $this->data['is_archived'] = true;
        });
    }
495673
@Override
    public ArchiveFormat getArchiveFormat() {
        return getArchive().as(Configurable.class).getConfiguration().getExtensionLoader()
            .getArchiveFormatFromExtensionMapping(actualType);
    }
1328506
public function getRecords()
    {
        $data = array();

        // List identifiers
        if (empty($this->metadataIterator)) {
            $this->metadataIterator = $this->endpoint->listMetadataFormats();
        } else {
            $this->metadataIterator->rewind(); // rewind the iterator
        }

        // Auto-determine a metadata prefix to use for getting records
        $mdPrefix = (string) $this->metadataIterator->current()->metadataPrefix;

        $data = array(
            'header' => array('Identifier', 'Title', 'usageDataResourceURL'),
            'rows' => array(),
        );

        // Iterate
        $recordIterator = $this->endpoint->listRecords($mdPrefix);
        for ($i = 0; $i < 10; $i++) {
            $rec = $recordIterator->next();
            $data['rows'][] = array(
                $rec->header->identifier,
                // Truncate title
                substr($rec->metadata->commParadata->paradataTitle->string->__toString(), 0, 30),
                $rec->metadata->commParadata->usageDataResourceURL
            );
        }

        return $data;
    }