Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 62 for newFunc (0.5 sec)

  1. staging/src/k8s.io/apiserver/pkg/reconcilers/peer_endpoint_lease_test.go

    	t.Cleanup(func() { server.Terminate(t) })
    
    	newFunc := func() runtime.Object { return &corev1.Endpoints{} }
    	newListFunc := func() runtime.Object { return &corev1.EndpointsList{} }
    	sc.Codec = apitesting.TestStorageCodec(codecs, corev1.SchemeGroupVersion)
    
    	s, dFunc, err := factory.Create(*sc.ForResource(schema.GroupResource{Resource: "endpoints"}), newFunc, newListFunc, "")
    	if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 8.7K bytes
    - Viewed (0)
  2. pkg/registry/resource/resourceclaimparameters/storage/storage.go

    	*genericregistry.Store
    }
    
    // NewREST returns a RESTStorage object that will work against ResourceClaimParameters.
    func NewREST(optsGetter generic.RESTOptionsGetter) (*REST, error) {
    	store := &genericregistry.Store{
    		NewFunc:                   func() runtime.Object { return &resource.ResourceClaimParameters{} },
    		NewListFunc:               func() runtime.Object { return &resource.ResourceClaimParametersList{} },
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 15:15:31 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher_test.go

    		enableWatchList bool
    		expectedErr     error
    	}{
    		{
    			name:        "no newFunc provided",
    			setupFn:     func(opts *setupOptions) { opts.newFunc = nil },
    			requestOpts: storage.ListOptions{ProgressNotify: true},
    			expectedErr: apierrors.NewInternalError(errors.New("progressNotify for watch is unsupported by the etcd storage because no newFunc was provided")),
    		},
    	}
    	for _, scenario := range scenarios {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 12.3K bytes
    - Viewed (0)
  4. pkg/registry/resource/resourceslice/storage/storage.go

    	*genericregistry.Store
    }
    
    // NewREST returns a RESTStorage object that will work against ResourceSlice.
    func NewREST(optsGetter generic.RESTOptionsGetter) (*REST, error) {
    	store := &genericregistry.Store{
    		NewFunc:                   func() runtime.Object { return &resource.ResourceSlice{} },
    		NewListFunc:               func() runtime.Object { return &resource.ResourceSliceList{} },
    		PredicateFunc:             resourceslice.Match,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 21:22:55 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  5. pkg/registry/resource/resourceclassparameters/storage/storage.go

    	*genericregistry.Store
    }
    
    // NewREST returns a RESTStorage object that will work against ResourceClassParameters.
    func NewREST(optsGetter generic.RESTOptionsGetter) (*REST, error) {
    	store := &genericregistry.Store{
    		NewFunc:                   func() runtime.Object { return &resource.ResourceClassParameters{} },
    		NewListFunc:               func() runtime.Object { return &resource.ResourceClassParametersList{} },
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 15:15:31 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  6. src/go/types/instantiate_test.go

    			"package equivalentinterfaces; type T[P any] int",
    			"T", []Type{
    				NewInterfaceType([]*Func{NewFunc(nopos, nil, "M", emptySignature)}, nil),
    			},
    			"T", []Type{
    				NewInterfaceType(
    					nil,
    					[]Type{
    						NewInterfaceType([]*Func{NewFunc(nopos, nil, "M", emptySignature)}, nil),
    					},
    				),
    			},
    			true,
    		},
    		{
    			// int|string is equivalent to string|int
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  7. staging/src/k8s.io/apiserver/pkg/storage/etcd3/store.go

    		pathPrefix += "/"
    	}
    
    	w := &watcher{
    		client:        c,
    		codec:         codec,
    		newFunc:       newFunc,
    		groupResource: groupResource,
    		versioner:     versioner,
    		transformer:   transformer,
    	}
    	if newFunc == nil {
    		w.objectType = "<unknown>"
    	} else {
    		w.objectType = reflect.TypeOf(newFunc()).String()
    	}
    	s := &store{
    		client:              c,
    		codec:               codec,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 11:56:42 UTC 2024
    - 35.2K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store.go

    //
    // TODO: make the default exposed methods exactly match a generic RESTStorage
    type Store struct {
    	// NewFunc returns a new instance of the type this registry returns for a
    	// GET of a single object, e.g.:
    	//
    	// curl GET /apis/group/version/namespaces/my-ns/myresource/name-of-object
    	NewFunc func() runtime.Object
    
    	// NewListFunc returns a new list of the type this registry; it is the
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jan 19 23:22:44 UTC 2024
    - 60.8K bytes
    - Viewed (0)
  9. src/go/types/object.go

    	origin      *Func // if non-nil, the Func from which this one was instantiated
    }
    
    // NewFunc returns a new function with the given signature, representing
    // the function's type.
    func NewFunc(pos token.Pos, pkg *Package, name string, sig *Signature) *Func {
    	var typ Type
    	if sig != nil {
    		typ = sig
    	} else {
    		// Don't store a (typed) nil *Signature.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 20.1K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/types2/object.go

    	origin      *Func // if non-nil, the Func from which this one was instantiated
    }
    
    // NewFunc returns a new function with the given signature, representing
    // the function's type.
    func NewFunc(pos syntax.Pos, pkg *Package, name string, sig *Signature) *Func {
    	var typ Type
    	if sig != nil {
    		typ = sig
    	} else {
    		// Don't store a (typed) nil *Signature.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 20.1K bytes
    - Viewed (0)
Back to top