Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 24 for decodeInt8 (0.14 sec)

  1. src/encoding/gob/decgen.go

    		"Int32",
    		`x := state.decodeInt()
    		if x < math.MinInt32 || math.MaxInt32 < x {
    			error_(ovfl)
    		}
    		slice[i] = int32(x)`,
    	},
    	{
    		"int64",
    		"Int64",
    		`slice[i] = state.decodeInt()`,
    	},
    	{
    		"int8",
    		"Int8",
    		`x := state.decodeInt()
    		if x < math.MinInt8 || math.MaxInt8 < x {
    			error_(ovfl)
    		}
    		slice[i] = int8(x)`,
    	},
    	{
    		"string",
    		"String",
    		`u := state.decodeUint()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Mar 20 14:15:38 UTC 2024
    - 5.3K bytes
    - Viewed (0)
  2. pkg/scheduler/framework/runtime/registry_test.go

    	for _, test := range tests {
    		t.Run(test.name, func(t *testing.T) {
    			var pluginFooConf PluginFooConfig
    			if err := DecodeInto(test.args, &pluginFooConf); err != nil {
    				t.Errorf("DecodeInto(): failed to decode args %+v: %v", test.args, err)
    			}
    			if !reflect.DeepEqual(test.expected, pluginFooConf) {
    				t.Errorf("DecodeInto(): failed to decode plugin config, expected: %+v, got: %+v",
    					test.expected, pluginFooConf)
    			}
    		})
    	}
    }
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Sep 20 09:49:54 UTC 2023
    - 6.5K bytes
    - Viewed (0)
  3. pkg/scheduler/framework/runtime/registry.go

    	return func(ctx context.Context, plArgs runtime.Object, fh framework.Handle) (framework.Plugin, error) {
    		return withFts(ctx, plArgs, fh, fts)
    	}
    }
    
    // DecodeInto decodes configuration whose type is *runtime.Unknown to the interface into.
    func DecodeInto(obj runtime.Object, into interface{}) error {
    	if obj == nil {
    		return nil
    	}
    	configuration, ok := obj.(*runtime.Unknown)
    	if !ok {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Sep 20 09:49:54 UTC 2023
    - 3.3K bytes
    - Viewed (0)
  4. cmd/kubeadm/app/phases/addons/dns/dns.go

    	return nil
    }
    
    func createCoreDNSAddon(deploymentBytes, serviceBytes, configBytes []byte, client clientset.Interface) error {
    	coreDNSConfigMap := &v1.ConfigMap{}
    	if err := kuberuntime.DecodeInto(clientsetscheme.Codecs.UniversalDecoder(), configBytes, coreDNSConfigMap); err != nil {
    		return errors.Wrapf(err, "%s ConfigMap", unableToDecodeCoreDNS)
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 11 10:21:20 UTC 2024
    - 16.1K bytes
    - Viewed (0)
  5. pkg/api/testing/serialization_test.go

    	t.Logf("rs.v1.apps -> rc._internal")
    	if err := runtime.DecodeInto(decoder, data, rc); err != nil {
    		t.Fatalf("unexpected decoding error: %v", err)
    	}
    
    	t.Logf("rc._internal -> rc.v1")
    	data, err = runtime.Encode(defaultCodec, rc)
    	if err != nil {
    		t.Fatalf("unexpected encoding error: %v", err)
    	}
    
    	t.Logf("rc.v1 -> rs._internal.apps")
    	if err := runtime.DecodeInto(decoder, data, rs); err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Sep 25 11:04:08 UTC 2023
    - 19.3K bytes
    - Viewed (0)
  6. cmd/kubeadm/app/phases/addons/proxy/proxy.go

    	}
    
    	if printManifest {
    		return configMapBytes, nil
    	}
    
    	kubeproxyConfigMap := &v1.ConfigMap{}
    	if err := kuberuntime.DecodeInto(clientsetscheme.Codecs.UniversalDecoder(), configMapBytes, kubeproxyConfigMap); err != nil {
    		return []byte(""), errors.Wrap(err, "unable to decode kube-proxy configmap")
    	}
    
    	if !kubeProxyCfg.IsUserSupplied() {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Sep 26 13:23:44 UTC 2023
    - 8.1K bytes
    - Viewed (0)
  7. cmd/kubeadm/app/phases/uploadconfig/uploadconfig_test.go

    				if configData == "" {
    					t2.Fatal("Fail to find ClusterConfigurationConfigMapKey key")
    				}
    
    				decodedCfg := &kubeadmapi.ClusterConfiguration{}
    				if err := runtime.DecodeInto(kubeadmscheme.Codecs.UniversalDecoder(), []byte(configData), decodedCfg); err != nil {
    					t2.Fatalf("unable to decode config from bytes: %v", err)
    				}
    
    				if len(decodedCfg.ComponentConfigs) != 0 {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Oct 24 08:46:51 UTC 2023
    - 3.4K bytes
    - Viewed (0)
  8. cmd/kubeadm/app/util/config/joinconfiguration.go

    	}
    
    	if len(joinBytes) == 0 {
    		return nil, errors.Errorf("no %s found in the supplied config", constants.JoinConfigurationKind)
    	}
    
    	internalcfg := &kubeadmapi.JoinConfiguration{}
    	if err := runtime.DecodeInto(kubeadmscheme.Codecs.UniversalDecoder(), joinBytes, internalcfg); err != nil {
    		return nil, err
    	}
    
    	// Applies dynamic defaults to settings not provided with flags
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jan 05 12:41:16 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  9. cmd/kubeadm/app/util/config/resetconfiguration.go

    	}
    
    	if len(resetBytes) == 0 {
    		return nil, errors.Errorf("no %s found in the supplied config", constants.JoinConfigurationKind)
    	}
    
    	internalcfg := &kubeadmapi.ResetConfiguration{}
    	if err := runtime.DecodeInto(kubeadmscheme.Codecs.UniversalDecoder(), resetBytes, internalcfg); err != nil {
    		return nil, err
    	}
    
    	// Applies dynamic defaults to settings not provided with flags
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jan 05 12:41:16 UTC 2024
    - 6.6K bytes
    - Viewed (0)
  10. src/encoding/gob/decode.go

    	for _, b := range buf[0:n] {
    		x = x<<8 | uint64(b)
    	}
    	state.b.Drop(n)
    	return x
    }
    
    // decodeInt reads an encoded signed integer from state.r.
    // Does not check for overflow.
    func (state *decoderState) decodeInt() int64 {
    	x := state.decodeUint()
    	if x&1 != 0 {
    		return ^int64(x >> 1)
    	}
    	return int64(x >> 1)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Sep 07 19:10:23 UTC 2023
    - 40.1K bytes
    - Viewed (0)
Back to top