Neos\Flow\ResourceManagement\Target\FileSystemTarget::getRelativePublicationPathAndFilename PHP Метод

getRelativePublicationPathAndFilename() защищенный Метод

No matter which kind of resource, persistent or static, this function will return a sub directory structure if no relative publication path was defined in the given object.
protected getRelativePublicationPathAndFilename ( Neos\Flow\ResourceManagement\ResourceMetaDataInterface $object ) : string
$object Neos\Flow\ResourceManagement\ResourceMetaDataInterface PersistentResource or Storage Object
Результат string The relative path and filename, for example "c/8/2/8/c828d0f88ce197be1aff7cc2e5e86b1244241ac6/MyPicture.jpg" (if subdivideHashPathSegment is on) or "c828d0f88ce197be1aff7cc2e5e86b1244241ac6/MyPicture.jpg" (if it's off)
    protected function getRelativePublicationPathAndFilename(ResourceMetaDataInterface $object)
    {
        if ($object->getRelativePublicationPath() !== '') {
            $pathAndFilename = $object->getRelativePublicationPath() . $object->getFilename();
        } else {
            if ($this->subdivideHashPathSegment) {
                $sha1Hash = $object->getSha1();
                $pathAndFilename = $sha1Hash[0] . '/' . $sha1Hash[1] . '/' . $sha1Hash[2] . '/' . $sha1Hash[3] . '/' . $sha1Hash . '/' . $object->getFilename();
            } else {
                $pathAndFilename = $object->getSha1() . '/' . $object->getFilename();
            }
        }
        return $pathAndFilename;
    }