PHP 클래스 Netson\L4gettext\L4gettext

파일 보기 프로젝트 열기: netson/l4gettext

보호된 프로퍼티들

프로퍼티 타입 설명
$encoding string variable holds the current encoding
$locale string variable holds the current locale

공개 메소드들

메소드 설명
__construct ( ) constructor method accepts an optional $locale, otherwise the default will be used
__toString ( ) : string method to dump the current locale/encoding settings to string
createFolder ( string $path ) : L4gettext method which auto creates the LC_MESSAGES folder for each set locale, if they do not exist yet
getEncoding ( ) : string method to fetch the set encoding
getLocale ( ) : string method to fetch the set locale
getLocaleAndEncoding ( ) : string method to merge the locale and encoding into a single string
hasEncoding ( ) : boolean method to check if an encoding has been set
hasLocale ( ) : boolean method to check if a locale has been set
setEncoding ( string $encoding ) : L4gettext method to set the encoding
setLocale ( string $locale ) : L4gettext method to set the locale
setTextDomain ( string $textdomain, string $path ) : L4gettext method to set the text domain

메소드 상세

__construct() 공개 메소드

constructor method accepts an optional $locale, otherwise the default will be used
public __construct ( )

__toString() 공개 메소드

method to dump the current locale/encoding settings to string
public __toString ( ) : string
리턴 string

createFolder() 공개 메소드

method which auto creates the LC_MESSAGES folder for each set locale, if they do not exist yet
public createFolder ( string $path ) : L4gettext
$path string
리턴 L4gettext

getEncoding() 공개 메소드

method to fetch the set encoding
public getEncoding ( ) : string
리턴 string

getLocale() 공개 메소드

method to fetch the set locale
public getLocale ( ) : string
리턴 string

getLocaleAndEncoding() 공개 메소드

method to merge the locale and encoding into a single string
public getLocaleAndEncoding ( ) : string
리턴 string

hasEncoding() 공개 메소드

method to check if an encoding has been set
public hasEncoding ( ) : boolean
리턴 boolean

hasLocale() 공개 메소드

method to check if a locale has been set
public hasLocale ( ) : boolean
리턴 boolean

setEncoding() 공개 메소드

method to set the encoding
public setEncoding ( string $encoding ) : L4gettext
$encoding string
리턴 L4gettext

setLocale() 공개 메소드

method to set the locale
public setLocale ( string $locale ) : L4gettext
$locale string
리턴 L4gettext

setTextDomain() 공개 메소드

method to set the text domain
public setTextDomain ( string $textdomain, string $path ) : L4gettext
$textdomain string
$path string
리턴 L4gettext

프로퍼티 상세

$encoding 보호되어 있는 프로퍼티

variable holds the current encoding
protected string $encoding
리턴 string

$locale 보호되어 있는 프로퍼티

variable holds the current locale
protected string $locale
리턴 string