PHP Class Sulu\Component\Content\Types\ResourceLocator\Strategy\ResourceLocatorStrategy

Inheritance: implements Sulu\Component\Content\Types\ResourceLocator\Strategy\ResourceLocatorStrategyInterface
Datei anzeigen Open project: sulu/sulu

Protected Properties

Property Type Description
$cleaner Sulu\Component\PHPCR\PathCleanupInterface
$contentTypeManager Sulu\Component\Content\ContentTypeManagerInterface
$documentInspector Sulu\Bundle\DocumentManagerBundle\Bridge\DocumentInspector
$documentManager Sulu\Component\DocumentManager\DocumentManagerInterface
$mapper Sulu\Component\Content\Types\ResourceLocator\Mapper\ResourceLocatorMapperInterface
$nodeHelper Sulu\Component\Util\SuluNodeHelper
$structureManager Sulu\Component\Content\Compat\StructureManagerInterface

Public Methods

Method Description
__construct ( Sulu\Component\Content\Types\ResourceLocator\Mapper\ResourceLocatorMapperInterface $mapper, Sulu\Component\PHPCR\PathCleanupInterface $cleaner, Sulu\Component\Content\Compat\StructureManagerInterface $structureManager, Sulu\Component\Content\ContentTypeManagerInterface $contentTypeManager, SuluNodeHelper $nodeHelper, DocumentInspector $documentInspector, Sulu\Component\DocumentManager\DocumentManagerInterface $documentManager, Sulu\Component\Content\Types\ResourceLocator\Strategy\ResourceLocatorGeneratorInterface $resourceLocatorGenerator )
deleteByPath ( $path, $webspaceKey, $languageCode, $segmentKey = null )
generate ( $title, $parentUuid, $webspaceKey, $languageCode, $segmentKey = null )
isValid ( $path, $webspaceKey, $languageCode, $segmentKey = null )
loadByContent ( Sulu\Component\Content\Document\Behavior\ResourceSegmentBehavior $document )
loadByContentUuid ( $uuid, $webspaceKey, $languageCode, $segmentKey = null )
loadByResourceLocator ( $resourceLocator, $webspaceKey, $languageCode, $segmentKey = null )
loadHistoryByContentUuid ( $uuid, $webspaceKey, $languageCode, $segmentKey = null )
save ( Sulu\Component\Content\Document\Behavior\ResourceSegmentBehavior $document, $userId )

Private Methods

Method Description
getPublishedAncestorOrSelf ( object $document ) : object Returns the first ancestor-or-self of the given document which is published and therefore has an assigned resource locator. If all ancestor documents are unpublished, the root document is returned.

Method Details

__construct() public method

public __construct ( Sulu\Component\Content\Types\ResourceLocator\Mapper\ResourceLocatorMapperInterface $mapper, Sulu\Component\PHPCR\PathCleanupInterface $cleaner, Sulu\Component\Content\Compat\StructureManagerInterface $structureManager, Sulu\Component\Content\ContentTypeManagerInterface $contentTypeManager, SuluNodeHelper $nodeHelper, DocumentInspector $documentInspector, Sulu\Component\DocumentManager\DocumentManagerInterface $documentManager, Sulu\Component\Content\Types\ResourceLocator\Strategy\ResourceLocatorGeneratorInterface $resourceLocatorGenerator )
$mapper Sulu\Component\Content\Types\ResourceLocator\Mapper\ResourceLocatorMapperInterface
$cleaner Sulu\Component\PHPCR\PathCleanupInterface
$structureManager Sulu\Component\Content\Compat\StructureManagerInterface
$contentTypeManager Sulu\Component\Content\ContentTypeManagerInterface
$nodeHelper Sulu\Component\Util\SuluNodeHelper
$documentInspector Sulu\Bundle\DocumentManagerBundle\Bridge\DocumentInspector
$documentManager Sulu\Component\DocumentManager\DocumentManagerInterface
$resourceLocatorGenerator Sulu\Component\Content\Types\ResourceLocator\Strategy\ResourceLocatorGeneratorInterface

deleteByPath() public method

public deleteByPath ( $path, $webspaceKey, $languageCode, $segmentKey = null )

generate() public method

public generate ( $title, $parentUuid, $webspaceKey, $languageCode, $segmentKey = null )

isValid() public method

public isValid ( $path, $webspaceKey, $languageCode, $segmentKey = null )

loadByContent() public method

public loadByContent ( Sulu\Component\Content\Document\Behavior\ResourceSegmentBehavior $document )
$document Sulu\Component\Content\Document\Behavior\ResourceSegmentBehavior

loadByContentUuid() public method

public loadByContentUuid ( $uuid, $webspaceKey, $languageCode, $segmentKey = null )

loadByResourceLocator() public method

public loadByResourceLocator ( $resourceLocator, $webspaceKey, $languageCode, $segmentKey = null )

loadHistoryByContentUuid() public method

public loadHistoryByContentUuid ( $uuid, $webspaceKey, $languageCode, $segmentKey = null )

save() public method

public save ( Sulu\Component\Content\Document\Behavior\ResourceSegmentBehavior $document, $userId )
$document Sulu\Component\Content\Document\Behavior\ResourceSegmentBehavior

Property Details

$cleaner protected_oe property

protected PathCleanupInterface,Sulu\Component\PHPCR $cleaner
return Sulu\Component\PHPCR\PathCleanupInterface

$contentTypeManager protected_oe property

protected ContentTypeManagerInterface,Sulu\Component\Content $contentTypeManager
return Sulu\Component\Content\ContentTypeManagerInterface

$documentInspector protected_oe property

protected DocumentInspector,Sulu\Bundle\DocumentManagerBundle\Bridge $documentInspector
return Sulu\Bundle\DocumentManagerBundle\Bridge\DocumentInspector

$documentManager protected_oe property

protected DocumentManagerInterface,Sulu\Component\DocumentManager $documentManager
return Sulu\Component\DocumentManager\DocumentManagerInterface

$mapper protected_oe property

protected ResourceLocatorMapperInterface,Sulu\Component\Content\Types\ResourceLocator\Mapper $mapper
return Sulu\Component\Content\Types\ResourceLocator\Mapper\ResourceLocatorMapperInterface

$nodeHelper protected_oe property

protected SuluNodeHelper,Sulu\Component\Util $nodeHelper
return Sulu\Component\Util\SuluNodeHelper

$structureManager protected_oe property

protected StructureManagerInterface,Sulu\Component\Content\Compat $structureManager
return Sulu\Component\Content\Compat\StructureManagerInterface