reflect.Value.Interface (method)
204 uses
reflect (current package)
type.go#L2677: copy(tt.Elem().Field(2).Slice(0, len(methods)).Interface().([]method), methods)
value.go#L1429: func (v Value) Interface() (i any) {
crypto/x509
verify.go#L515: constraint := excludedValue.Index(i).Interface()
verify.go#L535: constraint := permittedValue.Index(i).Interface()
database/sql
convert.go#L428: return convertAssignRows(dv.Interface(), src, rows)
database/sql/driver
types.go#L264: return defaultConverter{}.ConvertValue(rv.Elem().Interface())
encoding/asn1
asn1.go#L854: switch v := v.Addr().Interface().(type) {
marshal.go#L466: t := value.Interface().(time.Time)
marshal.go#L472: return bitStringEncoder(value.Interface().(BitString)), nil
marshal.go#L474: return makeObjectIdentifier(value.Interface().(ObjectIdentifier))
marshal.go#L476: return makeBigInt(value.Interface().(*big.Int))
marshal.go#L596: if reflect.DeepEqual(v.Interface(), defaultValue.Interface()) {
marshal.go#L605: if reflect.DeepEqual(v.Interface(), reflect.Zero(v.Type()).Interface()) {
marshal.go#L611: rv := v.Interface().(RawValue)
marshal.go#L656: if params.timeType == TagGeneralizedTime || outsideUTCRange(v.Interface().(time.Time)) {
encoding/json
decode.go#L478: if u, ok := v.Interface().(Unmarshaler); ok {
decode.go#L482: if u, ok := v.Interface().(encoding.TextUnmarshaler); ok {
encode.go#L474: m, ok := v.Interface().(Marshaler)
encode.go#L495: m := va.Interface().(Marshaler)
encode.go#L511: m, ok := v.Interface().(encoding.TextMarshaler)
encode.go#L529: m := va.Interface().(encoding.TextMarshaler)
encode.go#L938: ptr := v.Interface()
encode.go#L1011: if tm, ok := w.k.Interface().(encoding.TextMarshaler); ok {
encoding/xml
marshal.go#L435: return p.marshalInterface(val.Interface().(Marshaler), defaultStart(typ, finfo, startTemplate))
marshal.go#L440: return p.marshalInterface(pv.Interface().(Marshaler), defaultStart(pv.Type(), finfo, startTemplate))
marshal.go#L446: return p.marshalTextInterface(val.Interface().(encoding.TextMarshaler), defaultStart(typ, finfo, startTemplate))
marshal.go#L451: return p.marshalTextInterface(pv.Interface().(encoding.TextMarshaler), defaultStart(pv.Type(), finfo, startTemplate))
marshal.go#L487: if v, ok := fv.Interface().(Name); ok && v.Local != "" {
marshal.go#L559: attr, err := val.Interface().(MarshalerAttr).MarshalXMLAttr(name)
marshal.go#L572: attr, err := pv.Interface().(MarshalerAttr).MarshalXMLAttr(name)
marshal.go#L584: text, err := val.Interface().(encoding.TextMarshaler).MarshalText()
marshal.go#L595: text, err := pv.Interface().(encoding.TextMarshaler).MarshalText()
marshal.go#L625: start.Attr = append(start.Attr, val.Interface().(Attr))
marshal.go#L833: data, err := vf.Interface().(encoding.TextMarshaler).MarshalText()
marshal.go#L845: data, err := pv.Interface().(encoding.TextMarshaler).MarshalText()
marshal.go#L880: if elem, ok := vf.Interface().([]byte); ok {
marshal.go#L934: iface := vf.Interface()
read.go#L256: return val.Interface().(UnmarshalerAttr).UnmarshalXMLAttr(attr)
read.go#L261: return pv.Interface().(UnmarshalerAttr).UnmarshalXMLAttr(attr)
read.go#L269: return val.Interface().(encoding.TextUnmarshaler).UnmarshalText([]byte(attr.Value))
read.go#L274: return pv.Interface().(encoding.TextUnmarshaler).UnmarshalText([]byte(attr.Value))
read.go#L342: return d.unmarshalInterface(val.Interface().(Unmarshaler), start)
read.go#L348: return d.unmarshalInterface(pv.Interface().(Unmarshaler), start)
read.go#L353: return d.unmarshalTextInterface(val.Interface().(encoding.TextUnmarshaler))
read.go#L359: return d.unmarshalTextInterface(pv.Interface().(encoding.TextUnmarshaler))
read.go#L439: if _, ok := fv.Interface().(Name); ok {
read.go#L563: if err := saveData.Interface().(encoding.TextUnmarshaler).UnmarshalText(data); err != nil {
read.go#L572: if err := pv.Interface().(encoding.TextUnmarshaler).UnmarshalText(data); err != nil {
flag
flag.go#L464: return value == z.Interface().(Value).String()
fmt
print.go#L701: p.arg = f.Interface()
print.go#L722: p.arg = value.Interface()
github.com/aws/aws-sdk-go-v2/aws/transport/http
client.go#L225: return dstVal.Interface()
github.com/go-pg/pg/v10/orm
hook.go#L109: return v.Interface().(BeforeScanHook).BeforeScan(ctx)
hook.go#L121: return v.Interface().(AfterScanHook).AfterScan(ctx)
hook.go#L133: return v.Interface().(AfterSelectHook).AfterSelect(ctx)
hook.go#L151: return v.Interface().(BeforeInsertHook).BeforeInsert(ctx)
hook.go#L169: return v.Interface().(AfterInsertHook).AfterInsert(ctx)
hook.go#L187: return v.Interface().(BeforeUpdateHook).BeforeUpdate(ctx)
hook.go#L205: return v.Interface().(AfterUpdateHook).AfterUpdate(ctx)
hook.go#L223: return v.Interface().(BeforeDeleteHook).BeforeDelete(ctx)
hook.go#L241: return v.Interface().(AfterDeleteHook).AfterDelete(ctx)
model.go#L114: slicePtr := v.Addr().Interface().(*[]map[string]interface{})
model.go#L123: mapPtr := v.Addr().Interface().(*map[string]interface{})
model_func.go#L56: model, ok := v0.Interface().(Model)
model_func.go#L86: return errv.Interface().(error)
table.go#L1435: return dec.Decode(v.Addr().Interface())
table.go#L1473: ptr := fv.Addr().Interface().(*time.Time)
table.go#L1479: ptr := fv.Addr().Interface().(*types.NullTime)
table.go#L1485: ptr := fv.Addr().Interface().(*sql.NullInt64)
table.go#L1494: ptr := fv.Addr().Interface().(*int64)
github.com/go-pg/pg/v10/types
append_value.go#L143: return Append(b, v.Interface(), flags)
append_value.go#L203: if err := pgjson.NewEncoder(buf).Encode(v.Interface()); err != nil {
append_value.go#L216: tm := v.Interface().(time.Time)
append_value.go#L221: ip := v.Interface().(net.IP)
append_value.go#L226: ipnet := v.Interface().(net.IPNet)
append_value.go#L235: return appendAppender(b, v.Interface().(ValueAppender), flags)
append_value.go#L239: return appendDriverValuer(b, v.Interface().(driver.Valuer), flags)
array.go#L55: return a.v.Interface()
array_append.go#L107: ss := v.Convert(sliceStringType).Interface().([]string)
array_append.go#L140: ints := v.Convert(sliceIntType).Interface().([]int)
array_append.go#L173: ints := v.Convert(sliceInt64Type).Interface().([]int64)
array_append.go#L206: floats := v.Convert(sliceFloat64Type).Interface().([]float64)
array_scan.go#L296: scanner := v.Addr().Interface().(ArrayValueScanner)
hstore.go#L44: return h.v.Interface()
hstore_append.go#L48: m := v.Convert(mapStringStringType).Interface().(map[string]string)
scan_value.go#L261: return dec.Decode(v.Addr().Interface())
scan_value.go#L270: ptr := v.Addr().Interface().(*time.Time)
scan_value.go#L291: ptr := v.Addr().Interface().(*net.IP)
scan_value.go#L315: ptr := v.Addr().Interface().(*net.IPNet)
scan_value.go#L369: return v.Interface().(ValueScanner).ScanValue(rd, n)
scan_value.go#L376: return v.Interface().(ValueScanner).ScanValue(rd, n)
scan_value.go#L383: return v.Addr().Interface().(ValueScanner).ScanValue(rd, n)
scan_value.go#L391: return scanSQLScanner(v.Interface().(sql.Scanner), rd, n)
scan_value.go#L398: return scanSQLScanner(v.Interface().(sql.Scanner), rd, n)
scan_value.go#L405: return scanSQLScanner(v.Addr().Interface().(sql.Scanner), rd, n)
github.com/go-pg/zerochecker
zerochecker.go#L61: return v.Interface().(isZeroer).IsZero()
zerochecker.go#L69: appender := v.Interface().(valueAppender)
zerochecker.go#L82: valuer := v.Interface().(driver.Valuer)
github.com/golang/mock/gomock
call.go#L74: rets[i] = reflect.Zero(methodType.Out(i)).Interface()
call.go#L135: rets[i] = ret.Interface()
call.go#L199: rets[i] = v.Interface()
call.go#L373: if m.Matches(vArgs.Interface()) {
matchers.go#L116: return reflect.DeepEqual(x1ValConverted.Interface(), x2Val.Interface())
matchers.go#L231: wantedMatcher := Eq(wanted.Index(i).Interface())
matchers.go#L236: if wantedMatcher.Matches(given.Index(j).Interface()) {
github.com/golang/protobuf/jsonpb
decode.go#L502: return protoreflect.ValueOf(reflect.ValueOf(v).Elem().Interface()), err
github.com/golang/protobuf/proto
extensions.go#L176: v = rv2.Interface()
extensions.go#L238: v = rv.Elem().Interface()
properties.go#L264: oneofWrappers = fn.Func.Call([]reflect.Value{reflect.Zero(fn.Type.In(0))})[3].Interface().([]interface{})
properties.go#L267: oneofWrappers = fn.Func.Call([]reflect.Value{reflect.Zero(fn.Type.In(0))})[0].Interface().([]interface{})
properties.go#L269: if m, ok := reflect.Zero(reflect.PtrTo(t)).Interface().(protoreflect.ProtoMessage); ok {
github.com/google/go-cmp/cmp
export_unsafe.go#L33: return reflect.ValueOf(ve.Interface()).Convert(f.Type)
options.go#L235: if _, ok := reflect.New(t).Interface().(error); ok {
report_compare.go#L387: ambiguous = prevKey.Interface() != currKey.Interface()
report_reflect.go#L139: switch v := v.Interface().(type) {
report_slices.go#L311: ss = append(ss, fmt.Sprint(v.Index(i).Interface()))
report_slices.go#L362: return vx.Index(ix).Interface() == vy.Index(iy).Interface()
github.com/vmihailenco/msgpack/v5
decode_map.go#L91: mptr := v.Addr().Convert(mapStringStringPtrType).Interface().(*map[string]string)
decode_map.go#L127: ptr := v.Addr().Convert(mapStringInterfacePtrType).Interface().(*map[string]interface{})
decode_map.go#L233: return mapValue.Interface(), nil
decode_slice.go#L39: ptr := v.Addr().Convert(sliceStringPtrType).Interface().(*[]string)
decode_value.go#L144: return fmt.Errorf("msgpack: Decode(nonaddressable %T)", v.Interface())
decode_value.go#L214: decoder := v.Interface().(CustomDecoder)
decode_value.go#L228: unmarshaler := v.Interface().(Unmarshaler)
decode_value.go#L238: unmarshaler := v.Interface().(encoding.BinaryUnmarshaler)
decode_value.go#L248: unmarshaler := v.Interface().(encoding.TextUnmarshaler)
encode_map.go#L42: m := v.Convert(mapStringStringType).Interface().(map[string]string)
encode_map.go#L63: m := v.Convert(mapStringInterfaceType).Interface().(map[string]interface{})
encode_slice.go#L102: ss := v.Convert(stringSliceType).Interface().([]string)
encode_value.go#L135: return fmt.Errorf("msgpack: Encode(non-addressable %T)", v.Interface())
encode_value.go#L137: encoder := v.Addr().Interface().(CustomEncoder)
encode_value.go#L146: encoder := v.Interface().(CustomEncoder)
encode_value.go#L152: return fmt.Errorf("msgpack: Encode(non-addressable %T)", v.Interface())
encode_value.go#L162: marshaler := v.Interface().(Marshaler)
encode_value.go#L186: return e.EncodeString(v.Interface().(error).Error())
encode_value.go#L205: return fmt.Errorf("msgpack: Encode(non-addressable %T)", v.Interface())
encode_value.go#L215: marshaler := v.Interface().(encoding.BinaryMarshaler)
encode_value.go#L228: return fmt.Errorf("msgpack: Encode(non-addressable %T)", v.Interface())
encode_value.go#L238: marshaler := v.Interface().(encoding.TextMarshaler)
ext.go#L25: marshaler := v.Interface().(Marshaler)
ext.go#L33: return v.Interface().(Unmarshaler).UnmarshalMsgpack(b)
ext.go#L99: return fmt.Errorf("msgpack: Decode(nonaddressable %T)", v.Interface())
ext.go#L160: return fmt.Errorf("msgpack: Decode(nonaddressable %T)", v.Interface())
ext.go#L266: return v.Interface(), nil
time.go#L20: return e.encodeTime(v.Interface().(time.Time)), nil
time.go#L29: ptr := v.Addr().Interface().(*time.Time)
types.go#L331: if z, ok := v.Interface().(isZeroer); ok {
go/ast
print.go#L173: ptr := x.Interface()
print.go#L196: if s, ok := x.Interface().([]byte); ok {
print.go#L238: v := x.Interface()
google.golang.org/protobuf/internal/descfmt
stringer.go#L94: v := m.Call([]reflect.Value{reflect.ValueOf(i)})[0].Interface()
stringer.go#L219: if _, ok := rv.Interface().(protoreflect.Value); ok {
stringer.go#L240: if n, ok := rv.Interface().(list); ok {
stringer.go#L249: v := rv.Interface()
google.golang.org/protobuf/internal/filedesc
desc_lazy.go#L694: opts = reflect.New(reflect.TypeOf(*p).Elem()).Interface().(protoreflect.ProtoMessage)
google.golang.org/protobuf/internal/impl
codec_field.go#L501: m := reflect.New(f.mi.GoReflectType.Elem()).Interface()
codec_field.go#L815: m := reflect.New(f.mi.GoReflectType.Elem()).Interface()
codec_field.go#L826: if m, ok := v.Interface().(protoreflect.ProtoMessage); ok {
convert.go#L433: if m, ok := v.Interface().(protoreflect.ProtoMessage); ok {
convert_list.go#L140: return ls.v.Interface()
convert_map.go#L120: return ms.v.Interface()
enum.go#L19: return reflect.ValueOf(n).Convert(t.GoReflectType).Interface().(protoreflect.Enum)
extension.go#L102: return xi.lazyInit().GoValueOf(v).Interface()
legacy_enum.go#L103: return v.Interface()
legacy_enum.go#L124: ev := reflect.Zero(t).Interface()
legacy_extension.go#L33: mz := reflect.Zero(t).Interface()
legacy_extension.go#L66: xi.ExtensionType = reflect.Zero(extType).Interface()
legacy_extension.go#L96: switch v := reflect.Zero(t).Interface().(type) {
legacy_message.go#L30: return mt.MessageOf(v.Interface())
legacy_message.go#L61: v := reflect.Zero(t).Interface()
legacy_message.go#L100: mv := reflect.Zero(t).Interface()
legacy_message.go#L212: if vs, ok := v.Interface().([]interface{}); ok {
legacy_message.go#L274: if m, ok := reflect.Zero(t).Interface().(interface{ XXX_MessageName() string }); ok {
legacy_message.go#L320: switch v := reflect.Zero(t).Interface().(type) {
legacy_message.go#L328: switch v := reflect.Zero(t).Interface().(type) {
legacy_message.go#L491: if mr, ok := m.v.Interface().(interface{ Reset() }); ok {
legacy_message.go#L562: return m.v.Interface()
message.go#L56: m, ok := reflect.Zero(mt).Interface().(protoreflect.ProtoMessage)
message.go#L198: if vs, ok := v.Interface().([]interface{}); ok {
message.go#L221: m := reflect.New(mi.GoReflectType.Elem()).Interface()
message.go#L228: return mi.MessageOf(reflect.Zero(mi.GoReflectType).Interface())
message_reflect.go#L173: return (*extensionMap)(v.Interface().(*map[int32]ExtensionField))
message_reflect.go#L229: mi.fieldTypes[fd.Number()] = reflect.Zero(ft).Interface()
pointer_unsafe.go#L85: return p.AsValueOf(t).Interface()
gotest.tools/v3/assert/cmp
compare.go#L193: if reflect.DeepEqual(colValue.Index(i).Interface(), item) {
html/template
content.go#L127: return v.Interface()
content.go#L146: return v.Interface()
js.go#L138: return v.Interface()
net/http
transfer.go#L425: return reflect.ValueOf(t.Body).Field(0).Interface().(io.Reader)
transfer.go#L1093: return isKnownInMemoryReader(reflect.ValueOf(r).Field(0).Interface().(io.Reader))
transport.go#L375: if h2i, ok := v.Interface().(h2Transport); ok {
net/http/httptrace
trace.go#L199: tfCopy := reflect.ValueOf(tf.Interface())
text/template
exec.go#L460: value = reflect.ValueOf(value.Interface()) // lovely!
exec.go#L722: v = v.Interface().(reflect.Value)
exec.go#L732: v = s.evalArg(dot, argType, arg).Interface().(reflect.Value)
exec.go#L1044: return v.Interface(), true
funcs.go#L370: return ret[0], ret[1].Interface().(error)
funcs.go#L488: truth = arg1.Interface() == arg.Interface()