# DimensionBuilders.ExpandedDimensionProp

Artifact: [androidx.wear.protolayout:protolayout](https://developer.android.com/jetpack/androidx/releases/wear-protolayout) [View Source](https://cs.android.com/search?q=file:androidx/wear/protolayout/DimensionBuilders.java+class:androidx.wear.protolayout.DimensionBuilders.ExpandedDimensionProp) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.0.0)

*** ** * ** ***


```
@RequiresSchemaVersion(major = 1, minor = 0)
public final class DimensionBuilders.ExpandedDimensionProp implements DimensionBuilders.ContainerDimension, DimensionBuilders.ImageDimension, DimensionBuilders.SpacerDimension
```

<br />

*** ** * ** ***

A type for a dimension that fills all the space it can (i.e. MATCH_PARENT in Android parlance).

## Summary

| ### Nested types |
|---|
| `public final class https://developer.android.com/reference/androidx/wear/protolayout/DimensionBuilders.ExpandedDimensionProp.Builder` Builder for `https://developer.android.com/reference/androidx/wear/protolayout/DimensionBuilders.ExpandedDimensionProp`. |

| ### Public methods |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/wear/protolayout/TypeBuilders.FloatProp` | `https://developer.android.com/reference/androidx/wear/protolayout/DimensionBuilders.ExpandedDimensionProp#getLayoutWeight()()` Gets the layout weight (a dimensionless scalar value) for this element. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/wear/protolayout/DimensionBuilders.ExpandedDimensionProp#toString()()` |

## Public methods

### getLayoutWeight

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.0.0)

```
public @Nullable TypeBuilders.FloatProp getLayoutWeight()
```

Gets the layout weight (a dimensionless scalar value) for this element. This will only affect the width of children of a `https://developer.android.com/reference/androidx/wear/protolayout/LayoutElementBuilders.Row` or the height of children of a `https://developer.android.com/reference/androidx/wear/protolayout/LayoutElementBuilders.Column`. By default, all children have equal weight. Where applicable, the width or height of the element is proportional to the sum of the weights of its siblings.

Note that negative values are not supported and it can lead to unexpected behaviour.

### toString

```
public @NonNull String toString()
```