System\Helpers\System

Overview

System Helper

See Also

Protected Properties

protected bool $hasDatabaseCache

hasDatabaseCache helps multiple calls to hasDatabase()

protected $listModulesCache

listModulesCache helps multiple calls to listModules()


Public Methods

public checkBaseDir()

public checkBaseDir($filePath): bool 

checkBaseDir returns true if a file path is inside the base directory

public checkDebugMode()

public checkDebugMode(): bool 

checkDebugMode returns true if debug mode is on

public checkSafeMode()

public checkSafeMode(): bool 

checkSafeMode will return true if cms.safe_mode config is enabled

public composerToOctoberCode()

public composerToOctoberCode($name): string 

composerToOctoberCode converts a composer code to an October CMS code rainlab/mailchimp-plugin-9999999-dev -> rainlab.mailchimp

public hasDatabase()

public hasDatabase(): bool 

hasDatabase checks if a database connection can be made and the migrations table exists

public hasModule()

public hasModule($name): bool 

hasModule checks for a module inside the system

public listModules()

public listModules(): array 

listModules returns a list of module names that are enabled

public octoberToComposerCode()

public octoberToComposerCode($name, $type, $prefix = false): string 

octoberToComposerCode converts an October CMS code to a composer code RainLab.Mailchimp -> rainlab/mailchimp-plugin