Register now for Android Dev Summit 2019!

Shapeable

public interface Shapeable

com.google.android.material.shape.Shapeable
Known Indirect Subclasses


Provides a mechanism to uniformly modify the ShapeAppearanceModel that backs a MaterialShapeDrawable. Components that support custom shapes via MaterialShapeDrawable should implement this interface.

Summary

Public methods

abstract ShapeAppearanceModel getShapeAppearanceModel()

Returns the ShapeAppearanceModel used for the components's MaterialShapeDrawable's shape definition.

abstract void setShapeAppearanceModel(ShapeAppearanceModel shapeAppearanceModel)

Sets the ShapeAppearanceModel that defines the component's MaterialShapeDrawable's shape using shapeAppearanceModel.

Public methods

getShapeAppearanceModel

ShapeAppearanceModel getShapeAppearanceModel ()

Returns the ShapeAppearanceModel used for the components's MaterialShapeDrawable's shape definition.

This ShapeAppearanceModel can be modified to change the component's shape.

Returns
ShapeAppearanceModel

setShapeAppearanceModel

void setShapeAppearanceModel (ShapeAppearanceModel shapeAppearanceModel)

Sets the ShapeAppearanceModel that defines the component's MaterialShapeDrawable's shape using shapeAppearanceModel.

Parameters
shapeAppearanceModel ShapeAppearanceModel