LinktypeInterface
interface \
This class provides interface implementation.
Table of Contents
Methods
- checkLink() : bool
- Checks a given link for validity
- fetchType() : string
- Base type fetching method, based on the type that softRefParserObj returns.
- getBrokenUrl() : string
- Construct a valid Url for browser output
- getErrorMessage() : string
- Generate the localized error message from the error params saved from the parsing
- getErrorParams() : array
- Get the value of the private property errorParams.
- setAdditionalConfig() : void
- Function to override config of Linktype. Should be used only if necessary. Add additional configuration to TSconfig.
Methods
checkLink()
Checks a given link for validity
public
checkLink(string $url, array $softRefEntry, LinkAnalyzer $reference) : bool
Parameters
- $url : string
-
Url to check
- $softRefEntry : array
-
The soft reference entry which builds the context of that url
- $reference : LinkAnalyzer
-
Parent instance
Return values
bool —TRUE on success or FALSE on error
fetchType()
Base type fetching method, based on the type that softRefParserObj returns.
public
fetchType(array $value, string $type, string $key) : string
Parameters
- $value : array
-
Reference properties
- $type : string
-
Current type
- $key : string
-
Validator hook name
Return values
string —Fetched type
getBrokenUrl()
Construct a valid Url for browser output
public
getBrokenUrl(array $row) : string
Parameters
- $row : array
-
Broken link record
Tags
Return values
string —Parsed broken url
getErrorMessage()
Generate the localized error message from the error params saved from the parsing
public
getErrorMessage(array $errorParams) : string
Parameters
- $errorParams : array
-
All parameters needed for the rendering of the error message
Return values
string —Validation error message
getErrorParams()
Get the value of the private property errorParams.
public
getErrorParams() : array
Tags
Return values
array —All parameters needed for the rendering of the error message
setAdditionalConfig()
Function to override config of Linktype. Should be used only if necessary. Add additional configuration to TSconfig.
public
setAdditionalConfig(array $config) : void
Parameters
- $config : array