Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for str1 (0.05 sec)

  1. cmd/utils.go

    func lcpSuffix(strs []string) string {
    	return lcp(strs, false)
    }
    
    func lcp(strs []string, pre bool) string {
    	// short-circuit empty list
    	if len(strs) == 0 {
    		return ""
    	}
    	xfix := strs[0]
    	// short-circuit single-element list
    	if len(strs) == 1 {
    		return xfix
    	}
    	// compare first to rest
    	for _, str := range strs[1:] {
    		xfixl := len(xfix)
    		strl := len(str)
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Wed Jun 05 22:00:34 UTC 2024
    - 31.9K bytes
    - Viewed (0)
  2. security/pkg/k8s/chiron/utils_test.go

    }
    
    // Get the server port from server.URL (e.g., https://127.0.0.1:36253)
    func getServerPort(server *httptest.Server) (int, error) {
    	strs := strings.Split(server.URL, ":")
    	if len(strs) < 2 {
    		return 0, fmt.Errorf("server.URL is invalid: %v", server.URL)
    	}
    	port, err := strconv.Atoi(strs[len(strs)-1])
    	if err != nil {
    		return 0, fmt.Errorf("error to extract port from URL: %v", server.URL)
    	}
    	return port, nil
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed May 15 03:58:11 UTC 2024
    - 13K bytes
    - Viewed (0)
  3. docs/en/docs/tutorial/query-params-str-validations.md

        ```
    
    The query parameter `q` is of type `Union[str, None]` (or `str | None` in Python 3.10), that means that it's of type `str` but could also be `None`, and indeed, the default value is `None`, so FastAPI will know it's not required.
    
    !!! note
        FastAPI will know that the value of `q` is not required because of the default value `= None`.
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Fri May 31 02:38:05 UTC 2024
    - 25.8K bytes
    - Viewed (0)
  4. src/encoding/json/encode_test.go

    	Bo bool `json:"bo,omitempty"`
    
    	Ur uint `json:"ur"`
    	Uo uint `json:"uo,omitempty"`
    
    	Str struct{} `json:"str"`
    	Sto struct{} `json:"sto,omitempty"`
    }
    
    func TestOmitEmpty(t *testing.T) {
    	var want = `{
     "sr": "",
     "omitempty": 0,
     "slr": null,
     "mr": {},
     "fr": 0,
     "br": false,
     "ur": 0,
     "str": {},
     "sto": {}
    }`
    	var o Optionals
    	o.Sw = "something"
    	o.Mr = map[string]any{}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 29.4K bytes
    - Viewed (0)
  5. src/cmd/vendor/github.com/google/pprof/profile/profile.go

    	NumUnit map[string][]string
    
    	locationIDX []uint64
    	labelX      []label
    }
    
    // label corresponds to Profile.Label
    type label struct {
    	keyX int64
    	// Exactly one of the two following values must be set
    	strX int64
    	numX int64 // Integer value for this label
    	// can be set if numX has value
    	unitX int64
    }
    
    // Mapping corresponds to Profile.Mapping
    type Mapping struct {
    	ID              uint64
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 31 19:48:28 UTC 2024
    - 22.3K bytes
    - Viewed (0)
Back to top