kind property

  1. @protected
EntityKind<Int8Kind> kind
final

Kind for Int8Kind.

The purpose of annotation @protected is reducing accidental use.

Implementation

@protected
static final EntityKind<Int8Kind> kind = EntityKind<Int8Kind>(
  name: 'Int8Kind',
  define: (c) {
    final min = c.optionalInt32(
      id: 1,
      name: 'min',
      getter: (t) => t.min,
    );
    final max = c.optionalInt32(
      id: 2,
      name: 'max',
      getter: (t) => t.max,
    );
    c.constructorFromData = (data) => Int8Kind(
          min: data.get(min),
          max: data.get(max),
        );
  },
);