void (@LayoutPolicy int layoutPolicy) { if (layoutPolicy != NOWRAP_LAYOUT_POLICY && layoutPolicy != WRAP_LAYOUT_POLICY && layoutPolicy != AUTO_LAYOUT_POLICY) { throw new IllegalArgumentException("wrong layoutPolicy: " + layoutPolicy); } myLayoutPolicy = layoutPolicy; }