mirror of https://github.com/spf13/afero.git
Adding and optional Symlinker interface,
union interface supportint lstat, symlink and readlink
This commit is contained in:
parent
529d861398
commit
819f7ad35d
14
symlink.go
14
symlink.go
|
@ -12,6 +12,20 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
package afero
|
package afero
|
||||||
|
|
||||||
|
// Symlinker is an optional interface in Afero. It is only implemented by the
|
||||||
|
// filesystems saying so.
|
||||||
|
// It indicates support for 3 symlink related interfaces that implement the
|
||||||
|
// behaviors of the os methods:
|
||||||
|
// - Lstat
|
||||||
|
// - Symlink, and
|
||||||
|
// - Readlink
|
||||||
|
type Symlinker interface {
|
||||||
|
Lstater
|
||||||
|
Linker
|
||||||
|
LinkReader
|
||||||
|
}
|
||||||
|
|
||||||
// Linker is an optional interface in Afero. It is only implemented by the
|
// Linker is an optional interface in Afero. It is only implemented by the
|
||||||
// filesystems saying so.
|
// filesystems saying so.
|
||||||
// It will call Symlink if the filesystem itself is, or it delegates to, the os filesystem,
|
// It will call Symlink if the filesystem itself is, or it delegates to, the os filesystem,
|
||||||
|
|
Loading…
Reference in New Issue