MCPcopy Create free account
hub / github.com/chainloop-dev/chainloop / Ints

Method Ints

app/controlplane/pkg/data/ent/ent.go:389–398  ·  view source on GitHub ↗

Ints returns list of ints from a selector. It is only allowed when selecting one field.

(ctx context.Context)

Source from the content-addressed store, hash-verified

387
388// Ints returns list of ints from a selector. It is only allowed when selecting one field.
389func (s *selector) Ints(ctx context.Context) ([]int, error) {
390 if len(*s.flds) > 1 {
391 return nil, errors.New("ent: Ints is not achievable when selecting more than 1 field")
392 }
393 var v []int
394 if err := s.scan(ctx, &v); err != nil {
395 return nil, err
396 }
397 return v, nil
398}
399
400// IntsX is like Ints, but panics if an error occurs.
401func (s *selector) IntsX(ctx context.Context) []int {

Callers 2

IntsXMethod · 0.95
IntMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected