Provides runtime support for a Dart implementation of protobufs.
Typically one do not need to import this library–only libraries
generated by the protoc plugin import this library directly.
If your library or application uses generated protobuf libraries, add this
library as a dependency.
- Unknown enum values are ignored when parsing JSON, instead of throwing an
- Resolved a strong-mode error.
- Performance: Avoid excessive cloning in merge.
- Performance: Use code patterns that dart2js handles better.
- fix zigzag function so all coded buffer reader tests work on dart2js.
- make PbMixin constructor public for use within protoc plugin.
- Revert previous change because it causes strong mode type errorin the generated code. We will revisit this in a new version ofmixin support.
- Use a more refined implementation of
- Performance: eliminate some dynamic calls.
- Bugfix: remove dependency on
pkg/crypto for real.
- Experimental support for strong mode.
- Fixed an issue with GeneratedMessage operator== and Map mixins
- Added declaration of GeneratedMessage clone method
- Support the latest version of package
- Reorganized internals to improve performance. We now store
field values in a list instead of a map. Private properties
and methods are all moved to the _FieldSet class. There
are new entry points for generated getters, hazzers, and
setters. Improved JSON decoding performance.
- Dropped compatibility with .pb.dart files before 0.4.2
by removing internal constants from GeneratedMessage. Also,
protoc plugins before 0.5.0 won't work.
- Renamed FieldType to PbFieldType.
0.4.1 - DO NOT USE
- added FieldType class. It turned out that FieldType is a
commonly used name, even in .proto files. This is renamed to
PbFieldType in 0.4.2.
- Added support for observing field changes.
For now, this can only be enabled by using a mixin to override
the eventPlugin getter.
- Removed optional third parameter from setField().
It was only intended for internal use, and could be used to
defeat type checks on fields.
- clearExtension() removes the value and extension in all cases.
(Before, the extension would be kept and the list cleared
for repeated fields.)
- Upcoming: clearField() will require its argument to be a known
tag number (which could be an extension). For now, this is only
enforced when a mixin provides an eventPlugin.
- Add ReadonlyMessageMixin. The generated message classes use this to
for the default values of message fields.
- Add meta.dart which declares reserved names for the plugin.
- Add GeneratedService and ProtobufClient interfaces.
- Add experimental mixins_meta library
- Add experimental PbMapMixin class (in a separate library).
- Fix bug where ExtensionRegistry would not be used for nested messages.
- Added mergeFromMap() and writeToJsonMap()
- Fixed an analyzer warning.
- Bugfix for
setRange(): Do not assume Iterable has a
- Simplify some types used in is checks and correct PbList to match the
- signature of the List setRange method.
- Bugfix for incorrect decoding of protobuf messages: Uint8List views with
non-zero offsets were handled incorrectly.
Allow constants as field initial values as well as creation thunks to reduce
generated code size.
Improve the performance of reading a protobuf buffer.
Fixed truncation error in least significant bits with large Int64 constants.
1. Depend on it
Add this to your package's pubspec.yaml file:
2. Install it
You can install packages from the command line:
$ pub get
Alternatively, your editor might support pub. Check the docs for your editor to learn more.
3. Import it
Now in your Dart code, you can use:
||Apr 20, 2017
Go to the documentation of protobuf 0.5.4
Download protobuf 0.5.4 archive
||Mar 29, 2017
Go to the documentation of protobuf 0.5.3+2
Download protobuf 0.5.3+2 archive
||Mar 27, 2017
Go to the documentation of protobuf 0.5.3+1
Download protobuf 0.5.3+1 archive
||Sep 1, 2016
Go to the documentation of protobuf 0.5.3
Download protobuf 0.5.3 archive
||Jun 22, 2016
Go to the documentation of protobuf 0.5.2
Download protobuf 0.5.2 archive
||Jun 1, 2016
Go to the documentation of protobuf 0.5.1+4
Download protobuf 0.5.1+4 archive
||May 25, 2016
Go to the documentation of protobuf 0.5.1+3
Download protobuf 0.5.1+3 archive
||Apr 22, 2016
Go to the documentation of protobuf 0.5.1+2
Download protobuf 0.5.1+2 archive
||Apr 15, 2016
Go to the documentation of protobuf 0.5.1+1
Download protobuf 0.5.1+1 archive
||Apr 11, 2016
Go to the documentation of protobuf 0.5.1
Download protobuf 0.5.1 archive
All 35 versions...