index.js 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. 'use strict'
  2. const ls = require('./ls.js')
  3. const get = require('./get.js')
  4. const put = require('./put.js')
  5. const rm = require('./rm.js')
  6. const verify = require('./verify.js')
  7. const { clearMemoized } = require('./lib/memoization.js')
  8. const tmp = require('./lib/util/tmp.js')
  9. const index = require('./lib/entry-index.js')
  10. module.exports.index = {}
  11. module.exports.index.compact = index.compact
  12. module.exports.index.insert = index.insert
  13. module.exports.ls = ls
  14. module.exports.ls.stream = ls.stream
  15. module.exports.get = get
  16. module.exports.get.byDigest = get.byDigest
  17. module.exports.get.sync = get.sync
  18. module.exports.get.sync.byDigest = get.sync.byDigest
  19. module.exports.get.stream = get.stream
  20. module.exports.get.stream.byDigest = get.stream.byDigest
  21. module.exports.get.copy = get.copy
  22. module.exports.get.copy.byDigest = get.copy.byDigest
  23. module.exports.get.info = get.info
  24. module.exports.get.hasContent = get.hasContent
  25. module.exports.get.hasContent.sync = get.hasContent.sync
  26. module.exports.put = put
  27. module.exports.put.stream = put.stream
  28. module.exports.rm = rm.entry
  29. module.exports.rm.all = rm.all
  30. module.exports.rm.entry = module.exports.rm
  31. module.exports.rm.content = rm.content
  32. module.exports.clearMemoized = clearMemoized
  33. module.exports.tmp = {}
  34. module.exports.tmp.mkdir = tmp.mkdir
  35. module.exports.tmp.withTmp = tmp.withTmp
  36. module.exports.verify = verify
  37. module.exports.verify.lastRun = verify.lastRun