protected void initDriver(){ this.driver = new ECPWebDriver(); button = new ButtonCtl(this.driver); combo = new ComboBoxCtl(this.driver); common = new CommonCtl(this.driver); dialog = new Dialo-gCtl(this.driver); menu = new DropDownMenuCtl(this.driver); grid = new GridCtl(this.driver); pop = new PopCtl(this.driver); qzzGrid = new QzzGridCtl(this.driver); spinner = new SpinnerCtl(this.driver); tab = new TabCtl(this.driver); tree = new TreeCtl(this.driver); radio = new RadioCtl(this.driver); check = new CheckBoxCtl(this.driver); card = new CardCtl(this.driver); date = new DateCtl(this.driver); gldx = new GldxCtl(this.driver); attach = new AttachmentCtl(this.driver); quarter = new QuarterCtl(this.driver); file = new FileCtl(); condition = new ConditionCtl(this.driver); processComponents = new ProcessComponents(this.driver); newUIComponents = new NewUIComponents(this.driver); handles.clear(); }
时间: 2024-04-12 11:32:44 浏览: 150
Java的JDBC数据库连接池实现方法.doc
这段代码是一个名为 'initDriver' 的方法,它用于初始化驱动程序和各种控件。在这个方法中,首先创建了一个 ECPWebDriver 实例,并将其赋值给成员变量 driver。然后,依次创建了 ButtonCtl、ComboBoxCtl、CommonCtl、DialogCtl、DropDownMenuCtl、GridCtl、PopCtl、QzzGridCtl、SpinnerCtl、TabCtl、TreeCtl、RadioCtl、CheckBoxCtl、CardCtl、DateCtl、GldxCtl、AttachmentCtl、QuarterCtl、FileCtl、ConditionCtl、ProcessComponents 和 NewUIComponents 的实例,并将它们赋值给相应的成员变量。最后,清空了 handles 列表。
这段代码的作用是为后续的测试或应用程序提供各种控件的实例,并且通过驱动程序实现对这些控件的操作。
阅读全文