Team Ai
Apppublic

errorcode418/php

sourceHugging Faceupdated 1y agoView on Hugging Face
0likes
AbstractVersionedSoftware.php29 linesDownload Raw Back to Result
1<?php2/**3 * ua-parser4 *5 * Copyright (c) 2011-2013 Dave Olsen, http://dmolsen.com6 * Copyright (c) 2013-2014 Lars Strojny, http://usrportage.de7 *8 * Released under the MIT license9 */10namespace UAParser\Result;11 12abstract class AbstractVersionedSoftware extends AbstractSoftware13{14    /** @return string */15    abstract public function toVersion();16 17    /** @return string */18    public function toString()19    {20        return join(' ', array_filter(array($this->family, $this->toVersion())));21    }22 23    /** @return string */24    protected function formatVersion()25    {26        return join('.', array_filter(func_get_args(), 'is_numeric'));27    }28}29