Silla.IO API
  • Namespace
  • Class
  • Tree
  • Todo
  • Download

Namespaces

  • App
    • Controllers
  • CMS
    • Controllers
    • Helpers
    • Models
  • Configurations
    • CI
    • Development
    • Production
    • Staging
  • Core
    • Base
    • CLI
      • Cache
      • DB
    • Helpers
    • Modules
      • Cache
        • Adapters
        • Interfaces
      • Crypt
      • DB
        • Adapters
        • Decorators
          • Interfaces
        • Features
          • Paginator
        • Interfaces
      • Registry
      • Render
        • Adapters
        • Interfaces
      • Router
      • Session
        • Adapters
        • Interfaces
  • None
  • Tasks
    • DB

Classes

  • Configuration
  • Controller
  • Entity
  • Model
  • Task

Class Configuration

Class Configuration Definition.

Direct known subclasses

Configurations\Production\Configuration

Indirect known subclasses

Configurations\CI\Configuration, Configurations\Development\Configuration, Configurations\Staging\Configuration

Abstract
Namespace: Core\Base
Located at base/configuration.php

Methods summary

protected
# __construct( )

Setup all variables values.

Setup all variables values.

final public
# setMode( array $mode )

Setup mode configuration variables.

Setup mode configuration variables.

Parameters

$mode
Silla.IO mode data.
final public mixed
# paths( string $name = null )

Retrieves a configuration path value.

Retrieves a configuration path value.

Parameters

$name
Path configuration variable name.

Returns

mixed

Throws

OutOfBoundsException
When requesting a none existing path.
final public mixed
# urls( string $name = null )

Retrieves a configuration URL value.

Retrieves a configuration URL value.

Parameters

$name
URL configuration variable name.

Returns

mixed

Throws

OutOfBoundsException
When requesting a none existing URL.
final public array
# modes( string $name = '' )

Retrieves Silla.IO modes.

Retrieves Silla.IO modes.

Parameters

$name
Name of the mode.

Returns

array
final public mixed
# mode( string $segment = null )

Retrieves current Silla.IO mode.

Retrieves current Silla.IO mode.

Parameters

$segment
Segment name of the mode.

Returns

mixed
final public static Core\Base\Configuration
# getInstance( )

Returns an instance of the Configuration object.

Returns an instance of the Configuration object.

Returns

Core\Base\Configuration
final public
# __clone( )

Cloning of Configuration is disallowed.

Cloning of Configuration is disallowed.

final protected array
# setupModes( array $modes )

Format and setup Silla.IO modes.

Format and setup Silla.IO modes.

Parameters

$modes
Array of Silla.IO modes to setup.

Returns

array
final public
# modifyPath( string $key, string $value )

Modifies configuration path.

Modifies configuration path.

Parameters

$key
Configuration path name.
$value
New value for configuration path.
final public
# modifyURL( string $key, string $value )

Modifies configuration URL.

Modifies configuration URL.

Parameters

$key
Configuration URL name.
$value
New value for configuration url.

Properties summary

public boolean[] $ASSETS

$ASSETS Assets Management options flags.

$ASSETS Assets Management options flags.

Example

cache Whether to cache all assets groups on the file system.
combine Whether to combine all assets groups in one file.
optimize Whether to minify assets.
# array( 'cache' => false, 'combine' => false, 'optimize' => false, )
public string[] $RENDER

$RENDER Render engine configuration.

$RENDER Render engine configuration.

Example

adapter Render adapter name.
# array( 'adapter' => 'Core\Modules\Render\Adapters\Smarty', 'options' => array( 'strip_white_space' => false, ), )
public string[] $ROUTER

$ROUTER Router related configuration options.

$ROUTER Router related configuration options.

Example

rewrite Whether to support url rewrite or not.
separator URL elements separator.
variables_prefix Routes variables notation prefix. Must be different from the 'separator'.
# array( 'rewrite' => true, 'separator' => '/', 'variables_prefix' => ':', )
public array $CACHE

$CACHE Cache related configuration options.

$CACHE Cache related configuration options.

Example

adapter Caching adapter name.
routes Whether to cache Routing routes.
labels Whether to cache Localisation labels.
db_schema Whether to cache Database Entity tables schemas.
database Database cache adapter database schema.
redis Redis cache adapter connection parameters.
# array( 'adapter' => 'FileSystem', 'routes' => false, 'labels' => false, 'db_schema' => false, 'database' => array( 'table_name' => 'cache', 'fields' => array( 'cache_key', 'value', 'expire', ), ), 'redis' => array( 'scheme' => 'tcp', 'host' => '127.0.0.1', 'port' => 6379, 'timeout' => 5.0, ), )
public (int|string)[] $MAILER

