Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 13 of 13 for myExtension (0.12 sec)

  1. subprojects/core/src/integTest/groovy/org/gradle/api/ObjectExtensionInstantiationIntegrationTest.groovy

        @NotYetImplemented
        def "extension can be created on task"() {
            buildFile """
                interface MyExtension {
                    Property<String> getProp()
                }
    
                tasks.register("mytask") {
                    extensions.create("myext", MyExtension)
                    myext.prop = "foobar"
                    doLast {
                        println("myext.prop = " + myext.prop.get())
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Nov 04 22:26:51 UTC 2021
    - 16.9K bytes
    - Viewed (0)
  2. platforms/core-configuration/configuration-cache/src/integTest/groovy/org/gradle/internal/cc/impl/isolated/IsolatedProjectsToolingApiModelQueryIntegrationTest.groovy

            model2.message == "It works from project :"
    
            and:
            fixture.assertStateLoaded()
            outputDoesNotContain("creating model")
    
            when:
            buildFile << """
                myExtension.message = 'this is the root project'
            """
    
            executer.withArguments(ENABLE_CLI)
            def model3 = fetchModel()
    
            then:
            model3.message == "this is the root project"
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Sat Jun 08 11:29:25 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  3. platforms/documentation/docs/src/docs/userguide/authoring-builds/plugins/implementing_gradle_plugins_binary.adoc

    include::sample[dir="snippets/plugins/mappingExtensions/groovy",files="app/build.gradle[tags=snippet]"]
    ====
    
    In this example, the `MyExtension` class defines an `inputParameter` property that can be set in the build script.
    The `MyPlugin` class configures this extension and uses its `inputParameter` value to configure the `MyCustomTask` task.
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Apr 29 02:31:44 UTC 2024
    - 37.7K bytes
    - Viewed (0)
Back to top