Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 2,456 for map1 (0.23 sec)

  1. src/internal/types/testdata/check/map1.go

    // license that can be found in the LICENSE file.
    
    // This file is like map.go2, but instead if importing chans, it contains
    // the necessary functionality at the end of the file.
    
    // Package orderedmap provides an ordered map, implemented as a binary tree.
    package orderedmap
    
    // Map is an ordered map.
    type Map[K, V any] struct {
    	root    *node[K, V]
    	compare func(K, K) int
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 02 02:58:32 UTC 2022
    - 3.4K bytes
    - Viewed (0)
  2. src/runtime/pprof/proto_test.go

    		// Fake mapping - HasFunctions will be true because two PCs from Go
    		// will be fully symbolized.
    		fake := &profile.Mapping{ID: 1, HasFunctions: true}
    		map1, map2 = fake, fake
    	}
    	return
    }
    
    func TestConvertCPUProfile(t *testing.T) {
    	addr1, addr2, map1, map2 := testPCs(t)
    
    	b := []uint64{
    		3, 0, 500, // hz = 500
    		5, 0, 10, uint64(addr1 + 1), uint64(addr1 + 2), // 10 samples in addr1
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 31 23:21:53 UTC 2024
    - 17K bytes
    - Viewed (0)
  3. src/runtime/pprof/protomem_test.go

    			Location: []*profile.Location{
    				{ID: 1, Mapping: map1, Address: addr1},
    				{ID: 2, Mapping: map2, Address: addr2},
    			},
    			NumLabel: map[string][]int64{"bytes": {1024}},
    		},
    		{
    			Value: []int64{1, 829411, 1, 829411},
    			Location: []*profile.Location{
    				{ID: 3, Mapping: map2, Address: addr2 + 1},
    				{ID: 4, Mapping: map2, Address: addr2 + 2},
    			},
    			NumLabel: map[string][]int64{"bytes": {512 * 1024}},
    		},
    		{
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 21 14:38:45 UTC 2024
    - 6.7K bytes
    - Viewed (0)
  4. subprojects/core/src/testFixtures/groovy/org/gradle/util/TestTask.groovy

    class TestTask extends ConventionTask  {
        @Internal
        TestTask self
        @Internal
        String customProp
        @Internal
        List list1
        @Internal
        List list2
        @Internal
        Map map1
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Apr 26 10:58:32 UTC 2023
    - 922 bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/collect/MapsTest.java

        TreeMap<Integer, Integer> map = Maps.newTreeMap(SOME_COMPARATOR);
        assertEquals(Collections.emptyMap(), map);
        assertSame(SOME_COMPARATOR, map.comparator());
      }
    
      public void testTreeMapWithInitialMap() {
        SortedMap<Integer, Integer> map = Maps.newTreeMap();
        map.put(5, 10);
        map.put(3, 20);
        map.put(1, 30);
        TreeMap<Integer, Integer> copy = Maps.newTreeMap(map);
        assertEquals(copy, map);
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 17 15:27:58 UTC 2024
    - 67.1K bytes
    - Viewed (0)
  6. platforms/core-configuration/model-core/src/test/groovy/org/gradle/internal/extensibility/ConventionAwareHelperTest.java

            conventionAware.map("list1", new Callable<Object>() {
                public Object call() {
                    return toList("a");
                }
            });
            assertThat(conventionAware.getConventionValue(emptyList(), "list1", false), equalTo((Object) toList("a")));
        }
    
        @Test public void usesConventionValueForEmptyMap() {
            conventionAware.map("map1", new Callable<Object>() {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 5.9K bytes
    - Viewed (0)
  7. platforms/core-configuration/model-core/src/test/groovy/org/gradle/internal/snapshot/impl/DefaultValueSnapshotterTest.groovy

        }
    
        def "creates snapshot for map from candidate"() {
            def map1 = [:]
            map1.put(new Bean(prop: "value"), new Bean(prop: "value"))
            def map2 = [:]
            map2.put(new Bean(prop: "value"), new Bean(prop: "value2"))
            def map3 = [:]
            map3.putAll(map1)
            map3.put(new Bean(prop: "value2"), new Bean(prop: "value2"))
    
            expect:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 29.5K bytes
    - Viewed (0)
  8. src/mdo/java/ImmutableCollections.java

                };
            }
        }
    
        private static class MapN<K, V> extends AbstractImmutableMap<K, V> {
            private final Object[] entries;
    
            private MapN(Map<K, V> map) {
                if (map != null) {
                    entries = new Object[map.size()];
                    int idx = 0;
                    for (Map.Entry<K, V> e : map.entrySet()) {
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Mon Jan 22 17:27:48 UTC 2024
    - 16.7K bytes
    - Viewed (0)
  9. maven-xml-impl/src/main/java/org/apache/maven/internal/xml/ImmutableCollections.java

        }
    
        static <K, V> Map<K, V> copy(Map<K, V> map) {
            if (map == null) {
                return emptyMap();
            } else if (map instanceof AbstractImmutableMap) {
                return map;
            } else {
                switch (map.size()) {
                    case 0:
                        return emptyMap();
                    case 1:
                        Map.Entry<K, V> entry = map.entrySet().iterator().next();
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Mon Jan 22 17:27:48 UTC 2024
    - 16.4K bytes
    - Viewed (0)
  10. src/expvar/expvar_test.go

    	}
    }
    
    func TestHandler(t *testing.T) {
    	RemoveAll()
    	m := NewMap("map1")
    	m.Add("a", 1)
    	m.Add("z", 2)
    	m2 := NewMap("map2")
    	for i := 0; i < 9; i++ {
    		m2.Add(strconv.Itoa(i), int64(i))
    	}
    	rr := httptest.NewRecorder()
    	rr.Body = new(bytes.Buffer)
    	expvarHandler(rr, nil)
    	want := `{
    "map1": {"a": 1, "z": 2},
    "map2": {"0": 0, "1": 1, "2": 2, "3": 3, "4": 4, "5": 5, "6": 6, "7": 7, "8": 8}
    }
    `
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 14:46:19 UTC 2024
    - 13.4K bytes
    - Viewed (0)
Back to top