EstimateSpec@Deprecated public static class Component.MeasureSpec extends Object
A MeasureSpec encapsulates the layout requirements a child inherits from the parent. Each
MeasureSpec indicates the requirement for either the width or height as well as a mode. There are three
possible modes for MeasureSpec: UNCONSTRAINT, PRECISE, and NOT_EXCEED.
| 限定符和类型 | 字段 | 说明 |
|---|---|---|
static int |
ESTIMATED_STATE_BIT_MASK |
已过时。
|
static int |
NOT_EXCEED |
已过时。
|
static int |
PRECISE |
已过时。
|
static int |
UNCONSTRAINT |
已过时。
|
| 构造器 | 说明 |
|---|---|
MeasureSpec() |
已过时。
|
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
static int |
getMeasureSpec(int size,
int mode) |
已过时。
|
static int |
getMode(int measureSpec) |
已过时。
|
static int |
getSize(int measureSpec) |
已过时。
|
static int |
getSizeAndConfig(int size,
int estimatedConfig,
int childEstimatedConfig) |
已过时。
|
@Deprecated public static final int ESTIMATED_STATE_BIT_MASK
@Deprecated public static final int NOT_EXCEED
@Deprecated public static final int PRECISE
@Deprecated public static final int UNCONSTRAINT
@Deprecated public MeasureSpec()
@Deprecated public static int getMeasureSpec(int size, int mode)
size - Indicates the size contained in the measure specification. The value ranges from 0 to (1 shifted
left by shifting MeasureSpec.MODE_SHIFT bits), including 1.mode - Indicates the mode contained in the measure specification. The value must be
UNCONSTRAINT, PRECISE, or NOT_EXCEED.@Deprecated public static int getMode(int measureSpec)
measureSpec - Indicates the measure specification.@Deprecated public static int getSize(int measureSpec)
measureSpec - Indicates the measure specification.@Deprecated public static int getSizeAndConfig(int size, int estimatedConfig, int childEstimatedConfig)
size - The size how big the component wants to be.estimatedConfig - Constraints set by the parent.childEstimatedConfig - Size information bit mask for the component's children.