in progress
This commit is contained in:
26
ifs.go
Normal file
26
ifs.go
Normal file
@@ -0,0 +1,26 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"git.gm6.ru/icewind/pfs/models"
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
type IFSStat struct {
|
||||
ID uuid.UUID
|
||||
Name string
|
||||
IsDir bool
|
||||
Created time.Time
|
||||
LastModified time.Time
|
||||
OwnerID uuid.UUID
|
||||
}
|
||||
|
||||
type IFS interface {
|
||||
DirCreate(dir *models.Dir, userID uuid.UUID) error
|
||||
DirRemove(dirID uuid.UUID, userID uuid.UUID) error
|
||||
DirRead(dirID uuid.UUID, userID uuid.UUID) ([]IFSStat, error)
|
||||
FileCreate(file *models.File) error
|
||||
FileRemove(fileID uuid.UUID, userID uuid.UUID) error
|
||||
FileRead(fileID uuid.UUID, userID uuid.UUID) (*models.File, error)
|
||||
}
|
||||
Reference in New Issue
Block a user