Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 64 for ParseDuration (0.79 sec)

  1. staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1/types_jsonschema.go

    	// - byte: base64 encoded binary data
    	// - password: any kind of string
    	// - date: a date string like "2006-01-02" as defined by full-date in RFC3339
    	// - duration: a duration string like "22 ns" as parsed by Golang time.ParseDuration or compatible with Scala duration format
    	// - datetime: a date time string like "2014-12-15T19:30:20.000Z" as defined by date-time in RFC3339.
    	Format string `json:"format,omitempty" protobuf:"bytes,6,opt,name=format"`
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Nov 27 20:06:21 UTC 2023
    - 24.7K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/cel/common/values.go

    		str, ok := unstructured.(string)
    		if !ok {
    			return types.NewErr("invalid data, expected string, got %T", unstructured)
    		}
    		switch schema.Format() {
    		case "duration":
    			d, err := strfmt.ParseDuration(str)
    			if err != nil {
    				return types.NewErr("Invalid duration %s: %v", str, err)
    			}
    			return types.Duration{Duration: d}
    		case "date":
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Oct 23 22:30:17 UTC 2023
    - 20.5K bytes
    - Viewed (0)
  3. src/time/format.go

    	"m":  uint64(Minute),
    	"h":  uint64(Hour),
    }
    
    // ParseDuration parses a duration string.
    // A duration string is a possibly signed sequence of
    // decimal numbers, each with optional fraction and a unit suffix,
    // such as "300ms", "-1.5h" or "2h45m".
    // Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
    func ParseDuration(s string) (Duration, error) {
    	// [-+]?([0-9]*(\.[0-9]*)?[a-z]+)+
    	orig := s
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 17:09:28 UTC 2024
    - 49.3K bytes
    - Viewed (0)
  4. src/testing/benchmark.go

    		if err != nil || n < 0 || (!f.allowZero && n == 0) {
    			return fmt.Errorf("invalid count")
    		}
    		*f = durationOrCountFlag{n: int(n)}
    		return nil
    	}
    	d, err := time.ParseDuration(s)
    	if err != nil || d < 0 || (!f.allowZero && d == 0) {
    		return fmt.Errorf("invalid duration")
    	}
    	*f = durationOrCountFlag{d: d}
    	return nil
    }
    
    // Global lock to ensure only one benchmark runs at a time.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 23.9K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1/types_jsonschema.go

    	// - byte: base64 encoded binary data
    	// - password: any kind of string
    	// - date: a date string like "2006-01-02" as defined by full-date in RFC3339
    	// - duration: a duration string like "22 ns" as parsed by Golang time.ParseDuration or compatible with Scala duration format
    	// - datetime: a date time string like "2014-12-15T19:30:20.000Z" as defined by date-time in RFC3339.
    	Format string `json:"format,omitempty" protobuf:"bytes,6,opt,name=format"`
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Nov 27 20:06:21 UTC 2023
    - 24.7K bytes
    - Viewed (0)
  6. src/cmd/go/internal/script/cmds.go

    			},
    			Async: true,
    		},
    		func(s *State, args ...string) (WaitFunc, error) {
    			if len(args) != 1 {
    				return nil, ErrUsage
    			}
    
    			d, err := time.ParseDuration(args[0])
    			if err != nil {
    				return nil, err
    			}
    
    			timer := time.NewTimer(d)
    			wait := func(s *State) (stdout, stderr string, err error) {
    				ctx := s.Context()
    				select {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 26 19:58:28 UTC 2024
    - 28.5K bytes
    - Viewed (0)
  7. pilot/pkg/networking/core/listener_inbound.go

    	}
    	tcpProxy := &tcp.TcpProxy{
    		StatPrefix:       statPrefix,
    		ClusterSpecifier: &tcp.TcpProxy_Cluster{Cluster: fcc.clusterName},
    		IdleTimeout:      parseDuration(lb.node.Metadata.IdleTimeout),
    	}
    	tcpFilter := setAccessLogAndBuildTCPFilter(lb.push, lb.node, tcpProxy, istionetworking.ListenerClassSidecarInbound, fcc.policyService)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Jun 13 01:56:28 UTC 2024
    - 35.1K bytes
    - Viewed (0)
  8. src/database/sql/fakedb_test.go

    		if firstStmt == nil {
    			firstStmt = stmt
    		}
    		if len(parts) >= 3 {
    			switch parts[0] {
    			case "PANIC":
    				stmt.panic = parts[1]
    				parts = parts[2:]
    			case "WAIT":
    				wait, err := time.ParseDuration(parts[1])
    				if err != nil {
    					return nil, errf("expected section after WAIT to be a duration, got %q %v", parts[1], err)
    				}
    				parts = parts[2:]
    				stmt.wait = wait
    			}
    		}
    		cmd := parts[0]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 01 12:38:07 UTC 2024
    - 30.3K bytes
    - Viewed (0)
  9. pilot/pkg/config/kube/gateway/conversion.go

    			}
    		}
    	}
    
    	if r.Timeouts != nil {
    		if r.Timeouts.Request != nil {
    			request, _ := time.ParseDuration(string(*r.Timeouts.Request))
    			if request != 0 {
    				vs.Timeout = durationpb.New(request)
    			}
    		}
    		if r.Timeouts.BackendRequest != nil {
    			backendRequest, _ := time.ParseDuration(string(*r.Timeouts.BackendRequest))
    			if backendRequest != 0 {
    				timeout := durationpb.New(backendRequest)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri Jun 14 04:34:37 UTC 2024
    - 84.7K bytes
    - Viewed (0)
  10. staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1/generated.proto

      // - password: any kind of string
      // - date: a date string like "2006-01-02" as defined by full-date in RFC3339
      // - duration: a duration string like "22 ns" as parsed by Golang time.ParseDuration or compatible with Scala duration format
      // - datetime: a date time string like "2014-12-15T19:30:20.000Z" as defined by date-time in RFC3339.
      optional string format = 6;
    
      optional string title = 7;
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 28 15:34:11 UTC 2024
    - 41.8K bytes
    - Viewed (0)
Back to top