MCPcopy
hub / github.com/hashicorp/go-memdb / FieldSetIndex

Struct FieldSetIndex

index.go:605–607  ·  view source on GitHub ↗

FieldSetIndex is used to extract a field from an object using reflection and builds an index on whether the field is set by comparing it against its type's nil value.

Source from the content-addressed store, hash-verified

603// builds an index on whether the field is set by comparing it against its
604// type's nil value.
605type FieldSetIndex struct {
606 Field string
607}
608
609func (f *FieldSetIndex) FromObject(obj interface{}) (bool, []byte, error) {
610 v := reflect.ValueOf(obj)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected