\StaticSitePageTransformer
URL transformer specific to SilverStripe's `SiteTree` class for use with the module's import content feature.
If enabled in the CMS UI, links to imported pages will be automatically re-written.
- Author: Sam Minee <sam@silverstripe.com>
Synopsis
class StaticSitePageTransformer
extends StaticSiteDataTypeTransformer
{
- // members
- public static string $import_root = 'import-home';
- private static number $sleep_multiplier = 100;
- // Inherited members from StaticSiteDataTypeTransformer
- public StaticSiteUtils $utils;
- public StaticSiteMimeProcessor $mimeProcessor;
- public number $parentId;
- // methods
- public void __construct()
- public void transform()
- // Inherited methods from StaticSiteDataTypeTransformer
- public void __construct()
- public null getContentFieldsAndSelectors()
- protected boolean duplicationStrategy()
- public number getCurrentImportID()
- public array getSSExtensions()
- public void setParentId()
- public number getParentId()
Hierarchy
Extends
Members
private
- $sleep_multiplier
—
number
Default value to pass to usleep() to reduce load on the remote server
public
- $import_root — string
- $mimeProcessor — StaticSiteMimeProcessor
- $parentId
—
number
The parent ID of an imported object - $utils
—
StaticSiteUtils
Holds the StaticSiteUtils object on construct
Methods
public
- __construct()
- transform() — Generic function called by \ExternalContentImporter
Inherited from StaticSiteDataTypeTransformer
protected
- duplicationStrategy() — Process incoming content according to CMS user-inputted duplication strategy.
public
- getContentFieldsAndSelectors() — Get content from remote datasource (e.g. a File, Image or page-text).
- getCurrentImportID() — Get current import ID. If none can be found, start one and return that.
- getParentId() — Gets the parent ID for an imported object.
- getSSExtensions() — Build an array of file extensions. Utilised in buildFileProperties() to check incoming file-extensions are valid against those found on {@link File}.
- setParentId() — Sets the parent ID for an imported object.