Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 252 for newWith (0.21 sec)

  1. src/text/template/parse/node.go

    type WithNode struct {
    	BranchNode
    }
    
    func (t *Tree) newWith(pos Pos, line int, pipe *PipeNode, list, elseList *ListNode) *WithNode {
    	return &WithNode{BranchNode{tr: t, NodeType: NodeWith, Pos: pos, Line: line, Pipe: pipe, List: list, ElseList: elseList}}
    }
    
    func (w *WithNode) Copy() Node {
    	return w.tr.newWith(w.Pos, w.Line, w.Pipe.CopyPipe(), w.List.CopyList(), w.ElseList.CopyList())
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Feb 26 20:57:51 UTC 2024
    - 24.2K bytes
    - Viewed (0)
  2. internal/grid/types.go

    			return newFn()
    		}},
    	}
    }
    
    // New returns a new empty Array.
    func (p *ArrayOf[T]) New() *Array[T] {
    	return &Array[T]{
    		p: p,
    	}
    }
    
    // NewWith returns a new Array with the provided value (not copied).
    func (p *ArrayOf[T]) NewWith(val []T) *Array[T] {
    	return &Array[T]{
    		p:   p,
    		val: val,
    	}
    }
    
    func (p *ArrayOf[T]) newA(sz uint32) []T {
    	t, ok := p.aPool.Get().(*[]T)
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Apr 01 23:42:09 UTC 2024
    - 15.4K bytes
    - Viewed (0)
  3. cmd/peer-rest-server.go

    		if m.VariableLabels == nil {
    			m.VariableLabels = make(map[string]string, 1)
    		}
    		m.VariableLabels[serverName] = globalLocalNodeName
    		res = append(res, &m)
    		return true
    	})
    	return aoMetricsGroup.NewWith(res), nil
    }
    
    // GetPeerMetrics gets the metrics to be federated across peers.
    func (s *peerRESTServer) GetPeerMetrics(_ *grid.MSS) (*grid.Array[*MetricV2], *grid.RemoteErr) {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 52.1K bytes
    - Viewed (0)
  4. src/text/template/parse/parse.go

    	return r
    }
    
    // With:
    //
    //	{{with pipeline}} itemList {{end}}
    //	{{with pipeline}} itemList {{else}} itemList {{end}}
    //
    // If keyword is past.
    func (t *Tree) withControl() Node {
    	return t.newWith(t.parseControl("with"))
    }
    
    // End:
    //
    //	{{end}}
    //
    // End keyword is past.
    func (t *Tree) endControl() Node {
    	return t.newEnd(t.expect(itemRightDelim, "end").pos)
    }
    
    // Else:
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Feb 26 20:57:51 UTC 2024
    - 21.3K bytes
    - Viewed (0)
  5. pkg/proxy/apis/config/validation/validation_test.go

    			},
    			expectedErrs: field.ErrorList{field.Invalid(newPath.Child("KubeIPVSConfiguration.TCPTimeout"), metav1.Duration{Duration: -1 * time.Second}, "must be greater than or equal to 0"),
    				field.Invalid(newPath.Child("KubeIPVSConfiguration.TCPFinTimeout"), metav1.Duration{Duration: -1 * time.Second}, "must be greater than or equal to 0"),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 14:24:16 UTC 2024
    - 33.3K bytes
    - Viewed (0)
  6. pkg/config/schema/collection/schemas_test.go

    		Proto:        "google.protobuf.Struct",
    	}.MustBuild()
    )
    
    func TestSchemas_Basic(t *testing.T) {
    	g := NewWithT(t)
    
    	schemas := collection.SchemasFor(emptyResource)
    	g.Expect(schemas.All()).To(HaveLen(1))
    	g.Expect(schemas.All()[0]).To(Equal(emptyResource))
    }
    
    func TestSchemas_MustAdd(t *testing.T) {
    	g := NewWithT(t)
    	defer func() {
    		r := recover()
    		g.Expect(r).To(BeNil())
    	}()
    	b := collection.NewSchemasBuilder()
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Oct 31 14:48:28 UTC 2023
    - 5.4K bytes
    - Viewed (0)
  7. pkg/apis/resource/validation/validation.go

    	allErrs = append(allErrs, validateClassParameters(parameters.GeneratedFrom, field.NewPath("generatedFrom"))...)
    	allErrs = append(allErrs, validateResourceFilters(parameters.Filters, field.NewPath("filters"), filtersStored)...)
    	allErrs = append(allErrs, validateVendorParameters(parameters.VendorParameters, field.NewPath("vendorParameters"))...)
    	return allErrs
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 07 09:18:10 UTC 2024
    - 28.3K bytes
    - Viewed (0)
  8. pkg/apis/flowcontrol/validation/validation_test.go

    		expectedErrors: field.ErrorList{
    			field.Required(field.NewPath("spec").Child("rules").Index(0).Child("subjects").Index(0).Child("serviceAccount"), "serviceAccount is required when subject kind is 'ServiceAccount'"),
    			field.Forbidden(field.NewPath("spec").Child("rules").Index(0).Child("subjects").Index(0).Child("user"), "user is forbidden when subject kind is not 'User'"),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Oct 30 22:22:51 UTC 2023
    - 54.7K bytes
    - Viewed (0)
  9. pkg/apis/storage/validation/validation.go

    	allErrs = append(allErrs, validateProvisioner(storageClass.Provisioner, field.NewPath("provisioner"))...)
    	allErrs = append(allErrs, validateParameters(storageClass.Parameters, true, field.NewPath("parameters"))...)
    	allErrs = append(allErrs, validateReclaimPolicy(storageClass.ReclaimPolicy, field.NewPath("reclaimPolicy"))...)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Feb 28 00:47:13 UTC 2024
    - 25.5K bytes
    - Viewed (0)
  10. pkg/config/analysis/diag/messages_test.go

    // limitations under the License.
    
    package diag
    
    import (
    	"testing"
    
    	. "github.com/onsi/gomega"
    
    	"istio.io/istio/pkg/url"
    )
    
    func TestMessages_Sort(t *testing.T) {
    	g := NewWithT(t)
    
    	firstMsg := NewMessage(
    		NewMessageType(Error, "B1", "Template: %q"),
    		MockResource("B"),
    		"B",
    	)
    	secondMsg := NewMessage(
    		NewMessageType(Warning, "A1", "Template: %q"),
    		MockResource("B"),
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Oct 31 14:48:28 UTC 2023
    - 4.2K bytes
    - Viewed (0)
Back to top