Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for disallowChanges (0.25 sec)

  1. platforms/core-configuration/model-core/src/main/java/org/gradle/api/internal/provider/ValueState.java

            public void beforeMutate(Describable displayName) {
                if (disallowChanges) {
                    throw new IllegalStateException(String.format("The value for %s cannot be changed any further.", displayName.getDisplayName()));
                }
            }
    
            @Override
            public void disallowChanges() {
                disallowChanges = true;
            }
    
            @Override
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri May 17 11:41:55 UTC 2024
    - 13.7K bytes
    - Viewed (0)
  2. platforms/core-configuration/model-core/src/main/java/org/gradle/api/internal/provider/AbstractProperty.java

                    finalizeNow(context, ValueConsumer.IgnoreUnsafeRead);
                }
            }
        }
    
        @Override
        public void disallowChanges() {
            state.disallowChanges();
        }
    
        @Override
        public void finalizeValueOnRead() {
            state.finalizeOnNextGet();
        }
    
        @Override
        public void implicitFinalizeValue() {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri May 17 11:41:54 UTC 2024
    - 15.8K bytes
    - Viewed (0)
  3. platforms/core-configuration/file-collections/src/main/java/org/gradle/api/internal/file/collections/DefaultConfigurableFileCollection.java

            valueState = valueState.finalState();
        }
    
        public boolean isFinalizing() {
            return valueState.isFinalizing();
        }
    
        @Override
        public void disallowChanges() {
            valueState.disallowChanges();
        }
    
        @Override
        public void finalizeValueOnRead() {
            valueState.finalizeOnNextGet();
        }
    
        @Override
        public void implicitFinalizeValue() {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu May 23 16:06:55 UTC 2024
    - 30.2K bytes
    - Viewed (0)
  4. platforms/core-configuration/file-collections/src/integTest/groovy/org/gradle/api/file/FileCollectionLifecycleIntegrationTest.groovy

                def files = objects.fileCollection()
                def name = 'other'
                files.from { name }
    
                def names = ['b', 'c']
                files.from(names)
    
                files.disallowChanges()
                name = 'a'
                names.clear()
    
                assert files.files as List == [file('a')]
    
                files.from('broken')
            """
    
            when:
            fails('broken')
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Nov 27 10:55:07 UTC 2023
    - 11.4K bytes
    - Viewed (0)
  5. platforms/core-configuration/model-core/src/integTest/groovy/org/gradle/api/provider/CollectionPropertyIntegrationTest.groovy

    def provider = providers.provider { [++counter, ++counter] }
    
    def property = objects.listProperty(Integer)
    property.set(provider)
    
    assert property.get() == [1, 2]
    assert property.get() == [3, 4]
    property.disallowChanges()
    assert property.get() == [5, 6]
    assert property.get() == [7, 8]
    
    property.set([1])
    """
    
            when:
            fails()
    
            then:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Jan 12 19:57:00 UTC 2024
    - 15K bytes
    - Viewed (0)
  6. platforms/core-configuration/model-core/src/integTest/groovy/org/gradle/api/provider/PropertyLifecycleIntegrationTest.groovy

                def property = objects.property(Integer)
                property.set(provider)
    
                assert property.get() == 1
                assert property.get() == 2
                property.disallowChanges()
                assert property.get() == 3
                assert property.get() == 4
    
                property.set(12)
            """
    
            when:
            fails()
    
            then:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Jan 04 14:00:52 UTC 2024
    - 15K bytes
    - Viewed (0)
  7. platforms/core-configuration/model-core/src/integTest/groovy/org/gradle/api/provider/MapPropertyIntegrationTest.groovy

                def property = objects.mapProperty(Integer, Integer)
                property.set(provider)
    
                assert property.get() == [1: 2]
                assert property.get() == [3: 4]
                property.disallowChanges()
                assert property.get() == [5: 6]
                assert property.get() == [7: 8]
    
                property.set([1: 2])
                '''.stripIndent()
    
            when:
            fails()
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Jan 04 15:28:53 UTC 2024
    - 24.5K bytes
    - Viewed (0)
Back to top