Skip to content

Commit

Permalink
docs(package_info_plus): Add platform specific documentation (#2845)
Browse files Browse the repository at this point in the history
  • Loading branch information
miquelbeltran committed Apr 22, 2024
1 parent fd0511c commit ad06a23
Showing 1 changed file with 38 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,23 +92,56 @@ class PackageInfo {
return _fromPlatform!;
}

/// The app name. `CFBundleDisplayName` on iOS, `application/label` on Android.
/// The app name.
///
/// - `CFBundleDisplayName` on iOS and macOS, falls back to `CFBundleName`.
/// Defined in the `info.plist` and/or product target in xcode.
/// - `application/label` on Android.
/// Defined in `AndroidManifest.xml` or String resources.
/// - `app_name` from `version.json` on Web.
/// Defined in the `manifest.json`.
/// - `app_name` from `version.json` on Linux.
/// Defined in the `CMakeLists.txt` file.
/// - `ProductName` from the compiled executable file on Windows.
/// Defined in the `Runner.rc` file.
final String appName;

/// The package name. `bundleIdentifier` on iOS, `getPackageName` on Android.
/// The package name.
///
/// - `bundleIdentifier` on iOS and macOS.
/// Defined in the product target in xcode.
/// - `packageName` on Android.
/// Defined in `build.gradle` as `applicationId`.
/// - `package_name` from `version.json` on Web and Linux
/// Generated by Flutter.
/// - `InternalName` from the compiled executable file on Windows.
/// Defined in the `Runner.rc` file.
final String packageName;

/// The package version. `CFBundleShortVersionString` on iOS, `versionName` on Android.
/// The package version.
/// Generated from the version in `pubspec.yaml`.
///
/// - `CFBundleShortVersionString` on iOS and macOS.
/// - `versionName` on Android.
/// - `version` from `version.json` on Web and Linux.
/// - `ProductVersion` from the compiled executable file on Windows.
final String version;

/// The build number. `CFBundleVersion` on iOS, `versionCode` on Android.
/// The build number.
/// Generated from the version in `pubspec.yaml`.
///
/// - `CFBundleVersion` on iOS and macOs.
/// - `versionCode` on Android.
/// - `build_number` from `version.json` on Web and Linux.
/// - `ProductVersion` from the compiled executable file on Windows.
///
/// Note, on iOS if an app has no buildNumber specified this property will return version
/// Docs about CFBundleVersion: https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleversion
final String buildNumber;

/// The build signature.
/// Empty string on iOS.
/// SHA-256 signing key signature (hex) on Android.
/// Empty string on all the other platforms.
final String buildSignature;

/// The installer store. Indicates through which store this application was installed.
Expand Down

0 comments on commit ad06a23

Please sign in to comment.