Package com.airbnb.epoxy
Enum ModelView.Size
- java.lang.Object
-
- java.lang.Enum<ModelView.Size>
-
- com.airbnb.epoxy.ModelView.Size
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<ModelView.Size>
- Enclosing class:
- ModelView
public static enum ModelView.Size extends java.lang.Enum<ModelView.Size>
Use withModelView.autoLayout()to declare what layout parameters should be used to size your view when it is added to a RecyclerView. This maps to the LayoutParams optionslayout_widthandlayout_height. If you want to set the LayoutParams manually, you can useMANUALand set the params in the View's constructor when it is initialized (a runtime exception will be thrown if layout params are not set during view instantiation when MANUAL is used).
-
-
Enum Constant Summary
Enum Constants Enum Constant Description MANUALMATCH_WIDTH_MATCH_HEIGHTMATCH_WIDTH_WRAP_HEIGHTNONEWRAP_WIDTH_MATCH_HEIGHTWRAP_WIDTH_WRAP_HEIGHT
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ModelView.SizevalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static ModelView.Size[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NONE
public static final ModelView.Size NONE
-
MANUAL
public static final ModelView.Size MANUAL
-
WRAP_WIDTH_WRAP_HEIGHT
public static final ModelView.Size WRAP_WIDTH_WRAP_HEIGHT
-
WRAP_WIDTH_MATCH_HEIGHT
public static final ModelView.Size WRAP_WIDTH_MATCH_HEIGHT
-
MATCH_WIDTH_WRAP_HEIGHT
public static final ModelView.Size MATCH_WIDTH_WRAP_HEIGHT
-
MATCH_WIDTH_MATCH_HEIGHT
public static final ModelView.Size MATCH_WIDTH_MATCH_HEIGHT
-
-
Method Detail
-
values
public static ModelView.Size[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ModelView.Size c : ModelView.Size.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ModelView.Size valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException- if this enum type has no constant with the specified namejava.lang.NullPointerException- if the argument is null
-
-