class Field
extends FieldBase
import { Field } from "https://deno.land/x/steam_trader@v0.4.0/types/protobuf.d.ts";
Reflected message field.
Constructors
new
Field(name: string,
id: number,
type: string,
rule?: (string | { [k: string]: any; }),
extend?: (string | { [k: string]: any; }),
options?: { [k: string]: any; },
Constructs a new message field instance. Note that map fields have their own class.
Static Methods
d<T extends >(): FieldDecorator
fieldId: number,
fieldType: (),
| "double"
| "float"
| "int32"
| "uint32"
| "sint32"
| "fixed32"
| "sfixed32"
| "int64"
| "uint64"
| "sint64"
| "fixed64"
| "sfixed64"
| "string"
| "bool"
| "bytes"
| object
fieldRule?: ("optional" | "required" | "repeated"),
defaultValue?: T,
Field decorator (TypeScript).
d<T extends Message<T>>(): FieldDecorator
fieldId: number,
fieldType: (Constructor<T> | string),
fieldRule?: ("optional" | "required" | "repeated"),
Field decorator (TypeScript).