WXSlider extends WXVContainer<FrameLayout> { @Override protected boolean setProperty(String key, Object param) { switch (key) { case Constants.Name.VALUE: String value = WXUtils.getString(param, null); if (value != null) { setValue(value); } return true; case Constants.Name.AUTO_PLAY: String aotu_play = WXUtils.getString(param, null); if (aotu_play != null) { setAutoPlay(aotu_play); } return true; case Constants.Name.SHOW_INDICATORS: String indicators = WXUtils.getString(param, null); if (indicators != null) { setShowIndicators(indicators); } return true; case Constants.Name.INTERVAL: Integer interval = WXUtils.getInteger(param, null); if (interval != null) { setInterval(interval); } return true; case Constants.Name.INDEX: Integer index = WXUtils.getInteger(param, null); if (index != null) { setIndex(index); } return true; } return super.setProperty(key, param); } @Deprecated  WXSlider(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, String instanceId, boolean isLazy);  WXSlider(WXSDKInstance instance, WXDomObject node, WXVContainer parent, boolean lazy); @Override void addEvent(String type); @Override ViewGroup getRealView(); @Override void remove(WXComponent child); @Override void remove(WXComponent child, boolean destroy); @Override void destroy(); @Override void onActivityResume(); @Override void onActivityStop(); void addIndicator(WXIndicator indicator); @Deprecated @WXComponentProp(name = Constants.Name.VALUE) void setValue(String value); @WXComponentProp(name = Constants.Name.AUTO_PLAY) void setAutoPlay(String autoPlay); @WXComponentProp(name = Constants.Name.SHOW_INDICATORS) void setShowIndicators(String show); @WXComponentProp(name = Constants.Name.INTERVAL) void setInterval(int intervalMS); @WXComponentProp(name = Constants.Name.INDEX) void setIndex(int index);  }
@Test public void testSetProperties() throws Exception { ComponentTest.setProperty(component,PROPS,VALUES); }
@Test public void testIndicator() throws Exception { WXIndicator indicator = createIndicator(); indicator.mParent = component; ComponentTest.create(indicator); component.addChild(indicator); ComponentTest.setProperty(indicator,IPROPS,IVALUES); }