Class UrlRewriteStorage

Class UrlRewriteStorage

Package: Shared\Storage
Category: System
Located at Shared/Storages/UrlRewriteStorage.inc.php

Methods summary

public __construct( NonEmptyStringType $contentType, CI_DB_query_builder $db, LanguageProviderInterface $languageProvider )

UrlRewriteStorage constructor.

public get( IdType $contentId ) : UrlRewriteCollection

Returns an UrlRewriteCollection with UrlRewrite instances for the provided content ID.

public findByRewriteUrl( NonEmptyStringType $rewriteUrl ) : UrlRewriteCollection

Returns an UrlRewriteCollection with UrlRewrite instances for the provided rewrite url.

public findByContentIdAndLanguageId( IdType $contentId, IdType $languageId ) : null|UrlRewrite

Returns a single UrlRewrite instance for the provided content ID and language ID or NULL if no entry was found.

public set( IdType $contentId, UrlRewriteCollection $collection ) : UrlRewriteStorage

Saves the given UrlRewriteCollection into the database after old entries were deleted by the provided container ID.

public delete( IdType $contentId ) : UrlRewriteStorage
protected _createUrlRewriteByArray( array $urlRewriteData ) : UrlRewrite

Properties summary

protected $db : CI_DB_query_builder

DB Connection.


		
protected $validContentTypes : array
array('product', 'category', 'content', 'search')