# getProperties

abstract fun getProperties(): Map<String, Any>(source)

Returns all of the registered properties and their current values as a map. The returned map is detached from the extension. That is, any changes made to the map do not change the extension from which it originated.

    project.version = "1.0"

    assert project.hasProperty("version")
    assert project.ext.properties.containsKey("version") == false

    project.ext.foo = "bar"

    assert project.ext.properties.containsKey("foo")
    assert project.ext.properties.foo == project.ext.foo

    assert project.ext.properties.every { key, value -> project.properties[key] == value }

Content copied to clipboard

#### Return

All of the registered properties and their current values as a map.