// SetModTime sets the modification time of the local fs object
SetModTime sets the modification time of the local fs object
// SetModTime sets the modification time of the local fs object
func (o *Object) SetModTime(modTime time.Time) error {
	err := o.readMetaData()
	if err != nil {
		return err
	}
	o.meta[metaMtime] = aws.String(swift.TimeToFloatString(modTime))
	if o.bytes >= maxSizeForCopy {
		fs.Debugf(o, "SetModTime is unsupported for objects bigger than %v bytes", fs.SizeSuffix(maxSizeForCopy))
		return nil
	}
	mimeType := fs.MimeType(o)
	key := o.fs.root + o.remote
	sourceKey := o.fs.bucket + "/" + key
	directive := s3.MetadataDirectiveReplace 
	req := s3.CopyObjectInput{
		Bucket:            &o.fs.bucket,
		ACL:               &o.fs.opt.ACL,
		Key:               &key,
		ContentType:       &mimeType,
		CopySource:        aws.String(pathEscape(sourceKey)),
		Metadata:          o.meta,
		MetadataDirective: &directive,
	}
	_, err = o.fs.c.CopyObject(&req)
	return err
}
func ( o * Object ) SetModTime ( modTime time . Time ) error { err := o . readMetaData ( ) if err != nil { return err } o . meta [ metaMtime ] = aws . String ( swift . TimeToFloatString ( modTime ) ) if o . bytes >= maxSizeForCopy { fs . Debugf ( o , " " , fs . SizeSuffix ( maxSizeForCopy ) ) return nil } mimeType := fs . MimeType ( o ) key := o . fs . root + o . remote sourceKey := o . fs . bucket + " " + key directive := s3 . MetadataDirectiveReplace req := s3 . CopyObjectInput { Bucket : & o . fs . bucket , ACL : & o . fs . opt . ACL , Key : & key , ContentType : & mimeType , CopySource : aws . String ( pathEscape ( sourceKey ) ) , Metadata : o . meta , MetadataDirective : & directive , } _ , err = o . fs . c . CopyObject ( & req ) return err }
SetModTime sets the modification time of the local fs object
SetModTime sets the modification time of the local fs object
// Guess the content type // Copy the object to itself to update the metadata // replace metadata with that passed in