PHP 클래스 SimpleSAML_XHTML_Template, simplesamlphp

저자: Andreas Åkre Solberg, UNINETT AS. ([email protected])
파일 보기 프로젝트 열기: simplesamlphp/simplesamlphp 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$data array The data associated with this template, accessible within the template itself.

공개 메소드들

메소드 설명
__construct ( SimpleSAML_Configuration $configuration, string $template, string | null $defaultDictionary = null ) Constructor
getAttributeTranslation ( $name ) : string
getLanguage ( ) : string
getLanguageCookie ( ) : null | string
getTag ( $tag ) : array
getTranslation ( $translations ) Temporary wrapper for \SimpleSAML\Locale\Translate::getPreferredTranslation().
getTranslator ( ) : Translate Return the internal translator object used by this template.
includeInlineTranslation ( $tag, $translation ) Wraps Translate->includeInlineTranslation()
includeLanguageFile ( $file, null $otherConfig = null )
lang_merge ( array $def, array $lang ) : array Merge two translation arrays.
noop ( $tag ) Behave like Language->noop to mark a tag for translation but actually do it later.
setLanguage ( $language, boolean $setLanguageCookie = true )
setLanguageCookie ( $language )
show ( ) Show the template to the user.
t ( $tag, $replacements = [], $fallbackdefault = true, $oldreplacements = [], $striptags = false ) Wrap Language->t to translate tag into the current language, with a fallback to english.

비공개 메소드들

메소드 설명
findModuleAndTemplateName ( string $template ) : array Find module the template is in, if any
findModuleTemplateDirs ( ) * Which enabled modules have templates?
findTemplatePath ( string $template, $throw_exception = true ) : string Find template path.
findThemeTemplateDirs ( ) * Add overriding templates in configured theme
generateLanguageBar ( ) : array Generate an array for its use in the language bar, indexed by the ISO 639-2 codes of the languages available, containing their localized names and the URL that should be used in order to change to that language.
getLanguageList ( ) Wraps Language->getLanguageList
includeAtTemplateBase ( $file ) Includes a file relative to the template base directory.
isLanguageRTL ( ) Wrap Language->isLanguageRTL
normalizeTemplateName ( string $templateName ) : string Normalize the name of the template to one of the possible alternatives.
setupTwig ( ) Setup twig.
setupTwigTemplatepaths ( ) : Twig_Loader_Filesystem | false Set up the places where twig can look for templates.
twigDefaultContext ( ) Set some default context

메소드 상세

__construct() 공개 메소드

Constructor
public __construct ( SimpleSAML_Configuration $configuration, string $template, string | null $defaultDictionary = null )
$configuration SimpleSAML_Configuration Configuration object
$template string Which template file to load
$defaultDictionary string | null The default dictionary where tags will come from.

getAttributeTranslation() 공개 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Language::getLanguage() instead.
public getAttributeTranslation ( $name ) : string
$name
리턴 string

getLanguage() 공개 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Language::getLanguage() instead.
public getLanguage ( ) : string
리턴 string

getLanguageCookie() 공개 정적인 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Language::getLanguageCookie() instead.
public static getLanguageCookie ( ) : null | string
리턴 null | string

getTag() 공개 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Translate::getTag() instead.
public getTag ( $tag ) : array
$tag
리턴 array

getTranslation() 공개 메소드

Temporary wrapper for \SimpleSAML\Locale\Translate::getPreferredTranslation().
사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Translate::getPreferredTranslation() instead.
public getTranslation ( $translations )

getTranslator() 공개 메소드

Return the internal translator object used by this template.
public getTranslator ( ) : Translate
리턴 SimpleSAML\Locale\Translate The translator that will be used with this template.

includeInlineTranslation() 공개 메소드

Wraps Translate->includeInlineTranslation()
또한 보기: SimpleSAML\Locale\Translate::includeInlineTranslation()
사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Translate::includeInlineTranslation() instead.
public includeInlineTranslation ( $tag, $translation )

includeLanguageFile() 공개 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Translate::includeLanguageFile() instead.
public includeLanguageFile ( $file, null $otherConfig = null )
$file
$otherConfig null

lang_merge() 공개 정적인 메소드

Merge two translation arrays.
사용 중단: This method will be removed in SimpleSAMLphp 2.0. Please use array_merge_recursive() instead.
public static lang_merge ( array $def, array $lang ) : array
$def array The array holding string definitions.
$lang array The array holding translations for every string.
리턴 array The recursive merge of both arrays.

noop() 공개 정적인 메소드

Behave like Language->noop to mark a tag for translation but actually do it later.
또한 보기: SimpleSAML\Locale\Translate::noop()
사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Translate::noop() instead.
public static noop ( $tag )

setLanguage() 공개 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Language::setLanguage() instead.
public setLanguage ( $language, boolean $setLanguageCookie = true )
$language
$setLanguageCookie boolean

setLanguageCookie() 공개 정적인 메소드

사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Language::setLanguageCookie() instead.
public static setLanguageCookie ( $language )
$language

show() 공개 메소드

Show the template to the user.
public show ( )

t() 공개 메소드

Wrap Language->t to translate tag into the current language, with a fallback to english.
또한 보기: SimpleSAML\Locale\Translate::t()
사용 중단: This method will be removed in SSP 2.0. Please use \SimpleSAML\Locale\Translate::t() instead.
public t ( $tag, $replacements = [], $fallbackdefault = true, $oldreplacements = [], $striptags = false )

프로퍼티 상세

$data 공개적으로 프로퍼티

The data associated with this template, accessible within the template itself.
public array $data
리턴 array