PHP Class Arcanedev\SeoHelper\Entities\Keywords

Author: ARCANEDEV ([email protected])
Inheritance: implements Arcanedev\SeoHelper\Contracts\Entities\Keywords, use trait Arcanedev\Support\Traits\Configurable
Datei anzeigen Open project: arcanedev/seo-helper

Protected Properties

Property Type Description
$content array The meta content.
$name string The meta name.

Public Methods

Method Description
__construct ( array $configs = [] ) Make Keywords instance.
__toString ( ) : string Render the tag.
add ( string $keyword ) : self Add a keyword to the content.
addMany ( array $keywords ) : self Add many keywords to the content.
get ( ) : string Get keywords content.
getContent ( ) : array Get raw keywords content.
make ( array | string $keywords ) : self Make Keywords instance.
render ( ) : string Render the tag.
set ( array | string $content ) : self Set keywords content.

Private Methods

Method Description
clean ( string $value ) : string Clean the string.
hasContent ( ) : boolean Check if keywords has content.

Method Details

__construct() public method

Make Keywords instance.
public __construct ( array $configs = [] )
$configs array

__toString() public method

Render the tag.
public __toString ( ) : string
return string

add() public method

Add a keyword to the content.
public add ( string $keyword ) : self
$keyword string
return self

addMany() public method

Add many keywords to the content.
public addMany ( array $keywords ) : self
$keywords array
return self

get() public method

Get keywords content.
public get ( ) : string
return string

getContent() public method

Get raw keywords content.
public getContent ( ) : array
return array

make() public static method

Make Keywords instance.
public static make ( array | string $keywords ) : self
$keywords array | string
return self

render() public method

Render the tag.
public render ( ) : string
return string

set() public method

Set keywords content.
public set ( array | string $content ) : self
$content array | string
return self

Property Details

$content protected_oe property

The meta content.
protected array $content
return array

$name protected_oe property

The meta name.
protected string $name
return string