kubo/core
Lucas Molas 08922d239d mfs: make Root value a Directory
Make `Root` value explicitly a `Directory` structure instead of the `FSNode`
interface (which also allowed the `File` type). This helps to make the code
easier to reason about: the root of an MFS layout is always a directory, not a
(single) file.

Rename `GetValue()` to `GetDirectory()` to also make it more explicit, the
renamed function now returns a `Directory` so there is no need for type
assertions that were previously done on the `FSNode` interface to check that it
was actually a `Directory`.

`NewRoot()` now doesn't allow to create `Root` structures from DAG nodes that
contain UnixFS files.

License: MIT
Signed-off-by: Lucas Molas <schomatis@gmail.com>
2018-06-29 11:30:53 -03:00
..
commands extract ipns record logic to go-ipns 2018-06-15 20:10:26 -07:00
coreapi Add package overview comments to coreapi 2018-06-12 15:56:15 -07:00
coredag gx update go-log, sys, go-crypto 2018-06-08 22:36:24 -07:00
corehttp Merge pull request #5072 from Bren2010/review/core 2018-06-13 15:30:58 +08:00
corerepo mfs: make Root value a Directory 2018-06-29 11:30:53 -03:00
coreunix mfs: make Root value a Directory 2018-06-29 11:30:53 -03:00
mock gx update go-log, sys, go-crypto 2018-06-08 22:36:24 -07:00
.gitignore ignore testdb 2014-07-05 15:04:04 -07:00
bootstrap_test.go gx update go-log, sys, go-crypto 2018-06-08 22:36:24 -07:00
bootstrap.go gx update go-log, sys, go-crypto 2018-06-08 22:36:24 -07:00
builder.go Fix how filestore is hooked up. 2018-06-15 02:33:01 -04:00
core_test.go update deps 2018-05-31 17:59:17 -07:00
core.go extract ipns record logic to go-ipns 2018-06-15 20:10:26 -07:00
pathresolver_test.go make path resolver no longer require whole node for construction 2016-10-25 15:04:44 -07:00
pathresolver.go gx update go-log, sys, go-crypto 2018-06-08 22:36:24 -07:00