AttributeLocalizations class abstract

Callers can lookup localized strings with an instance of AttributeLocalizations returned by AttributeLocalizations.of(context).

Applications need to include AttributeLocalizations.delegate() in their app's localizationDelegates list, and the locales they support in the app's supportedLocales list. For example:

import 'lib/attribute_localizations.dart';

return MaterialApp(
  localizationsDelegates: AttributeLocalizations.localizationsDelegates,
  supportedLocales: AttributeLocalizations.supportedLocales,
  home: MyApplicationHome(),
);

Update pubspec.yaml

Please make sure to update your pubspec.yaml to include the following packages:

dependencies:
  # Internationalization support.
  flutter_localizations:
    sdk: flutter
  intl: any # Use the pinned version from flutter_localizations

  # Rest of dependencies

iOS Applications

iOS applications define key application metadata, including supported locales, in an Info.plist file that is built into the application bundle. To configure the locales supported by your app, you’ll need to edit this file.

First, open your project’s ios/Runner.xcworkspace Xcode workspace file. Then, in the Project Navigator, open the Info.plist file under the Runner project’s Runner folder.

Next, select the Information Property List item, select Add Item from the Editor menu, then select Localizations from the pop-up menu.

Select and expand the newly-created Localizations item then, for each locale your application supports, add a new item and select the locale you wish to add from the pop-up menu in the Value field. This list should be consistent with the languages listed in the AttributeLocalizations.supportedLocales property.

Implementers

Constructors

AttributeLocalizations(String locale)

Properties

address String
No description provided for @address.
no setter
age String
No description provided for @age.
no setter
available String
No description provided for @available.
no setter
city String
No description provided for @city.
no setter
content String
No description provided for @content.
no setter
country String
No description provided for @country.
no setter
date String
No description provided for @date.
no setter
day String
No description provided for @day.
no setter
desc String
No description provided for @desc.
no setter
description String
No description provided for @description.
no setter
email String
No description provided for @email.
no setter
excerpt String
No description provided for @excerpt.
no setter
firstName String
No description provided for @firstName.
no setter
gender String
No description provided for @gender.
no setter
hashCode int
The hash code for this object.
no setterinherited
hour String
No description provided for @hour.
no setter
lastName String
No description provided for @lastName.
no setter
localeName String
final
middleName String
No description provided for @middleName.
no setter
minute String
No description provided for @minute.
no setter
mobile String
No description provided for @mobile.
no setter
month String
No description provided for @month.
no setter
name String
No description provided for @name.
no setter
password String
No description provided for @password.
no setter
passwordConfirmation String
No description provided for @passwordConfirmation.
no setter
phone String
No description provided for @phone.
no setter
price String
No description provided for @price.
no setter
q String
No description provided for @q.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
second String
No description provided for @second.
no setter
sex String
No description provided for @sex.
no setter
size String
No description provided for @size.
no setter
time String
No description provided for @time.
no setter
title String
No description provided for @title.
no setter
username String
No description provided for @username.
no setter
year String
No description provided for @year.
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

of(BuildContext context) AttributeLocalizations?

Constants

delegate → const LocalizationsDelegate<AttributeLocalizations>
localizationsDelegates → const List<LocalizationsDelegate>
A list of this localizations delegate along with the default localizations delegates.
supportedLocales → const List<Locale>
A list of this localizations delegate's supported locales.