class Locale extends BaseResource

Value object encoding a locale.

Properties

protected Client $client from BaseResource
protected SystemProperties $sys from BaseResource
protected string $code
protected string $name
protected string|null $fallbackCode
protected bool $default

Methods

__construct(array $data)

Resources in this SDK should not be built using $new Class().

asLink()

{@inheritdoc}

getId()

{@inheritdoc}

getType()

{@inheritdoc}

string
getCode()

Returns the locale code.

string
getName()

Returns the human readable name.

bool
isDefault()

Returns true if this is the default locale for the space.

string|null
getFallbackCode()

Returns the code of the locale used for for the fallback.

jsonSerialize()

{@inheritdoc}

Details

in BaseResource at line 36
protected __construct(array $data)

Resources in this SDK should not be built using $new Class().

This method is only useful in testing environments, where the resource needs to be subclasses and this method made public.

Parameters

array $data

in BaseResource at line 50
SystemProperties getSystemProperties()

{@inheritdoc}

Return Value

SystemProperties

{@inheritdoc}

in BaseResource at line 69
getId()

{@inheritdoc}

in BaseResource at line 77
getType()

{@inheritdoc}

at line 42
string getCode()

Returns the locale code.

Return Value

string

at line 52
string getName()

Returns the human readable name.

Return Value

string

at line 62
bool isDefault()

Returns true if this is the default locale for the space.

Return Value

bool

at line 72
string|null getFallbackCode()

Returns the code of the locale used for for the fallback.

Return Value

string|null

at line 80
jsonSerialize()

{@inheritdoc}