$MAILER Mailer configuration options.

$MAILER Mailer configuration options.

Example

type Type of the mailing infrastructure to use(Sendmail|SMTP).
identity Mailer identity signature.
credentials Mailer service credentials.
# array( 'type' => 'Sendmail', 'identity' => array( 'name' => 'Athlon Production', 'email' => 'hi@athlonproduction.com', ), 'credentials' => array( 'smtp' => array( 'host' => 'localhost', 'port' => '25', 'user' => '', 'password' => '', ), ), )
public (int|string)[] $DB

$DB DSN (Data source name).

$DB DSN (Data source name).

Example

adapter Adapter type (pdo_mysql|mysql|sqllite).
host Connection host name.
port Connection host port.
user User name.
password Password phrase.
name Database name.
tables_prefix Storage tables prefix.
encryption_key Database encryption key.
crypt_vector Initialization Vector value.
# array( 'adapter' => 'pdo_mysql', 'host' => 'localhost', 'port' => 3306, 'user' => '', 'password' => '', 'name' => '', 'tables_prefix' => '', 'encryption_key' => '25c6c7ff35bd13b0ff9979b151f2136c', 'crypt_vector' => 'dasn312321nssa1k', )
public array $I18N

$I18N Localisation configuration options if supported.

$I18N Localisation configuration options if supported.

Example

'support' boolean Whether to support localisation or not.
'default' string Default localization code.
'locales' array Supported localisations options ['url-value' => 'database-value'].
# array( 'support' => false, 'default' => 'en_US', 'locales' => array( 'en_US' => 'English (American)', ), )
public (int|string)[] $SESSION

$SESSION Session related configuration options.

$SESSION Session related configuration options.

Example

adapter Type of session. Possible values (Standard|DB).
name Name of the session (used as cookie name).
ttl Lifetime in seconds of cookie. If 0, until browser is restarted.
lifetime After specified minutes, stored data will be cleaned up by the garbage collection.
key_length Length of session unique id.
transparency Usage of transparent session id. Use with caution.
parameter Name of the transparent session id parameter.
# array( 'adapter' => 'Standard', 'name' => 'ATHSESSID', 'ttl' => 0, 'lifetime' => 60, 'key_length' => 32, 'transparency' => false, 'parameter' => 'ath', )
protected array $PATHS

$PATHS File Paths definition.

$PATHS File Paths definition.

Example

root Path to Silla.IO files location on the file system.
mode Path to Silla.IO current mode location.
labels Path to Silla.IO localisation labels location.
cache Path to Silla.IO file caches on the server.
tmp Path to Silla.IO temorary file storage location.
public Path to Silla.IO public accessible location.
uploads Path to Silla.IO uploads storage location.
vendor Path to Silla.IO vendor files location.
resources Path to Silla.IO resources files location.
assets Path to Silla.IO assets storage location['source', 'distribution'].
views Path to Silla.IO views['templates', 'compiled', 'config', 'cache'].
# array( 'root' => null, 'mode' => null, 'labels' => null, 'cache' => null, 'tmp' => null, 'public' => null, 'uploads' => null, 'vendor' => null, 'resources' => null, 'views' => array(), 'assets' => array(), )
protected string[] $URLS

$URLS URLS paths definition.

$URLS URLS paths definition.

Example

full Full URL path for the current Silla.IO instance.
relative Relative URL path for the current Silla.IO instance.
protocol Current URL request protocol type.
public URL path to the public accessible location.
assets URL path to the assets storage location.
uploads URL path to the uploads storage location.
# array( 'full' => null, 'relative' => null, 'protocol' => null, 'assets' => null, 'public' => null, 'uploads' => null, )
private array $MODES

$MODES Silla.IO Runtime Modes. Array representation of supported Silla.IO modes. Default mode(most common) is the last element the array.

$MODES Silla.IO Runtime Modes. Array representation of supported Silla.IO modes. Default mode(most common) is the last element the array.

Example

name Semantic name of the mode.
location File path to the mode files WITH trailing slash.
url URL prefix of the mode WITH trailing slash.
# array( array( 'name' => 'cms', 'location' => 'cms/', 'url' => 'cms/', ), array( 'name' => 'app', 'location' => 'app/', 'url' => '/', ), )
private array $MODE

$MODE Current mode.

$MODE Current mode.

# array()
protected static Core\Base\Configuration $instance

$instance Reference to the current instance of the Configuration object.

$instance Reference to the current instance of the Configuration object.

# null
Silla.IO API API documentation generated by ApiGen