PHP Class Shopware\PluginCreator\Services\NameGenerator

Class NameGenerator
Show file Open project: shopwarelabs/sw-cli-tools

Public Properties

Property Type Description
$backendModelAlias e.g.promotion
$backendWidgetController e.g. SwagTestWidget
$camelCaseModel e.g. PromotionTest
$dash_js e.g. swag-promotion
$developerPrefix e.g. swag
$under_score_js e.g. swag_promotion
$under_score_model e.g. promotion_test

Public Methods

Method Description
__construct ( Configuration $configuration )
generateNames ( ) Generate all needed names
getBackendModelAlias ( ) : string Determine the alias for the backend model
getModelName ( ) : mixed | string Return a proper model name
upperToArray ( $input ) : array Splits a given string by upper case characters

Method Details

__construct() public method

public __construct ( Configuration $configuration )
$configuration Shopware\PluginCreator\Struct\Configuration

generateNames() public method

Generate all needed names
public generateNames ( )

getBackendModelAlias() public method

Determine the alias for the backend model
public getBackendModelAlias ( ) : string
return string

getModelName() public method

Return a proper model name
public getModelName ( ) : mixed | string
return mixed | string

upperToArray() public method

Splits a given string by upper case characters
public upperToArray ( $input ) : array
$input
return array

Property Details

$backendModelAlias public property

e.g.promotion
public $backendModelAlias

$backendWidgetController public property

e.g. SwagTestWidget
public $backendWidgetController

$camelCaseModel public property

e.g. PromotionTest
public $camelCaseModel

$dash_js public property

e.g. swag-promotion
public $dash_js

$developerPrefix public property

e.g. swag
public $developerPrefix

$under_score_js public property

e.g. swag_promotion
public $under_score_js

$under_score_model public property

e.g. promotion_test
public $under_score_model