Jose\Object\JWE::getJSONBase PHP Method

getJSONBase() private method

private getJSONBase ( ) : array
return array
    private function getJSONBase()
    {
        $json = ['ciphertext' => Base64Url::encode($this->getCiphertext())];
        if (null !== $this->getIV()) {
            $json['iv'] = Base64Url::encode($this->getIV());
        }
        if (null !== $this->getTag()) {
            $json['tag'] = Base64Url::encode($this->getTag());
        }
        if (null !== $this->getAAD()) {
            $json['aad'] = Base64Url::encode($this->getAAD());
        }
        if (!empty($this->getSharedProtectedHeaders())) {
            $json['protected'] = $this->getEncodedSharedProtectedHeaders();
        }
        if (!empty($this->getSharedHeaders())) {
            $json['unprotected'] = $this->getSharedHeaders();
        }
        return $json;
    }