@Test public void testSetProperty() throws Exception { assertTrue(component.setProperty(Constants.Name.VISIBILITY,null)); assertTrue(component.setProperty(Constants.Name.VISIBILITY, Constants.Value.VISIBLE)); assertTrue(component.setProperty(Constants.Name.DISABLED,true)); assertTrue(component.setProperty(Constants.Name.POSITION, Constants.Value.FIXED)); assertTrue(component.setProperty(Constants.Name.BACKGROUND_COLOR, "#ffffff")); assertTrue(component.setProperty(Constants.Name.OPACITY, 0.5f)); assertTrue(component.setProperty(Constants.Name.BORDER_RADIUS,0.5f)); assertTrue(component.setProperty(Constants.Name.BORDER_RADIUS,null)); assertTrue(component.setProperty(Constants.Name.BORDER_WIDTH,null)); assertTrue(component.setProperty(Constants.Name.BORDER_WIDTH,10)); assertTrue(component.setProperty(Constants.Name.BORDER_STYLE,null)); assertTrue(component.setProperty(Constants.Name.BORDER_STYLE, "SOLID")); assertTrue(component.setProperty(Constants.Name.BORDER_COLOR,null)); assertTrue(component.setProperty(Constants.Name.BORDER_COLOR, "#ff0000")); assertTrue(component.setProperty(Constants.Name.BORDER_TOP_LEFT_RADIUS, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_TOP_RIGHT_RADIUS, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_BOTTOM_LEFT_RADIUS, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_BOTTOM_RIGHT_RADIUS, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_TOP_WIDTH, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_LEFT_WIDTH, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_BOTTOM_WIDTH, 1)); assertTrue(component.setProperty(Constants.Name.BORDER_RIGHT_WIDTH,1)); assertTrue(component.setProperty(Constants.Name.BORDER_TOP_COLOR, "#ff0000")); assertTrue(component.setProperty(Constants.Name.BORDER_BOTTOM_COLOR, "#ff0000")); assertTrue(component.setProperty(Constants.Name.BORDER_LEFT_COLOR, "#ff0000")); assertTrue(component.setProperty(Constants.Name.BORDER_RIGHT_COLOR, "#ff0000")); assertTrue(component.setProperty(Constants.Name.WIDTH, null)); assertTrue(component.setProperty(Constants.Name.MIN_WIDTH, null)); assertTrue(component.setProperty(Constants.Name.MAX_WIDTH, null)); assertTrue(component.setProperty(Constants.Name.HEIGHT, null)); assertTrue(component.setProperty(Constants.Name.MIN_HEIGHT, null)); assertTrue(component.setProperty(Constants.Name.MAX_HEIGHT, null)); assertTrue(component.setProperty(Constants.Name.ALIGN_ITEMS, null)); assertTrue(component.setProperty(Constants.Name.ALIGN_SELF, null)); assertTrue(component.setProperty(Constants.Name.FLEX, null)); assertTrue(component.setProperty(Constants.Name.FLEX_DIRECTION, null)); assertTrue(component.setProperty(Constants.Name.JUSTIFY_CONTENT, null)); assertTrue(component.setProperty(Constants.Name.FLEX_WRAP, null)); assertTrue(component.setProperty(Constants.Name.MARGIN, null)); assertTrue(component.setProperty(Constants.Name.MARGIN_TOP, null)); assertTrue(component.setProperty(Constants.Name.MARGIN_LEFT, null)); assertTrue(component.setProperty(Constants.Name.MARGIN_RIGHT, null)); assertTrue(component.setProperty(Constants.Name.MARGIN_BOTTOM, null)); assertTrue(component.setProperty(Constants.Name.PADDING, null)); assertTrue(component.setProperty(Constants.Name.PADDING_TOP, null)); assertTrue(component.setProperty(Constants.Name.PADDING_LEFT, null)); assertTrue(component.setProperty(Constants.Name.PADDING_RIGHT, null)); assertTrue(component.setProperty(Constants.Name.PADDING_BOTTOM, null)); }
protected boolean setProperty(String key, Object param) { switch (key) { case Constants.Name.DISABLED: Boolean disabled = WXUtils.getBoolean(param,null); if (disabled != null) { setDisabled(disabled); setPseudoClassStatus(Constants.PESUDO.DISABLED, disabled); } return true; case Constants.Name.POSITION: String position = WXUtils.getString(param,null); if (position != null) setSticky(position); return true; case Constants.Name.BACKGROUND_COLOR: String bgColor = WXUtils.getString(param,null); if (bgColor != null) setBackgroundColor(bgColor); return true; case Constants.Name.BACKGROUND_IMAGE: String bgImage = WXUtils.getString(param,null); if(bgImage!=null){ setBackgroundImage(bgImage); } return true; case Constants.Name.OPACITY: Float opacity = WXUtils.getFloat(param,null); if (opacity != null) setOpacity(opacity); return true; case Constants.Name.BORDER_RADIUS: case Constants.Name.BORDER_TOP_LEFT_RADIUS: case Constants.Name.BORDER_TOP_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_LEFT_RADIUS: Float radius = WXUtils.getFloat(param,null); if (radius != null) setBorderRadius(key,radius); return true; case Constants.Name.BORDER_WIDTH: case Constants.Name.BORDER_TOP_WIDTH: case Constants.Name.BORDER_RIGHT_WIDTH: case Constants.Name.BORDER_BOTTOM_WIDTH: case Constants.Name.BORDER_LEFT_WIDTH: Float width = WXUtils.getFloat(param,null); if (width != null) setBorderWidth(key,width); return true; case Constants.Name.BORDER_STYLE: case Constants.Name.BORDER_RIGHT_STYLE: case Constants.Name.BORDER_BOTTOM_STYLE: case Constants.Name.BORDER_LEFT_STYLE: case Constants.Name.BORDER_TOP_STYLE: String border_style = WXUtils.getString(param,null); if (border_style != null) setBorderStyle(key, border_style); return true; case Constants.Name.BORDER_COLOR: case Constants.Name.BORDER_TOP_COLOR: case Constants.Name.BORDER_RIGHT_COLOR: case Constants.Name.BORDER_BOTTOM_COLOR: case Constants.Name.BORDER_LEFT_COLOR: String border_color = WXUtils.getString(param,null); if (border_color != null) setBorderColor(key, border_color); return true; case Constants.Name.VISIBILITY: String visibility = WXUtils.getString(param,null); if (visibility != null) setVisibility(visibility); return true; case Constants.Name.ELEVATION: if(param!=null) { updateElevation(); } return true; case PROP_FIXED_SIZE: String fixedSize = WXUtils.getString(param, PROP_FS_MATCH_PARENT); setFixedSize(fixedSize); return true; case Constants.Name.WIDTH: case Constants.Name.MIN_WIDTH: case Constants.Name.MAX_WIDTH: case Constants.Name.HEIGHT: case Constants.Name.MIN_HEIGHT: case Constants.Name.MAX_HEIGHT: case Constants.Name.ALIGN_ITEMS: case Constants.Name.ALIGN_SELF: case Constants.Name.FLEX: case Constants.Name.FLEX_DIRECTION: case Constants.Name.JUSTIFY_CONTENT: case Constants.Name.FLEX_WRAP: case Constants.Name.MARGIN: case Constants.Name.MARGIN_TOP: case Constants.Name.MARGIN_LEFT: case Constants.Name.MARGIN_RIGHT: case Constants.Name.MARGIN_BOTTOM: case Constants.Name.PADDING: case Constants.Name.PADDING_TOP: case Constants.Name.PADDING_LEFT: case Constants.Name.PADDING_RIGHT: case Constants.Name.PADDING_BOTTOM: case Constants.Name.LEFT: case Constants.Name.TOP: case Constants.Name.RIGHT: case Constants.Name.BOTTOM: return true; default: return false; } }
WXComponent implements IWXObject, IWXActivityStateListener,OnActivePseudoListner { protected boolean setProperty(String key, Object param) { switch (key) { case Constants.Name.DISABLED: Boolean disabled = WXUtils.getBoolean(param,null); if (disabled != null) { setDisabled(disabled); setPseudoClassStatus(Constants.PESUDO.DISABLED, disabled); } return true; case Constants.Name.POSITION: String position = WXUtils.getString(param,null); if (position != null) setSticky(position); return true; case Constants.Name.BACKGROUND_COLOR: String bgColor = WXUtils.getString(param,null); if (bgColor != null) setBackgroundColor(bgColor); return true; case Constants.Name.BACKGROUND_IMAGE: String bgImage = WXUtils.getString(param,null); if(bgImage!=null){ setBackgroundImage(bgImage); } return true; case Constants.Name.OPACITY: Float opacity = WXUtils.getFloat(param,null); if (opacity != null) setOpacity(opacity); return true; case Constants.Name.BORDER_RADIUS: case Constants.Name.BORDER_TOP_LEFT_RADIUS: case Constants.Name.BORDER_TOP_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_LEFT_RADIUS: Float radius = WXUtils.getFloat(param,null); if (radius != null) setBorderRadius(key,radius); return true; case Constants.Name.BORDER_WIDTH: case Constants.Name.BORDER_TOP_WIDTH: case Constants.Name.BORDER_RIGHT_WIDTH: case Constants.Name.BORDER_BOTTOM_WIDTH: case Constants.Name.BORDER_LEFT_WIDTH: Float width = WXUtils.getFloat(param,null); if (width != null) setBorderWidth(key,width); return true; case Constants.Name.BORDER_STYLE: case Constants.Name.BORDER_RIGHT_STYLE: case Constants.Name.BORDER_BOTTOM_STYLE: case Constants.Name.BORDER_LEFT_STYLE: case Constants.Name.BORDER_TOP_STYLE: String border_style = WXUtils.getString(param,null); if (border_style != null) setBorderStyle(key, border_style); return true; case Constants.Name.BORDER_COLOR: case Constants.Name.BORDER_TOP_COLOR: case Constants.Name.BORDER_RIGHT_COLOR: case Constants.Name.BORDER_BOTTOM_COLOR: case Constants.Name.BORDER_LEFT_COLOR: String border_color = WXUtils.getString(param,null); if (border_color != null) setBorderColor(key, border_color); return true; case Constants.Name.VISIBILITY: String visibility = WXUtils.getString(param,null); if (visibility != null) setVisibility(visibility); return true; case Constants.Name.ELEVATION: if(param!=null) { updateElevation(); } return true; case PROP_FIXED_SIZE: String fixedSize = WXUtils.getString(param, PROP_FS_MATCH_PARENT); setFixedSize(fixedSize); return true; case Constants.Name.WIDTH: case Constants.Name.MIN_WIDTH: case Constants.Name.MAX_WIDTH: case Constants.Name.HEIGHT: case Constants.Name.MIN_HEIGHT: case Constants.Name.MAX_HEIGHT: case Constants.Name.ALIGN_ITEMS: case Constants.Name.ALIGN_SELF: case Constants.Name.FLEX: case Constants.Name.FLEX_DIRECTION: case Constants.Name.JUSTIFY_CONTENT: case Constants.Name.FLEX_WRAP: case Constants.Name.MARGIN: case Constants.Name.MARGIN_TOP: case Constants.Name.MARGIN_LEFT: case Constants.Name.MARGIN_RIGHT: case Constants.Name.MARGIN_BOTTOM: case Constants.Name.PADDING: case Constants.Name.PADDING_TOP: case Constants.Name.PADDING_LEFT: case Constants.Name.PADDING_RIGHT: case Constants.Name.PADDING_BOTTOM: case Constants.Name.LEFT: case Constants.Name.TOP: case Constants.Name.RIGHT: case Constants.Name.BOTTOM: return true; default: return false; } } }
WXComponent implements IWXObject, IWXActivityStateListener,OnActivePseudoListner { protected boolean setProperty(String key, Object param) { switch (key) { case Constants.Name.DISABLED: Boolean disabled = WXUtils.getBoolean(param,null); if (disabled != null) { setDisabled(disabled); setPseudoClassStatus(Constants.PESUDO.DISABLED, disabled); } return true; case Constants.Name.POSITION: String position = WXUtils.getString(param,null); if (position != null) setSticky(position); return true; case Constants.Name.BACKGROUND_COLOR: String bgColor = WXUtils.getString(param,null); if (bgColor != null) setBackgroundColor(bgColor); return true; case Constants.Name.BACKGROUND_IMAGE: String bgImage = WXUtils.getString(param,null); if(bgImage!=null){ setBackgroundImage(bgImage); } return true; case Constants.Name.OPACITY: Float opacity = WXUtils.getFloat(param,null); if (opacity != null) setOpacity(opacity); return true; case Constants.Name.BORDER_RADIUS: case Constants.Name.BORDER_TOP_LEFT_RADIUS: case Constants.Name.BORDER_TOP_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_LEFT_RADIUS: Float radius = WXUtils.getFloat(param,null); if (radius != null) setBorderRadius(key,radius); return true; case Constants.Name.BORDER_WIDTH: case Constants.Name.BORDER_TOP_WIDTH: case Constants.Name.BORDER_RIGHT_WIDTH: case Constants.Name.BORDER_BOTTOM_WIDTH: case Constants.Name.BORDER_LEFT_WIDTH: Float width = WXUtils.getFloat(param,null); if (width != null) setBorderWidth(key,width); return true; case Constants.Name.BORDER_STYLE: case Constants.Name.BORDER_RIGHT_STYLE: case Constants.Name.BORDER_BOTTOM_STYLE: case Constants.Name.BORDER_LEFT_STYLE: case Constants.Name.BORDER_TOP_STYLE: String border_style = WXUtils.getString(param,null); if (border_style != null) setBorderStyle(key, border_style); return true; case Constants.Name.BORDER_COLOR: case Constants.Name.BORDER_TOP_COLOR: case Constants.Name.BORDER_RIGHT_COLOR: case Constants.Name.BORDER_BOTTOM_COLOR: case Constants.Name.BORDER_LEFT_COLOR: String border_color = WXUtils.getString(param,null); if (border_color != null) setBorderColor(key, border_color); return true; case Constants.Name.VISIBILITY: String visibility = WXUtils.getString(param,null); if (visibility != null) setVisibility(visibility); return true; case Constants.Name.ELEVATION: if(param!=null) { updateElevation(); } return true; case PROP_FIXED_SIZE: String fixedSize = WXUtils.getString(param, PROP_FS_MATCH_PARENT); setFixedSize(fixedSize); return true; case Constants.Name.WIDTH: case Constants.Name.MIN_WIDTH: case Constants.Name.MAX_WIDTH: case Constants.Name.HEIGHT: case Constants.Name.MIN_HEIGHT: case Constants.Name.MAX_HEIGHT: case Constants.Name.ALIGN_ITEMS: case Constants.Name.ALIGN_SELF: case Constants.Name.FLEX: case Constants.Name.FLEX_DIRECTION: case Constants.Name.JUSTIFY_CONTENT: case Constants.Name.FLEX_WRAP: case Constants.Name.MARGIN: case Constants.Name.MARGIN_TOP: case Constants.Name.MARGIN_LEFT: case Constants.Name.MARGIN_RIGHT: case Constants.Name.MARGIN_BOTTOM: case Constants.Name.PADDING: case Constants.Name.PADDING_TOP: case Constants.Name.PADDING_LEFT: case Constants.Name.PADDING_RIGHT: case Constants.Name.PADDING_BOTTOM: case Constants.Name.LEFT: case Constants.Name.TOP: case Constants.Name.RIGHT: case Constants.Name.BOTTOM: return true; default: return false; } } @Deprecated  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, String instanceId, boolean isLazy); @Deprecated  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, boolean isLazy);  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent); }
WXComponent implements IWXObject, IWXActivityStateListener,OnActivePseudoListner { protected boolean setProperty(String key, Object param) { switch (key) { case Constants.Name.DISABLED: Boolean disabled = WXUtils.getBoolean(param,null); if (disabled != null) { setDisabled(disabled); setPseudoClassStatus(Constants.PESUDO.DISABLED, disabled); } return true; case Constants.Name.POSITION: String position = WXUtils.getString(param,null); if (position != null) setSticky(position); return true; case Constants.Name.BACKGROUND_COLOR: String bgColor = WXUtils.getString(param,null); if (bgColor != null) setBackgroundColor(bgColor); return true; case Constants.Name.BACKGROUND_IMAGE: String bgImage = WXUtils.getString(param,null); if(bgImage!=null){ setBackgroundImage(bgImage); } return true; case Constants.Name.OPACITY: Float opacity = WXUtils.getFloat(param,null); if (opacity != null) setOpacity(opacity); return true; case Constants.Name.BORDER_RADIUS: case Constants.Name.BORDER_TOP_LEFT_RADIUS: case Constants.Name.BORDER_TOP_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_LEFT_RADIUS: Float radius = WXUtils.getFloat(param,null); if (radius != null) setBorderRadius(key,radius); return true; case Constants.Name.BORDER_WIDTH: case Constants.Name.BORDER_TOP_WIDTH: case Constants.Name.BORDER_RIGHT_WIDTH: case Constants.Name.BORDER_BOTTOM_WIDTH: case Constants.Name.BORDER_LEFT_WIDTH: Float width = WXUtils.getFloat(param,null); if (width != null) setBorderWidth(key,width); return true; case Constants.Name.BORDER_STYLE: case Constants.Name.BORDER_RIGHT_STYLE: case Constants.Name.BORDER_BOTTOM_STYLE: case Constants.Name.BORDER_LEFT_STYLE: case Constants.Name.BORDER_TOP_STYLE: String border_style = WXUtils.getString(param,null); if (border_style != null) setBorderStyle(key, border_style); return true; case Constants.Name.BORDER_COLOR: case Constants.Name.BORDER_TOP_COLOR: case Constants.Name.BORDER_RIGHT_COLOR: case Constants.Name.BORDER_BOTTOM_COLOR: case Constants.Name.BORDER_LEFT_COLOR: String border_color = WXUtils.getString(param,null); if (border_color != null) setBorderColor(key, border_color); return true; case Constants.Name.VISIBILITY: String visibility = WXUtils.getString(param,null); if (visibility != null) setVisibility(visibility); return true; case Constants.Name.ELEVATION: if(param!=null) { updateElevation(); } return true; case PROP_FIXED_SIZE: String fixedSize = WXUtils.getString(param, PROP_FS_MATCH_PARENT); setFixedSize(fixedSize); return true; case Constants.Name.WIDTH: case Constants.Name.MIN_WIDTH: case Constants.Name.MAX_WIDTH: case Constants.Name.HEIGHT: case Constants.Name.MIN_HEIGHT: case Constants.Name.MAX_HEIGHT: case Constants.Name.ALIGN_ITEMS: case Constants.Name.ALIGN_SELF: case Constants.Name.FLEX: case Constants.Name.FLEX_DIRECTION: case Constants.Name.JUSTIFY_CONTENT: case Constants.Name.FLEX_WRAP: case Constants.Name.MARGIN: case Constants.Name.MARGIN_TOP: case Constants.Name.MARGIN_LEFT: case Constants.Name.MARGIN_RIGHT: case Constants.Name.MARGIN_BOTTOM: case Constants.Name.PADDING: case Constants.Name.PADDING_TOP: case Constants.Name.PADDING_LEFT: case Constants.Name.PADDING_RIGHT: case Constants.Name.PADDING_BOTTOM: case Constants.Name.LEFT: case Constants.Name.TOP: case Constants.Name.RIGHT: case Constants.Name.BOTTOM: return true; default: return false; } } @Deprecated  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, String instanceId, boolean isLazy); @Deprecated  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, boolean isLazy);  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent); void postAnimation(WXAnimationModule.AnimationHolder holder); String getInstanceId(); Rect getComponentSize(); final void invoke(String method, JSONArray args); void bindHolder(IFComponentHolder holder); WXSDKInstance getInstance(); Context getContext(); final void fireEvent(String type); final void fireEvent(String type, Map<String, Object> params); boolean isLazy(); void applyLayoutAndEvent(WXComponent component); void bindData(WXComponent component); void refreshData(WXComponent component); final void setLayout(ImmutableDomObject domObject); int getLayoutTopOffsetForSibling(); void setPadding(Spacing padding, Spacing border); void updateExtra(Object extra); ImmutableDomObject getDomObject(); void updateProperties(Map<String, Object> props); void addEvent(String type); View getRealView(); Scrollable getParentScroller(); WXVContainer getParent(); String getRef(); final void createView(); T getHostView(); @Deprecated View getView(); int getAbsoluteY(); int getAbsoluteX(); void updateDom(WXDomObject dom); final void removeEvent(String type); final void removeAllEvent(); final void removeStickyStyle(); boolean isSticky(); void setDisabled(boolean disabled); void setSticky(String sticky); void setBackgroundColor(String color); void setBackgroundImage(String bgImage); void setOpacity(float opacity); void setBorderRadius(String key, float borderRadius); void setBorderWidth(String key, float borderWidth); void setBorderStyle(String key, String borderStyle); void setBorderColor(String key, String borderColor); @Nullable String getVisibility(); void setVisibility(String visibility); @Deprecated void registerActivityStateListener(); void onActivityCreate(); void onActivityStart(); void onActivityPause(); void onActivityResume(); void onActivityStop(); void onActivityDestroy(); boolean onActivityBack(); void onActivityResult(int requestCode, int resultCode, Intent data); boolean onCreateOptionsMenu(Menu menu); void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults); void destroy(); View detachViewAndClearPreInfo(); void computeVisiblePointInViewCoordinate(PointF pointF); boolean containsGesture(WXGestureType WXGestureType); void notifyAppearStateChange(String wxEventType,String direction); boolean isUsing(); void setUsing(boolean using); void readyToRender(); boolean isVirtualComponent(); void removeVirtualComponent(); boolean hasScrollParent(WXComponent component); @Override void updateActivePseudo(boolean isSet); }
WXComponent implements IWXObject, IWXActivityStateListener,OnActivePseudoListner { protected boolean setProperty(String key, Object param) { switch (key) { case Constants.Name.DISABLED: Boolean disabled = WXUtils.getBoolean(param,null); if (disabled != null) { setDisabled(disabled); setPseudoClassStatus(Constants.PESUDO.DISABLED, disabled); } return true; case Constants.Name.POSITION: String position = WXUtils.getString(param,null); if (position != null) setSticky(position); return true; case Constants.Name.BACKGROUND_COLOR: String bgColor = WXUtils.getString(param,null); if (bgColor != null) setBackgroundColor(bgColor); return true; case Constants.Name.BACKGROUND_IMAGE: String bgImage = WXUtils.getString(param,null); if(bgImage!=null){ setBackgroundImage(bgImage); } return true; case Constants.Name.OPACITY: Float opacity = WXUtils.getFloat(param,null); if (opacity != null) setOpacity(opacity); return true; case Constants.Name.BORDER_RADIUS: case Constants.Name.BORDER_TOP_LEFT_RADIUS: case Constants.Name.BORDER_TOP_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_RIGHT_RADIUS: case Constants.Name.BORDER_BOTTOM_LEFT_RADIUS: Float radius = WXUtils.getFloat(param,null); if (radius != null) setBorderRadius(key,radius); return true; case Constants.Name.BORDER_WIDTH: case Constants.Name.BORDER_TOP_WIDTH: case Constants.Name.BORDER_RIGHT_WIDTH: case Constants.Name.BORDER_BOTTOM_WIDTH: case Constants.Name.BORDER_LEFT_WIDTH: Float width = WXUtils.getFloat(param,null); if (width != null) setBorderWidth(key,width); return true; case Constants.Name.BORDER_STYLE: case Constants.Name.BORDER_RIGHT_STYLE: case Constants.Name.BORDER_BOTTOM_STYLE: case Constants.Name.BORDER_LEFT_STYLE: case Constants.Name.BORDER_TOP_STYLE: String border_style = WXUtils.getString(param,null); if (border_style != null) setBorderStyle(key, border_style); return true; case Constants.Name.BORDER_COLOR: case Constants.Name.BORDER_TOP_COLOR: case Constants.Name.BORDER_RIGHT_COLOR: case Constants.Name.BORDER_BOTTOM_COLOR: case Constants.Name.BORDER_LEFT_COLOR: String border_color = WXUtils.getString(param,null); if (border_color != null) setBorderColor(key, border_color); return true; case Constants.Name.VISIBILITY: String visibility = WXUtils.getString(param,null); if (visibility != null) setVisibility(visibility); return true; case Constants.Name.ELEVATION: if(param!=null) { updateElevation(); } return true; case PROP_FIXED_SIZE: String fixedSize = WXUtils.getString(param, PROP_FS_MATCH_PARENT); setFixedSize(fixedSize); return true; case Constants.Name.WIDTH: case Constants.Name.MIN_WIDTH: case Constants.Name.MAX_WIDTH: case Constants.Name.HEIGHT: case Constants.Name.MIN_HEIGHT: case Constants.Name.MAX_HEIGHT: case Constants.Name.ALIGN_ITEMS: case Constants.Name.ALIGN_SELF: case Constants.Name.FLEX: case Constants.Name.FLEX_DIRECTION: case Constants.Name.JUSTIFY_CONTENT: case Constants.Name.FLEX_WRAP: case Constants.Name.MARGIN: case Constants.Name.MARGIN_TOP: case Constants.Name.MARGIN_LEFT: case Constants.Name.MARGIN_RIGHT: case Constants.Name.MARGIN_BOTTOM: case Constants.Name.PADDING: case Constants.Name.PADDING_TOP: case Constants.Name.PADDING_LEFT: case Constants.Name.PADDING_RIGHT: case Constants.Name.PADDING_BOTTOM: case Constants.Name.LEFT: case Constants.Name.TOP: case Constants.Name.RIGHT: case Constants.Name.BOTTOM: return true; default: return false; } } @Deprecated  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, String instanceId, boolean isLazy); @Deprecated  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, boolean isLazy);  WXComponent(WXSDKInstance instance, WXDomObject dom, WXVContainer parent); void postAnimation(WXAnimationModule.AnimationHolder holder); String getInstanceId(); Rect getComponentSize(); final void invoke(String method, JSONArray args); void bindHolder(IFComponentHolder holder); WXSDKInstance getInstance(); Context getContext(); final void fireEvent(String type); final void fireEvent(String type, Map<String, Object> params); boolean isLazy(); void applyLayoutAndEvent(WXComponent component); void bindData(WXComponent component); void refreshData(WXComponent component); final void setLayout(ImmutableDomObject domObject); int getLayoutTopOffsetForSibling(); void setPadding(Spacing padding, Spacing border); void updateExtra(Object extra); ImmutableDomObject getDomObject(); void updateProperties(Map<String, Object> props); void addEvent(String type); View getRealView(); Scrollable getParentScroller(); WXVContainer getParent(); String getRef(); final void createView(); T getHostView(); @Deprecated View getView(); int getAbsoluteY(); int getAbsoluteX(); void updateDom(WXDomObject dom); final void removeEvent(String type); final void removeAllEvent(); final void removeStickyStyle(); boolean isSticky(); void setDisabled(boolean disabled); void setSticky(String sticky); void setBackgroundColor(String color); void setBackgroundImage(String bgImage); void setOpacity(float opacity); void setBorderRadius(String key, float borderRadius); void setBorderWidth(String key, float borderWidth); void setBorderStyle(String key, String borderStyle); void setBorderColor(String key, String borderColor); @Nullable String getVisibility(); void setVisibility(String visibility); @Deprecated void registerActivityStateListener(); void onActivityCreate(); void onActivityStart(); void onActivityPause(); void onActivityResume(); void onActivityStop(); void onActivityDestroy(); boolean onActivityBack(); void onActivityResult(int requestCode, int resultCode, Intent data); boolean onCreateOptionsMenu(Menu menu); void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults); void destroy(); View detachViewAndClearPreInfo(); void computeVisiblePointInViewCoordinate(PointF pointF); boolean containsGesture(WXGestureType WXGestureType); void notifyAppearStateChange(String wxEventType,String direction); boolean isUsing(); void setUsing(boolean using); void readyToRender(); boolean isVirtualComponent(); void removeVirtualComponent(); boolean hasScrollParent(WXComponent component); @Override void updateActivePseudo(boolean isSet); static final String PROP_FIXED_SIZE; static final String PROP_FS_MATCH_PARENT; static final String PROP_FS_WRAP_CONTENT; static int mComponentNum; }