Documentation ¶
Index ¶
- Constants
- Variables
- func Get(columnKey string, o *Object) interface{}
- type Access
- type After
- type Annotation
- type AnnotationItem
- type Before
- type BeginWith
- type CommOpe
- type CustomColumn
- type CustomColumnItem
- type Equal
- type ExtendData
- type In
- type Job
- type Kind
- type Label
- type Labels
- type Metadata
- type MutilOpe
- type Object
- type ObjectAttr
- type Operation
- type Pattern
- type Permission
- type Properties
- type Rule
- type Task
- type TimeOpe
- type WFRule
- type Workflow
Constants ¶
View Source
const ( PermOwnerRead = "owner_read" PermOwnerWrite = "owner_write" PermOwnerExec = "owner_exec" PermGroupRead = "group_read" PermGroupWrite = "group_write" PermGroupExec = "group_exec" PermOthersRead = "others_read" PermOthersWrite = "others_write" PermOthersExec = "others_exec" )
View Source
const ( /* system-wide kind */ GroupKind = "group" /* text based file kind */ TextKind = "text" /* format doc kind */ FmtDocKind = "fmtdoc" /* media file kind */ ImageKind = "image" VideoKind = "video" AudioKind = "audio" /* web based file kind */ WebArchiveKind = "web" /* workflow kind */ WorkflowKind = "workflow" JobKind = "job" /* time management system object kind */ TodoActionItemKind = "tdaction" TodoProjectKind = "tdproject" TodoGroupKind = "tdgroup" /* ungrouped files */ RawKind = "raw" )
View Source
const ( VersionKey = "nanafs.version" KindKey = "nanafs.kind" )
Variables ¶
Functions ¶
Types ¶
type Access ¶
type Access struct {
Permissions []Permission `json:"permissions,omitempty"`
}
type Annotation ¶
type Annotation struct { Annotations []AnnotationItem `json:"annotations,omitempty"` Details string `json:"details,omitempty"` }
func (*Annotation) Add ¶
func (a *Annotation) Add(newA *AnnotationItem)
func (*Annotation) Get ¶
func (a *Annotation) Get(key string, withInternal bool) *AnnotationItem
func (*Annotation) Remove ¶
func (a *Annotation) Remove(key string)
type AnnotationItem ¶
type CustomColumn ¶
type CustomColumn struct {
Columns []CustomColumnItem `json:"columns,omitempty"`
}
type CustomColumnItem ¶
type ExtendData ¶
type ExtendData struct { Properties *Properties `json:"properties,omitempty"` Annotation *Annotation `json:"annotation,omitempty"` }
type Metadata ¶
type Metadata struct { ID string `json:"id"` Name string `json:"name"` Aliases string `json:"aliases,omitempty"` ParentID string `json:"parent_id"` RefID string `json:"ref_id,omitempty"` Kind Kind `json:"kind"` Hash string `json:"hash"` Size int64 `json:"size"` Inode uint64 `json:"inode"` Namespace string `json:"namespace,omitempty"` CreatedAt time.Time `json:"created_at"` ChangedAt time.Time `json:"changed_at"` ModifiedAt time.Time `json:"modified_at"` AccessAt time.Time `json:"access_at"` Labels Labels `json:"labels"` Access Access `json:"access"` }
func NewMetadata ¶
type Object ¶
type Object struct { Metadata ExtendData ExtendData `json:"extend_data"` CustomColumn CustomColumn `json:"custom_column"` // contains filtered or unexported fields }
func InitNewObject ¶
func InitNewObject(parent *Object, attr ObjectAttr) (*Object, error)
type ObjectAttr ¶
type ObjectAttr struct { Name string Kind Kind Permissions []Permission }
type Permission ¶
type Permission string
type Properties ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.