MCPcopy Create free account
hub / github.com/dolthub/doltgresql / Iter

Method Iter

core/storage/storage.go:342–353  ·  view source on GitHub ↗

Iter calls the given callback for each table and hash contained in the map.

(ctx context.Context, cb func(string, hash.Hash) (bool, error))

Source from the content-addressed store, hash-verified

340
341// Iter calls the given callback for each table and hash contained in the map.
342func (m RootTableMap) Iter(ctx context.Context, cb func(string, hash.Hash) (bool, error)) error {
343 var stop bool
344 return m.AddressMap.IterAll(ctx, func(n string, a hash.Hash) error {
345 n, ok := decodeTableNameForAddressMap(n, m.schemaName)
346 if !stop && ok {
347 var err error
348 stop, err = cb(n, a)
349 return err
350 }
351 return nil
352 })
353}

Callers 7

DropDatabaseSchemaMethod · 0.45
DebugStringMethod · 0.45
GetAllTableNamesMethod · 0.45
GetTableNamesMethod · 0.45
IterTablesMethod · 0.45
ResolveTableNameMethod · 0.45
runServerFunction · 0.45

Calls 2

IterAllMethod · 0.65

Tested by

no test coverage detected