CoreFiles by mySites.guru
OtherObject.php34 lines, 715 bytes, from Joomla_6.2.0-Stable-Full_Package.zip
Raw History Compare with 6.1.4
md5
56a663af46d43211abf661c94aee7964
sha1
c093424a7575809e30cda3261bc12f79a181c8b7
sha256
c2cc34ecff5bde519e09d4bd3761f894c634977aafe09f088c964a47d84bb0fa
<?php

declare(strict_types=1);

namespace CBOR;

use CBOR\OtherObject\OtherObjectInterface;

abstract class OtherObject extends AbstractCBORObject implements OtherObjectInterface
{
    private const MAJOR_TYPE = self::MAJOR_TYPE_OTHER_TYPE;

    public function __construct(
        int $additionalInformation,
        protected ?string $data
    ) {
        parent::__construct(self::MAJOR_TYPE, $additionalInformation);
    }

    public function __toString(): string
    {
        $result = parent::__toString();
        if ($this->data !== null) {
            $result .= $this->data;
        }

        return $result;
    }

    public function getContent(): ?string
    {
        return $this->data;
    }
}

The same content is in 158 releases, Joomla 5.0.0-alpha1 to 6.3.0-alpha1. See them all, or every version of this file.