Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Timestamp
    • MockProtoTimestamp

Index

Constructors

constructor

Properties

nanos

nanos: number

seconds

seconds: number

Static extensions

extensions: object

Type declaration

  • [key: number]: ExtensionFieldInfo<Message>

Static extensionsBinary

extensionsBinary: object

Type declaration

  • [key: number]: ExtensionFieldBinaryInfo<Message>

Methods

clone

  • clone(): Message
  • Returns Message

cloneMessage

  • cloneMessage(): Message
  • Returns Message

fromDate

  • fromDate(date: Date): void
  • Parameters

    • date: Date

    Returns void

getExtension

  • getExtension<T>(fieldInfo: ExtensionFieldInfo<T>): T
  • Type parameters

    • T

    Parameters

    • fieldInfo: ExtensionFieldInfo<T>

    Returns T

getJsPbMessageId

  • getJsPbMessageId(): string
  • Returns string

getNanos

  • getNanos(): number
  • Returns number

getSeconds

  • getSeconds(): number

readBinaryExtension

  • readBinaryExtension(proto: Message, reader: BinaryReader, extensions: object, setExtensionFn: function): void
  • Parameters

    • proto: Message
    • reader: BinaryReader
    • extensions: object
      • [key: number]: ExtensionFieldBinaryInfo<Message>
    • setExtensionFn: function
        • <T>(fieldInfo: ExtensionFieldInfo<T>, val: T): void
        • Type parameters

          • T

          Parameters

          • fieldInfo: ExtensionFieldInfo<T>
          • val: T

          Returns void

    Returns void

serializeBinary

  • serializeBinary(): Uint8Array
  • Returns Uint8Array

serializeBinaryExtensions

  • serializeBinaryExtensions(proto: Message, writer: BinaryWriter, extensions: object, getExtensionFn: function): void
  • Parameters

    • proto: Message
    • writer: BinaryWriter
    • extensions: object
      • [key: number]: ExtensionFieldBinaryInfo<Message>
    • getExtensionFn: function
        • <T>(fieldInfo: ExtensionFieldInfo<T>): T
        • Type parameters

          • T

          Parameters

          • fieldInfo: ExtensionFieldInfo<T>

          Returns T

    Returns void

setExtension

  • setExtension<T>(fieldInfo: ExtensionFieldInfo<T>, value: T): void
  • Type parameters

    • T

    Parameters

    • fieldInfo: ExtensionFieldInfo<T>
    • value: T

    Returns void

setNanos

  • setNanos(value: number): void
  • Parameters

    • value: number

    Returns void

setSeconds

  • setSeconds(value: number): void
  • Parameters

    • value: number

    Returns void

toArray

  • toArray(): Message.MessageArray
  • Returns Message.MessageArray

toDate

  • toDate(): Date

toObject

  • toObject(includeInstance?: boolean): AsObject
  • Parameters

    • Optional includeInstance: boolean

    Returns AsObject

toString

  • toString(): string
  • Returns string

Static addToRepeatedField

  • addToRepeatedField(msg: Message, fieldNumber: number, value: any, index?: number): void
  • Parameters

    • msg: Message
    • fieldNumber: number
    • value: any
    • Optional index: number

    Returns void

Static addToRepeatedWrapperField

  • addToRepeatedWrapperField<T>(msg: Message, fieldNumber: number, value: T | undefined, ctor: object, index?: number): T
  • Type parameters

    • T: Message

    Parameters

    • msg: Message
    • fieldNumber: number
    • value: T | undefined
    • ctor: object
      • constructor: function
        • new __type(): T
        • Returns T

    • Optional index: number

    Returns T

Static bytesAsB64

  • bytesAsB64(bytes: Uint8Array): string
  • Parameters

    • bytes: Uint8Array

    Returns string

Static bytesAsU8

  • bytesAsU8(str: string): Uint8Array
  • Parameters

    • str: string

    Returns Uint8Array

Static bytesListAsB64

  • bytesListAsB64(bytesList: Uint8Array[]): string[]
  • Parameters

    • bytesList: Uint8Array[]

    Returns string[]

Static bytesListAsU8

  • bytesListAsU8(strList: string[]): Uint8Array[]
  • Parameters

    • strList: string[]

    Returns Uint8Array[]

Static clone

  • clone<T>(msg: T): T
  • Type parameters

    • T: Message

    Parameters

    • msg: T

    Returns T

Static cloneMessage

  • cloneMessage<T>(msg: T): T
  • Type parameters

    • T: Message

    Parameters

    • msg: T

    Returns T

Static compareExtensions

  • compareExtensions(extension1: __type, extension2: __type): boolean
  • Parameters

    • extension1: __type
    • extension2: __type

    Returns boolean

Static compareFields

  • compareFields(field1: any, field2: any): boolean
  • Parameters

    • field1: any
    • field2: any

    Returns boolean

Static computeOneofCase

  • computeOneofCase(msg: Message, oneof: number[]): number
  • Parameters

    • msg: Message
    • oneof: number[]

    Returns number

Static copyInto

  • copyInto(fromMessage: Message, toMessage: Message): void
  • Parameters

    • fromMessage: Message
    • toMessage: Message

    Returns void

Static deserializeBinary

  • deserializeBinary(bytes: Uint8Array): Timestamp
  • Parameters

    • bytes: Uint8Array

    Returns Timestamp

Static deserializeBinaryFromReader

  • deserializeBinaryFromReader(message: Timestamp, reader: BinaryReader): Timestamp
  • Parameters

    • message: Timestamp
    • reader: BinaryReader

    Returns Timestamp

Static difference

  • difference<T>(m1: T, m2: T): T
  • Type parameters

    • T: Message

    Parameters

    • m1: T
    • m2: T

    Returns T

