Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for MapEntrySnapshot (0.24 sec)

  1. platforms/core-execution/snapshots/src/main/java/org/gradle/internal/snapshot/impl/MapEntrySnapshot.java

     * See the License for the specific language governing permissions and
     * limitations under the License.
     */
    
    package org.gradle.internal.snapshot.impl;
    
    public class MapEntrySnapshot<T> {
        private final T key;
        private final T value;
    
        public MapEntrySnapshot(T key, T value) {
            this.key = key;
            this.value = value;
        }
    
        public T getKey() {
            return key;
        }
    
        public T getValue() {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 09:34:50 UTC 2023
    - 1.6K bytes
    - Viewed (0)
  2. platforms/core-configuration/model-core/src/main/java/org/gradle/internal/snapshot/impl/AbstractIsolatedMap.java

        public AbstractIsolatedMap(ImmutableList<MapEntrySnapshot<Isolatable<?>>> entries) {
            super(entries);
        }
    
        @Override
        public ValueSnapshot asSnapshot() {
            ImmutableList.Builder<MapEntrySnapshot<ValueSnapshot>> builder = ImmutableList.builderWithExpectedSize(entries.size());
            for (MapEntrySnapshot<Isolatable<?>> entry : entries) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 1.9K bytes
    - Viewed (0)
  3. platforms/core-configuration/model-core/src/main/java/org/gradle/internal/snapshot/impl/AbstractMapSnapshot.java

    class AbstractMapSnapshot<T extends Hashable> implements Hashable {
        protected final ImmutableList<MapEntrySnapshot<T>> entries;
    
        public AbstractMapSnapshot(ImmutableList<MapEntrySnapshot<T>> entries) {
            this.entries = entries;
        }
    
        public ImmutableList<MapEntrySnapshot<T>> getEntries() {
            return entries;
        }
    
        @Override
        public void appendToHasher(Hasher hasher) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 1.9K bytes
    - Viewed (0)
  4. platforms/core-configuration/core-serialization-codecs/src/main/kotlin/org/gradle/internal/serialize/codecs/core/IsolatedCodecs.kt

        override suspend fun ReadContext.decode(): IsolatedMap {
            val elements = readNonNull<ImmutableList<MapEntrySnapshot<Isolatable<*>>>>()
            return IsolatedMap(elements)
        }
    }
    
    
    object MapEntrySnapshotCodec : Codec<MapEntrySnapshot<Any>> {
        override suspend fun WriteContext.encode(value: MapEntrySnapshot<Any>) {
            write(value.key)
            write(value.value)
        }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Jun 07 23:09:56 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  5. platforms/core-execution/workers/src/main/java/org/gradle/workers/internal/IsolatableSerializerRegistry.java

            protected abstract T getIsolatedObject(ImmutableList<MapEntrySnapshot<Isolatable<?>>> entries);
    
            @Override
            protected void serialize(Encoder encoder, T value) throws Exception {
                List<MapEntrySnapshot<Isolatable<?>>> entrySnapshots = value.getEntries();
                encoder.writeInt(entrySnapshots.size());
                for (MapEntrySnapshot<Isolatable<?>> entrySnapshot : entrySnapshots) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Jan 26 14:58:23 UTC 2024
    - 26.9K bytes
    - Viewed (0)
  6. platforms/core-configuration/model-core/src/test/groovy/org/gradle/internal/snapshot/impl/SnapshotSerializerTest.groovy

            expect:
            original == written
        }
    
        def "serializes map properties"() {
            def builder = ImmutableList.<MapEntrySnapshot<ValueSnapshot>> builder()
            builder.add(new MapEntrySnapshot<ValueSnapshot>(string("123"), integer(123)))
            builder.add(new MapEntrySnapshot<ValueSnapshot>(string("456"), list(integer(-12), integer(12))))
            def original = new MapValueSnapshot(builder.build())
            write(original)
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Jan 11 20:22:01 UTC 2024
    - 8K bytes
    - Viewed (0)
  7. platforms/core-configuration/model-core/src/main/java/org/gradle/internal/snapshot/impl/AbstractValueProcessor.java

            }
        }
    
        private <T> T processMap(Map<?, ?> map, ValueVisitor<T> visitor) {
            ImmutableList.Builder<MapEntrySnapshot<T>> builder = ImmutableList.builderWithExpectedSize(map.size());
            for (Map.Entry<?, ?> entry : map.entrySet()) {
                builder.add(new MapEntrySnapshot<>(processValue(entry.getKey(), visitor), processValue(entry.getValue(), visitor)));
            }
            if (map instanceof Properties) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Feb 05 19:08:37 UTC 2024
    - 10K bytes
    - Viewed (0)
  8. platforms/core-configuration/model-core/src/main/java/org/gradle/internal/snapshot/impl/SnapshotSerializer.java

                case MAP_SNAPSHOT:
                    size = decoder.readSmallInt();
                    ImmutableList.Builder<MapEntrySnapshot<ValueSnapshot>> mapBuilder = ImmutableList.builderWithExpectedSize(size);
                    for (int i = 0; i < size; i++) {
                        mapBuilder.add(new MapEntrySnapshot<>(read(decoder), read(decoder)));
                    }
                    return new MapValueSnapshot(mapBuilder.build());
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Jan 11 20:22:01 UTC 2024
    - 14.1K bytes
    - Viewed (0)
  9. platforms/core-configuration/model-core/src/main/java/org/gradle/internal/snapshot/impl/IsolatedProperties.java

    import javax.annotation.Nullable;
    import java.util.Properties;
    
    public class IsolatedProperties extends AbstractIsolatedMap<Properties> {
        public IsolatedProperties(ImmutableList<MapEntrySnapshot<Isolatable<?>>> entries) {
            super(entries);
        }
    
        @Nullable
        @Override
        public Properties create() {
            return new Properties();
        }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 1.1K bytes
    - Viewed (0)
  10. platforms/core-configuration/model-core/src/main/java/org/gradle/internal/snapshot/impl/IsolatedMap.java

    import javax.annotation.Nullable;
    import java.util.LinkedHashMap;
    import java.util.Map;
    
    public class IsolatedMap extends AbstractIsolatedMap<Map<Object, Object>> {
        public IsolatedMap(ImmutableList<MapEntrySnapshot<Isolatable<?>>> entries) {
            super(entries);
        }
    
        @Nullable
        @Override
        public Map<Object, Object> create() {
            return new LinkedHashMap<>(getEntries().size());
        }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 1.1K bytes
    - Viewed (0)
Back to top