Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 6,031 for return (0.04 sec)

  1. internal/hash/checksum.go

    		return ChecksumSHA1
    	case "SHA256":
    		return ChecksumSHA256
    	case "":
    		return ChecksumNone
    	}
    	return ChecksumInvalid
    }
    
    // String returns the type as a string.
    func (c ChecksumType) String() string {
    	switch {
    	case c.Is(ChecksumCRC32):
    		return "CRC32"
    	case c.Is(ChecksumCRC32C):
    		return "CRC32C"
    	case c.Is(ChecksumSHA1):
    		return "SHA1"
    	case c.Is(ChecksumSHA256):
    		return "SHA256"
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 19 12:59:07 UTC 2024
    - 12.7K bytes
    - Viewed (0)
  2. cmd/auth-handler.go

    		return authTypeStreamingUnsignedTrailer
    	} else if isRequestSignatureV4(r) {
    		return authTypeSigned
    	} else if isRequestPresignedSignatureV4(r) {
    		return authTypePresigned
    	} else if isRequestJWT(r) {
    		return authTypeJWT
    	} else if isRequestPostPolicySignatureV4(r) {
    		return authTypePostPolicy
    	} else if _, ok := r.Form[xhttp.Action]; ok {
    		return authTypeSTS
    	} else if _, ok := r.Header[xhttp.Authorization]; !ok {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Sep 17 16:45:46 UTC 2024
    - 26.1K bytes
    - Viewed (0)
  3. internal/config/storageclass/storage-class.go

    	scStr := string(b)
    	if scStr == "" {
    		return nil
    	}
    	s, err := parseStorageClass(scStr)
    	if err != nil {
    		return err
    	}
    	sc.Parity = s.Parity
    	return nil
    }
    
    // MarshalText - marshals storage class string.
    func (sc *StorageClass) MarshalText() ([]byte, error) {
    	if sc.Parity != 0 {
    		return []byte(fmt.Sprintf("%s:%d", schemePrefix, sc.Parity)), nil
    	}
    	return []byte{}, nil
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 12 12:24:04 UTC 2024
    - 12.3K bytes
    - Viewed (0)
  4. internal/auth/credentials.go

    		return []byte(secretKey), nil
    	}
    
    	if err := jwt.ParseWithClaims(token, claims, stsTokenCallback); err != nil {
    		return nil, err
    	}
    
    	return claims, nil
    }
    
    // GetNewCredentials generates and returns new credential.
    func GetNewCredentials() (cred Credentials, err error) {
    	return GetNewCredentialsWithMetadata(map[string]interface{}{}, "")
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue May 28 17:14:16 UTC 2024
    - 12K bytes
    - Viewed (0)
  5. cmd/batch-expire.go

    		if err := tag.Validate(); err != nil {
    			return err
    		}
    	}
    
    	for _, meta := range ef.Metadata {
    		if err := meta.Validate(); err != nil {
    			return err
    		}
    	}
    	if err := ef.Purge.Validate(); err != nil {
    		return err
    	}
    	if err := ef.Size.Validate(); err != nil {
    		return err
    	}
    	if ef.CreatedBefore != nil && !ef.CreatedBefore.Before(time.Now()) {
    		return BatchJobYamlErr{
    			line: ef.line,
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Sep 18 17:59:03 UTC 2024
    - 21.9K bytes
    - Viewed (0)
  6. cmd/utils.go

    		if transport == nil {
    			// Client certs are not readable return default transport.
    			return s.NewHTTPTransportWithTimeout(1 * time.Minute)
    		}
    		return transport
    	}
    
    	return globalRemoteTargetTransport
    }
    
    // NewHTTPTransport returns a new http configuration
    // used while communicating with the cloud backends.
    func NewHTTPTransport() *http.Transport {
    	return NewHTTPTransportWithTimeout(1 * time.Minute)
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Aug 13 22:22:04 UTC 2024
    - 31.9K bytes
    - Viewed (0)
  7. internal/ioutil/ioutil.go

    	buf := *bufp
    
    	return io.CopyBuffer(writerOnly{dst}, src, buf)
    }
    
    // SameFile returns if the files are same.
    func SameFile(fi1, fi2 os.FileInfo) bool {
    	if !os.SameFile(fi1, fi2) {
    		return false
    	}
    	if !fi1.ModTime().Equal(fi2.ModTime()) {
    		return false
    	}
    	if fi1.Mode() != fi2.Mode() {
    		return false
    	}
    	return fi1.Size() == fi2.Size()
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Jul 26 12:55:01 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  8. internal/event/target/redis.go

    // Name - returns the Name of the target.
    func (target *RedisTarget) Name() string {
    	return target.ID().String()
    }
    
    // Store returns any underlying store if set.
    func (target *RedisTarget) Store() event.TargetStore {
    	return target.store
    }
    
    // IsActive - Return true if target is up and active
    func (target *RedisTarget) IsActive() (bool, error) {
    	if err := target.init(); err != nil {
    		return false, err
    	}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Sep 06 23:06:30 UTC 2024
    - 9.1K bytes
    - Viewed (0)
  9. cmd/bucket-lifecycle.go

    		return `ongoing-request="true"`
    	}
    	return fmt.Sprintf(`ongoing-request="false", expiry-date="%s"`, r.expiry.Format(http.TimeFormat))
    }
    
    // Expiry returns expiry of restored object and true if restore-object has completed.
    // Otherwise returns zero value of time.Time and false.
    func (r restoreObjStatus) Expiry() (time.Time, bool) {
    	if r.Ongoing() {
    		return time.Time{}, false
    	}
    	return r.expiry, true
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Oct 23 15:35:37 UTC 2024
    - 33.7K bytes
    - Viewed (0)
  10. cmd/data-usage-cache.go

    					switch err.(type) {
    					case ObjectNotFound, BucketNotFound:
    						return false, nil
    					case InsufficientReadQuorum, StorageErr:
    						return true, nil
    					}
    					return false, err
    				}
    				err = d.deserialize(r)
    				r.Close()
    				return err != nil, nil
    			case InsufficientReadQuorum, StorageErr:
    				return true, nil
    			}
    			return false, err
    		}
    		err = d.deserialize(r)
    		r.Close()
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Oct 22 15:30:50 UTC 2024
    - 34.7K bytes
    - Viewed (0)
Back to top