Static equals

  • equals(m1: Message, m2: Message): boolean
  • Parameters

    • m1: Message
    • m2: Message

    Returns boolean

Static getField

  • getField(msg: Message, fieldNumber: number): FieldValue | null
  • Parameters

    • msg: Message
    • fieldNumber: number

    Returns FieldValue | null

Static getFieldWithDefault

  • getFieldWithDefault<T>(msg: Message, fieldNumber: number, defaultValue: T): T
  • Type parameters

    • T

    Parameters

    • msg: Message
    • fieldNumber: number
    • defaultValue: T

    Returns T

Static getMapField

  • getMapField(msg: Message, fieldNumber: number, noLazyCreate: boolean, valueCtor: Message): Map<any, any>
  • Parameters

    • msg: Message
    • fieldNumber: number
    • noLazyCreate: boolean
    • valueCtor: Message

    Returns Map<any, any>

Static getOptionalFloatingPointField

  • getOptionalFloatingPointField(msg: Message, fieldNumber: number): number | undefined
  • Parameters

    • msg: Message
    • fieldNumber: number

    Returns number | undefined

Static getRepeatedFloatingPointField

  • getRepeatedFloatingPointField(msg: Message, fieldNumber: number): number[]
  • Parameters

    • msg: Message
    • fieldNumber: number

    Returns number[]

Static getRepeatedWrapperField

  • getRepeatedWrapperField<T>(msg: Message, ctor: object, fieldNumber: number): T[]
  • Type parameters

    • T: Message

    Parameters

    • msg: Message
    • ctor: object
      • constructor: function
        • new __type(): T
        • Returns T

    • fieldNumber: number

    Returns T[]

Static getWrapperField

  • getWrapperField<T>(msg: Message, ctor: object, fieldNumber: number, required?: number): T
  • Type parameters

    • T: Message

    Parameters

    • msg: Message
    • ctor: object
      • constructor: function
        • new __type(): T
        • Returns T

    • fieldNumber: number
    • Optional required: number

    Returns T

Static initialize

  • initialize(msg: Message, data: Message.MessageArray, messageId: string | number, suggestedPivot: number, repeatedFields?: number[], oneofFields?: number[][] | null): void
  • Parameters

    • msg: Message
    • data: Message.MessageArray
    • messageId: string | number
    • suggestedPivot: number
    • Optional repeatedFields: number[]
    • Optional oneofFields: number[][] | null

    Returns void

Static registerMessageType

  • registerMessageType(id: number, constructor: Message): void
  • Parameters

    • id: number
    • constructor: Message

    Returns void

Static serializeBinaryToWriter

  • serializeBinaryToWriter(message: Timestamp, writer: BinaryWriter): void
  • Parameters

    • message: Timestamp
    • writer: BinaryWriter

    Returns void

Static setField

  • setField(msg: Message, fieldNumber: number, value: FieldValue): void
  • Parameters

    • msg: Message
    • fieldNumber: number
    • value: FieldValue

    Returns void

Static setOneofField

  • setOneofField(msg: Message, fieldNumber: number, oneof: number[], value: FieldValue): void
  • Parameters

    • msg: Message
    • fieldNumber: number
    • oneof: number[]
    • value: FieldValue

    Returns void

Static setOneofWrapperField

  • setOneofWrapperField(msg: Message, fieldNumber: number, oneof: number[], value: any): void
  • Parameters

    • msg: Message
    • fieldNumber: number
    • oneof: number[]
    • value: any

    Returns void

Static setRepeatedWrapperField

  • setRepeatedWrapperField<T>(msg: Message, fieldNumber: number, value?: T[]): void
  • Type parameters

    • T: Message

    Parameters

    • msg: Message
    • fieldNumber: number
    • Optional value: T[]

    Returns void

Static setWrapperField

  • setWrapperField<T>(msg: Message, fieldNumber: number, value?: Map<any, any> | T): void
  • Type parameters

    • T: Message

    Parameters

    • msg: Message
    • fieldNumber: number
    • Optional value: Map<any, any> | T

    Returns void

Static toMap

  • toMap(field: any[], mapKeyGetterFn: function, toObjectFn?: Message.StaticToObject, includeInstance?: boolean): void
  • Parameters

    • field: any[]
    • mapKeyGetterFn: function
        • (field: any): string
        • Parameters

          • field: any

          Returns string

    • Optional toObjectFn: Message.StaticToObject
    • Optional includeInstance: boolean

    Returns void

Static toObject

  • toObject(includeInstance: boolean, msg: Timestamp): AsObject
  • Parameters

    • includeInstance: boolean
    • msg: Timestamp

    Returns AsObject

Static toObjectExtension

  • toObjectExtension(msg: Message, obj: __type, extensions: object, getExtensionFn: function, includeInstance?: boolean): void
  • Parameters

    • msg: Message
    • obj: __type
    • extensions: object
      • [key: number]: ExtensionFieldInfo<Message>
    • getExtensionFn: function
        • (fieldInfo: ExtensionFieldInfo<Message>): Message
        • Parameters

          • fieldInfo: ExtensionFieldInfo<Message>

          Returns Message

    • Optional includeInstance: boolean

    Returns void

Static toObjectList

  • toObjectList<T>(field: T[], toObjectFn: function, includeInstance?: boolean): Array<__type>
  • Type parameters

    • T: Message

    Parameters

    • field: T[]
    • toObjectFn: function
        • (includeInstance: boolean, data: T): __type
        • Parameters

          • includeInstance: boolean
          • data: T

          Returns __type

    • Optional includeInstance: boolean

    Returns Array<__type>

Generated using TypeDoc