FieldInfo<T> constructor
Null safety
- String name,
- int tagNumber,
- int? index,
- int type,
- {dynamic defaultOrMaker,
- CreateBuilderFunc? subBuilder,
- ValueOfFunc? valueOf,
- List<
ProtobufEnum> ? enumValues, - ProtobufEnum? defaultEnumValue,
- String? protoName}
Implementation
FieldInfo(this.name, this.tagNumber, this.index, this.type,
{dynamic defaultOrMaker,
this.subBuilder,
this.valueOf,
this.enumValues,
this.defaultEnumValue,
String? protoName})
: makeDefault = findMakeDefault(type, defaultOrMaker),
check = null,
protoName = protoName ?? _unCamelCase(name),
assert(type != 0),
assert(!_isGroupOrMessage(type) ||
subBuilder != null ||
_isMapField(type)),
assert(!_isEnum(type) || valueOf != null);