github.com/slene/docker@v1.8.0-rc1/pkg/system/stat.go (about) 1 // +build !windows 2 3 package system 4 5 import ( 6 "syscall" 7 ) 8 9 // Stat_t type contains status of a file. It contains metadata 10 // like permission, owner, group, size, etc about a file 11 type Stat_t struct { 12 mode uint32 13 uid uint32 14 gid uint32 15 rdev uint64 16 size int64 17 mtim syscall.Timespec 18 } 19 20 func (s Stat_t) Mode() uint32 { 21 return s.mode 22 } 23 24 func (s Stat_t) Uid() uint32 { 25 return s.uid 26 } 27 28 func (s Stat_t) Gid() uint32 { 29 return s.gid 30 } 31 32 func (s Stat_t) Rdev() uint64 { 33 return s.rdev 34 } 35 36 func (s Stat_t) Size() int64 { 37 return s.size 38 } 39 40 func (s Stat_t) Mtim() syscall.Timespec { 41 return s.mtim 42 } 43 44 func (s Stat_t) GetLastModification() syscall.Timespec { 45 return s.Mtim() 46 }