meta 1.0.4

  • CHANGELOG.md
  • Installing
  • Versions
  • --

1.0.4

  • Introduce @virtual to allow field overrides in strong mode (SDK issue 27384).

      import 'package:meta/meta.dart' show virtual;
      class Base {
        @virtual int x;
      }
      class Derived extends Base {
        int x;
    
        // Expose the hidden storage slot:
        int get superX => super.x;
        set superX(int v) { super.x = v; }
      }
    

1.0.3

  • Introduce @checked to override a method and tighten a parameter type (SDK issue 25578).

      import 'package:meta/meta.dart' show checked;
      class View {
        addChild(View v) {}
      }
      class MyView extends View {
        // this override is legal, it will check at runtime if we actually
        // got a MyView.
        addChild(@checked MyView v) {}
      }
      main() {
        dynamic mv = new MyView();
        mv.addChild(new View()); // runtime error
      }
    

1.0.2

  • Introduce @visibleForTesting annotation for declarations that may be referenced only in the library or in a test.

1.0.1

  • Updated @factory to allow statics and methods returning null.

1.0.0

  • First stable API release.

0.12.2

  • Updated @protected to include implemented interfaces (linter#252).

0.12.1

  • Fixed markdown in dartdocs.

0.12.0

  • Introduce @optionalTypeArgs annotation for classes whose type arguments are to be treated as optional.

0.11.0

  • Added new Required constructor with a means to specify a reason to explain why a parameter is required.

0.10.0

  • Introduce @factory annotation for methods that must either be abstract or must return a newly allocated object.
  • Introduce @literal annotation that indicates that any invocation of a constructor must use the keyword const unless one or more of the arguments to the constructor is not a compile-time constant.

0.9.0

  • Introduce @protected annotation for members that must only be called from instance members of subclasses.
  • Introduce @required annotation for optional parameters that should be treated as required.
  • Introduce @mustCallSuper annotation for methods that must be invoked by all overriding methods.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  meta: ^1.0.4

2. Install it

You can install packages from the command line:

with pub:


$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:meta/meta.dart';
  
Version Uploaded Documentation Archive
1.1.6 Jul 18, 2018 Go to the documentation of meta 1.1.6 Download meta 1.1.6 archive
1.1.5 May 3, 2018 Go to the documentation of meta 1.1.5 Download meta 1.1.5 archive
1.1.2 Sep 28, 2017 Go to the documentation of meta 1.1.2 Download meta 1.1.2 archive
1.1.1 Jul 19, 2017 Go to the documentation of meta 1.1.1 Download meta 1.1.1 archive
1.1.0 Jul 10, 2017 Go to the documentation of meta 1.1.0 Download meta 1.1.0 archive
1.0.5 Mar 31, 2017 Go to the documentation of meta 1.0.5 Download meta 1.0.5 archive
1.0.4 Sep 20, 2016 Go to the documentation of meta 1.0.4 Download meta 1.0.4 archive
1.0.3 Sep 14, 2016 Go to the documentation of meta 1.0.3 Download meta 1.0.3 archive
1.0.2 Aug 15, 2016 Go to the documentation of meta 1.0.2 Download meta 1.0.2 archive
1.0.1 Jun 27, 2016 Go to the documentation of meta 1.0.1 Download meta 1.0.1 archive

All 85 versions...

Popularity:
Describes how popular the package is relative to other packages. [more]
--
Health:
Code health derived from static analysis. [more]
--
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
--
Overall:
Weighted score of the above. [more]
--
Learn more about scoring.

This package version is not analyzed, because it is more than two years old. Check the latest stable version for its analysis.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.12.0 <2.0.0