reflectutil

package
v0.12.1 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2022 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Copyright 2019 The Go Authors. All rights reserved. Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

taken from: https://github.com/golang/protobuf/blob/master/proto/defaults.go

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetDefaults added in v0.8.0

func SetDefaults(m proto.Message)

SetDefaults sets unpopulated scalar fields to their default values. Fields within a oneof are not set even if they have a default value. SetDefaults is recursively called upon any populated message fields.

func SortValues

func SortValues(vals []reflect.Value)

SortValues sorts vals in alphabetical order.

func UnmarshalAST

func UnmarshalAST(v interface{}, expr ast.Expr)

func UnmarshalProto

func UnmarshalProto(v interface{}, lit *protop.Literal)

Types

This section is empty.

Jump to

Keyboard shortcuts

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