Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 54 for absDate (1 sec)

  1. src/time/format_rfc3339.go

    // the addition of logic to optimize formatting and parsing.
    
    func (t Time) appendFormatRFC3339(b []byte, nanos bool) []byte {
    	_, offset, abs := t.locabs()
    
    	// Format date.
    	year, month, day, _ := absDate(abs, true)
    	b = appendInt(b, year, 4)
    	b = append(b, '-')
    	b = appendInt(b, int(month), 2)
    	b = append(b, '-')
    	b = appendInt(b, day, 2)
    
    	b = append(b, 'T')
    
    	// Format time.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 18 19:59:26 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  2. src/time/time.go

    // the month and day in which t occurs.
    func (t Time) date(full bool) (year int, month Month, day int, yday int) {
    	return absDate(t.abs(), full)
    }
    
    // absDate is like date but operates on an absolute time.
    //
    // absDate should be an internal detail,
    // but widely used packages access it using linkname.
    // Notable members of the hall of shame include:
    //   - github.com/phuslu/log
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 50.7K bytes
    - Viewed (0)
  3. src/time/zoneinfo.go

    		return "", 0, 0, 0, false, false
    	}
    	s = s[1:]
    	endRule, s, ok = tzsetRule(s)
    	if !ok || len(s) > 0 {
    		return "", 0, 0, 0, false, false
    	}
    
    	year, _, _, yday := absDate(uint64(sec+unixToInternal+internalToAbsolute), false)
    
    	ysec := int64(yday*secondsPerDay) + sec%secondsPerDay
    
    	// Compute start of year in seconds since Unix epoch.
    	d := daysSinceEpoch(year)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 14:21:30 UTC 2024
    - 18.2K bytes
    - Viewed (0)
  4. src/time/format.go

    		s += string(buf)
    	}
    	return s
    }
    
    // GoString implements [fmt.GoStringer] and formats t to be printed in Go source
    // code.
    func (t Time) GoString() string {
    	abs := t.abs()
    	year, month, day, _ := absDate(abs, true)
    	hour, minute, second := absClock(abs)
    
    	buf := make([]byte, 0, len("time.Date(9999, time.September, 31, 23, 59, 59, 999999999, time.Local)"))
    	buf = append(buf, "time.Date("...)
    	buf = appendInt(buf, year, 0)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 17:09:28 UTC 2024
    - 49.3K bytes
    - Viewed (0)
  5. cmd/importverifier/importverifier.go

    }
    
    // isPathUnder determines if path is under base
    func isPathUnder(base, path string) (bool, error) {
    	absBase, err := filepath.Abs(base)
    	if err != nil {
    		return false, err
    	}
    	absPath, err := filepath.Abs(path)
    	if err != nil {
    		return false, err
    	}
    
    	relPath, err := filepath.Rel(absBase, absPath)
    	if err != nil {
    		return false, err
    	}
    
    	// if path is below base, the relative path
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Mar 01 06:06:16 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  6. src/os/file_open_wasip1.go

    		return -1, poll.SysFile{}, syscall.EINVAL
    	}
    	absPath := filePath
    	// os.(*File).Chdir is emulated by setting the working directory to the
    	// absolute path that this file was opened at, which is why we have to
    	// resolve and capture it here.
    	if filePath[0] != '/' {
    		wd, err := syscall.Getwd()
    		if err != nil {
    			return -1, poll.SysFile{}, err
    		}
    		absPath = joinPath(wd, filePath)
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 07 23:34:21 UTC 2023
    - 818 bytes
    - Viewed (0)
  7. staging/src/k8s.io/apiextensions-apiserver/test/integration/limit_test.go

    kind: %s
    metadata:
      name: test
    values: `+strings.Repeat("[", 3*1024*1024), apiVersion, kind))
    
    		_, err := rest.Post().
    			SetHeader("Accept", "application/yaml").
    			SetHeader("Content-Type", "application/yaml").
    			AbsPath("/apis", noxuDefinition.Spec.Group, noxuDefinition.Spec.Versions[0].Name, noxuDefinition.Spec.Names.Plural).
    			Body(yamlBody).
    			DoRaw(context.TODO())
    		if !apierrors.IsRequestEntityTooLargeError(err) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 02 19:34:41 UTC 2021
    - 8K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiextensions-apiserver/test/integration/apply_test.go

    	result, err := rest.Patch(types.ApplyPatchType).
    		AbsPath("/apis", noxuDefinition.Spec.Group, noxuDefinition.Spec.Versions[0].Name, noxuDefinition.Spec.Names.Plural).
    		Name("mytest").
    		Param("fieldManager", "apply_test").
    		Body(yamlBody).
    		DoRaw(context.TODO())
    	if err != nil {
    		t.Fatal(err, string(result))
    	}
    
    	result, err = rest.Patch(types.MergePatchType).
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Sep 27 11:48:28 UTC 2022
    - 3.5K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiextensions-apiserver/test/integration/yaml_test.go

    	rest := apiExtensionClient.Discovery().RESTClient()
    
    	// Discovery
    	{
    		result, err := rest.Get().
    			SetHeader("Accept", "application/yaml").
    			AbsPath("/apis", noxuDefinition.Spec.Group, noxuDefinition.Spec.Versions[0].Name).
    			DoRaw(context.TODO())
    		if err != nil {
    			t.Fatal(err, string(result))
    		}
    		obj, err := decodeYAML(result)
    		if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 02 19:34:41 UTC 2021
    - 16.5K bytes
    - Viewed (0)
  10. platforms/core-configuration/model-core/src/test/groovy/org/gradle/model/internal/core/ModelReferenceTest.groovy

            def reference = ModelReference.of("some.path", String).atState(ModelNode.State.Mutated)
            reference.scope == null
            reference.path == ModelPath.path("some.path")
            reference.type == ModelType.of(String)
            !reference.untyped
            reference.state == ModelNode.State.Mutated
    
            def original = ModelReference.of(String)
            original.atState(original.state).is(original)
        }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 3.9K bytes
    - Viewed (0)
Back to top