Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for readOnlyProperty (0.22 sec)

  1. analysis/analysis-api-fe10/src/org/jetbrains/kotlin/analysis/api/descriptors/utils/ValidityAwareCachedValue.kt

    import org.jetbrains.kotlin.analysis.api.lifetime.assertIsValidAndAccessible
    import kotlin.properties.ReadOnlyProperty
    import kotlin.reflect.KProperty
    
    /**
     * Lazy value that guaranties safe publication and checks validity on every access
     */
    internal class ValidityAwareCachedValue<T>(
        private val token: KaLifetimeToken,
        init: () -> T
    ) : ReadOnlyProperty<Any, T> {
        private val lazyValue = lazy(LazyThreadSafetyMode.PUBLICATION, init)
    
    Registered: Wed Jun 12 09:53:16 UTC 2024
    - Last Modified: Wed May 22 06:28:34 UTC 2024
    - 1.1K bytes
    - Viewed (0)
  2. analysis/analysis-api-fir/src/org/jetbrains/kotlin/analysis/api/fir/utils/ValidityAwareCachedValue.kt

    import org.jetbrains.kotlin.analysis.api.lifetime.withValidityAssertion
    import kotlin.properties.ReadOnlyProperty
    import kotlin.reflect.KProperty
    
    /**
     * Lazy value that guaranties safe publication and checks validity on every access
     */
    @JvmInline
    internal value class ValidityAwareCachedValue<T>(
        private val lazyValue: Lazy<T>,
    ) : ReadOnlyProperty<KaLifetimeOwner, T> {
    Registered: Wed Jun 12 09:53:16 UTC 2024
    - Last Modified: Wed May 22 06:28:34 UTC 2024
    - 1.1K bytes
    - Viewed (0)
  3. analysis/analysis-api/src/org/jetbrains/kotlin/analysis/api/lifetime/KaLifetimeOwnerField.kt

    import kotlin.properties.ReadOnlyProperty
    import kotlin.reflect.KProperty
    
    /**
     * Represents a value with validity assertions.
     *
     * To create an instance of [KaLifetimeOwnerField] use the [validityAsserted] function.
     *
     * @see KaLifetimeOwner
     * @see validityAsserted
     */
    @JvmInline
    public value class KaLifetimeOwnerField<T>(public val value: T) : ReadOnlyProperty<KaLifetimeOwner, T> {
    Registered: Wed Jun 12 09:53:16 UTC 2024
    - Last Modified: Wed May 22 06:28:34 UTC 2024
    - 870 bytes
    - Viewed (0)
  4. platforms/core-configuration/model-core/src/test/groovy/org/gradle/internal/extensibility/ExtensibleDynamicObjectTest.java

            Bean bean = new Bean();
            bean.doSetReadOnlyProperty("value");
    
            assertThat(bean.getProperty("readOnlyProperty"), equalTo((Object) "value"));
        }
    
        @Test
        public void cannotSetReadOnlyClassProperty() {
            Bean bean = new Bean();
    
            try {
                bean.setProperty("readOnlyProperty", "value");
                fail();
            } catch (GroovyRuntimeException e) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 33.7K bytes
    - Viewed (0)
  5. platforms/core-configuration/model-core/src/test/groovy/org/gradle/internal/extensibility/ExtensibleDynamicObjectTestHelper.groovy

            bean.readWriteProperty = 'value'
            assertEquals(bean.readWriteProperty, 'value')
    
            bean.doSetReadOnlyProperty('value')
            assertEquals(bean.readOnlyProperty, 'value')
    
            bean.defineProperty('additional', 'value')
            assertEquals(bean.additional, 'value')
        }
        
        public static void assertCanGetAndSetProperties (ExtensibleDynamicObjectTest.Bean bean) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  6. build-logic/documentation/src/test/groovy/gradlebuild/docs/dsl/docbook/ClassDocRendererTest.groovy

            PropertyDoc readOnlyProperty = propertyDoc('readOnlyProperty', readable: true, writeable: false)
            PropertyDoc writeOnlyProperty = propertyDoc('writeOnlyProperty', readable: false, writeable: true)
            _ * classDoc.classProperties >> [readWriteProperty, readOnlyProperty, writeOnlyProperty]
            _ * classDoc.classMethods >> []
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Dec 09 08:14:05 UTC 2020
    - 40.8K bytes
    - Viewed (0)
  7. platforms/core-configuration/model-core/src/test/groovy/org/gradle/model/internal/manage/schema/extract/DefaultModelSchemaExtractorTest.groovy

            then:
            properties*.name == ["value"]
        }
    
        @Managed
        static interface ReadOnlyProperty {
            SingleStringValueProperty getSingleStringValueProperty()
        }
    
        @Managed
        static interface WritableProperty extends ReadOnlyProperty {
            void setSingleStringValueProperty(SingleStringValueProperty value)
        }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 29.9K bytes
    - Viewed (0)
Back to top