tmap

package
v0.39.0-alpha.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 2, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package tmap provides type mapping facility that maps type id to type name.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Constructor added in v0.15.0

type Constructor struct {
	// contains filtered or unexported fields
}

Constructor maps type id to type constructor.

func NewConstructor added in v0.15.0

func NewConstructor(mappings ...map[uint32]func() bin.Object) *Constructor

NewConstructor merges mappings into Constructor.

func (*Constructor) New added in v0.15.0

func (c *Constructor) New(id uint32) bin.Object

New instantiates new value for type id or returns nil.

type Map

type Map struct {
	// contains filtered or unexported fields
}

Map is type mapping.

func New

func New(mappings ...map[uint32]string) *Map

New creates new Map from mappings.

func (*Map) Get

func (m *Map) Get(id uint32) string

Get returns type string or blank.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL