Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 247 for SplitN (0.18 sec)

  1. internal/arn/arn.go

    	// the ARN would not match any configured ARNs in the server.
    	if ps[4] != "" {
    		err = errors.New("invalid ARN - unsupported account-id field")
    		return
    	}
    
    	res := strings.SplitN(ps[5], "/", 2)
    	if len(res) != 2 {
    		err = errors.New("invalid ARN - resource does not contain a \"/\"")
    		return
    	}
    
    	if res[0] != string(arnResourceTypeRole) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 08:31:34 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  2. cmd/erasure-utils.go

    	uploadBytes, err := base64.RawURLEncoding.DecodeString(uploadID)
    	if err != nil {
    		return "", fmt.Errorf("error parsing uploadID %s (%w)", uploadID, err)
    	}
    	slc := strings.SplitN(string(uploadBytes), ".", 2)
    	if len(slc) != 2 {
    		return "", fmt.Errorf("uploadID %s has incorrect format", uploadID)
    	}
    	return slc[0], nil
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Jan 31 02:11:45 GMT 2024
    - 3.1K bytes
    - Viewed (0)
  3. cmd/ftp-server.go

    	var (
    		port          int
    		publicIP      string
    		portRange     string
    		tlsPrivateKey string
    		tlsPublicCert string
    	)
    
    	var err error
    	for _, arg := range args {
    		tokens := strings.SplitN(arg, "=", 2)
    		if len(tokens) != 2 {
    			logger.Fatal(fmt.Errorf("invalid arguments passed to --ftp=%s", arg), "unable to start FTP server")
    		}
    		switch tokens[0] {
    		case "address":
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Mar 09 03:07:08 GMT 2024
    - 4.8K bytes
    - Viewed (2)
  4. src/bytes/bytes.go

    	return genSplit(s, sep, len(sep), n)
    }
    
    // Split slices s into all subslices separated by sep and returns a slice of
    // the subslices between those separators.
    // If sep is empty, Split splits after each UTF-8 sequence.
    // It is equivalent to SplitN with a count of -1.
    //
    // To split around the first instance of a separator, see Cut.
    func Split(s, sep []byte) [][]byte { return genSplit(s, sep, 0, -1) }
    
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Mon Feb 19 19:51:15 GMT 2024
    - 33.8K bytes
    - Viewed (0)
  5. internal/config/config.go

    	tgt = Default
    	if len(s) == 0 {
    		return subSys, inputs, tgt, Errorf("input arguments cannot be empty")
    	}
    	inputs = strings.SplitN(s, KvSpaceSeparator, 2)
    
    	subSystemValue := strings.SplitN(inputs[0], SubSystemSeparator, 2)
    	subSys = subSystemValue[0]
    	if !SubSystems.Contains(subSys) {
    		return subSys, inputs, tgt, Errorf("unknown sub-system %s", s)
    	}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Mar 02 05:11:03 GMT 2024
    - 37.3K bytes
    - Viewed (0)
  6. cmd/admin-server-info.go

    	}
    	for _, v := range os.Environ() {
    		if !strings.HasPrefix(v, "MINIO") && !strings.HasPrefix(v, "_MINIO") {
    			continue
    		}
    		split := strings.SplitN(v, "=", 2)
    		key := split[0]
    		value := ""
    		if len(split) > 1 {
    			value = split[1]
    		}
    
    		// Do not send sensitive creds.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 4.8K bytes
    - Viewed (0)
  7. cmd/sftp-server.go

    	}
    }
    
    func startSFTPServer(args []string) {
    	var (
    		port          int
    		publicIP      string
    		sshPrivateKey string
    	)
    
    	var err error
    	for _, arg := range args {
    		tokens := strings.SplitN(arg, "=", 2)
    		if len(tokens) != 2 {
    			logger.Fatal(fmt.Errorf("invalid arguments passed to --sftp=%s", arg), "unable to start SFTP server")
    		}
    		switch tokens[0] {
    		case "address":
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  8. callbacks/preload.go

    		for _, join := range joins {
    			if _, ok := relationships.Relations[join]; ok && name == join {
    				joined = true
    				continue
    			}
    			joinNames := strings.SplitN(join, ".", 2)
    			if len(joinNames) == 2 {
    				if _, ok := relationships.Relations[joinNames[0]]; ok && name == joinNames[0] {
    					joined = true
    					nestedJoins = append(nestedJoins, joinNames[1])
    				}
    			}
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Thu Apr 25 12:21:03 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  9. src/bytes/example_test.go

    	// U+0068 'h'
    	// U+0065 'e'
    	// U+0072 'r'
    }
    
    func ExampleSplit() {
    	fmt.Printf("%q\n", bytes.Split([]byte("a,b,c"), []byte(",")))
    	fmt.Printf("%q\n", bytes.Split([]byte("a man a plan a canal panama"), []byte("a ")))
    	fmt.Printf("%q\n", bytes.Split([]byte(" xyz "), []byte("")))
    	fmt.Printf("%q\n", bytes.Split([]byte(""), []byte("Bernardo O'Higgins")))
    	// Output:
    	// ["a" "b" "c"]
    	// ["" "man " "plan " "canal panama"]
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Mon Mar 04 15:54:40 GMT 2024
    - 15K bytes
    - Viewed (1)
  10. cmd/bucket-lifecycle.go

    // the empty value and an error indicating the parse failure.
    func parseRestoreObjStatus(restoreHdr string) (restoreObjStatus, error) {
    	tokens := strings.SplitN(restoreHdr, ",", 2)
    	progressTokens := strings.SplitN(tokens[0], "=", 2)
    	if len(progressTokens) != 2 {
    		return restoreObjStatus{}, errRestoreHDRMalformed
    	}
    	if strings.TrimSpace(progressTokens[0]) != "ongoing-request" {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Apr 17 05:09:58 GMT 2024
    - 33.1K bytes
    - Viewed (0)
Back to top