MCPcopy Create free account
hub / github.com/dgraph-io/dgraph-benchmarks / Size

Method Size

bitmap/pb.pb.go:11348–11390  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

11346}
11347
11348func (m *Mutations) Size() (n int) {
11349 if m == nil {
11350 return 0
11351 }
11352 var l int
11353 _ = l
11354 if m.GroupId != 0 {
11355 n += 1 + sovPb(uint64(m.GroupId))
11356 }
11357 if m.StartTs != 0 {
11358 n += 1 + sovPb(uint64(m.StartTs))
11359 }
11360 if len(m.Edges) > 0 {
11361 for _, e := range m.Edges {
11362 l = e.Size()
11363 n += 1 + l + sovPb(uint64(l))
11364 }
11365 }
11366 if len(m.Schema) > 0 {
11367 for _, e := range m.Schema {
11368 l = e.Size()
11369 n += 1 + l + sovPb(uint64(l))
11370 }
11371 }
11372 if len(m.Types) > 0 {
11373 for _, e := range m.Types {
11374 l = e.Size()
11375 n += 1 + l + sovPb(uint64(l))
11376 }
11377 }
11378 if m.DropOp != 0 {
11379 n += 1 + sovPb(uint64(m.DropOp))
11380 }
11381 l = len(m.DropValue)
11382 if l > 0 {
11383 n += 1 + l + sovPb(uint64(l))
11384 }
11385 if m.Metadata != nil {
11386 l = m.Metadata.Size()
11387 n += 1 + l + sovPb(uint64(l))
11388 }
11389 return n
11390}
11391
11392func (m *Metadata) Size() (n int) {
11393 if m == nil {

Callers 3

XXX_SizeMethod · 0.95
MarshalMethod · 0.95
MarshalToMethod · 0.95

Calls 2

sovPbFunction · 0.85
SizeMethod · 0.45

Tested by

no test coverage detected