MCPcopy
hub / github.com/rclone/rclone / ModTime

Method ModTime

backend/yandex/yandex.go:985–992  ·  view source on GitHub ↗

ModTime returns the modification time of the object It attempts to read the objects mtime and if that isn't present the LastModified returned in the http headers

(ctx context.Context)

Source from the content-addressed store, hash-verified

983// It attempts to read the objects mtime and if that isn't present the
984// LastModified returned in the http headers
985func (o *Object) ModTime(ctx context.Context) time.Time {
986 err := o.readMetaData(ctx)
987 if err != nil {
988 fs.Logf(o, "Failed to read metadata: %v", err)
989 return time.Now()
990 }
991 return o.modTime
992}
993
994// Size returns the size of an object in bytes
995func (o *Object) Size() int64 {

Callers

nothing calls this directly

Calls 2

readMetaDataMethod · 0.95
LogfFunction · 0.92

Tested by

no test coverage detected