Skip to content

Language

Viames Marino edited this page Oct 19, 2026 · 2 revisions

Pair framework: Language

Pair\Models\Language stores language settings and country association.

Main methods

  • getDefaultCountry(): ?Country

Lifecycle/config:

  • _init() defines fields and validations

Implementation example

use Pair\Models\Language;

$lang = Language::firstWhere('code', 'en');
$defaultCountry = $lang?->getDefaultCountry();

Notes

  • Supports locale-aware defaults for formatting and content routing.

See also: Country, Locale, Translator.

Clone this wiki locally