-
public class CoordinatorLayout.LayoutParams extends ViewGroup.MarginLayoutParams
Parameters describing the desired layout for a child of a CoordinatorLayout.
-
-
Field Summary
Fields Modifier and Type Field Description public intgravitypublic intanchorGravitypublic intkeylinepublic intinsetEdgepublic intdodgeInsetEdges
-
Constructor Summary
Constructors Constructor Description CoordinatorLayout.LayoutParams(int width, int height)CoordinatorLayout.LayoutParams(CoordinatorLayout.LayoutParams p)CoordinatorLayout.LayoutParams(ViewGroup.MarginLayoutParams p)CoordinatorLayout.LayoutParams(ViewGroup.LayoutParams p)
-
Method Summary
Modifier and Type Method Description intgetAnchorId()Get the id of this view's anchor. voidsetAnchorId(@IdRes() int id)Set the id of this view's anchor. CoordinatorLayout.BehaviorgetBehavior()Get the behavior governing the layout and interaction of the child view within a parentCoordinatorLayout. voidsetBehavior(@Nullable() CoordinatorLayout.Behavior behavior)Set the behavior governing the layout and interaction of the child view within a parentCoordinatorLayout. -
Methods inherited from class android.view.ViewGroup.MarginLayoutParams
getLayoutDirection, getMarginEnd, getMarginStart, isMarginRelative, resolveLayoutDirection, setLayoutDirection, setMarginEnd, setMarginStart, setMargins -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
CoordinatorLayout.LayoutParams
CoordinatorLayout.LayoutParams(int width, int height)
-
CoordinatorLayout.LayoutParams
CoordinatorLayout.LayoutParams(CoordinatorLayout.LayoutParams p)
-
CoordinatorLayout.LayoutParams
CoordinatorLayout.LayoutParams(ViewGroup.MarginLayoutParams p)
-
CoordinatorLayout.LayoutParams
CoordinatorLayout.LayoutParams(ViewGroup.LayoutParams p)
-
-
Method Detail
-
getAnchorId
@IdRes() int getAnchorId()
Get the id of this view's anchor.
-
setAnchorId
void setAnchorId(@IdRes() int id)
Set the id of this view's anchor.
The view with this id must be a descendant of the CoordinatorLayout containingthe child view this LayoutParams belongs to. It may not be the child view with thisLayoutParams or a descendant of it.
-
getBehavior
@Nullable() CoordinatorLayout.Behavior getBehavior()
Get the behavior governing the layout and interaction of the child view within a parentCoordinatorLayout.
-
setBehavior
void setBehavior(@Nullable() CoordinatorLayout.Behavior behavior)
Set the behavior governing the layout and interaction of the child view within a parentCoordinatorLayout.
Setting a new behavior will remove any currently associated Behavior tag.
- Parameters:
behavior- The behavior to set or null for no special behavior
-
-
-
-