PDA

View Full Version : Ext.Direct Component Communication



gurufaction
5 Jun 2009, 7:27 AM
I am trying to understand Ext.Direct and how it integrates with components. I notice some components require directFn, others api, and some could be either.

Ext.Direct => Ext.tree.TreePanel.directFn
Ext.Direct => Ext.form.FormPanel.api
Ext.Direct => Ext.data.DirectStore.api/directFn => Ext.grid.GridPanel

Which components require DirectStore? Is it only GridPanel?
Which components support api? directFn? both?

Thanks
Michael

aconran
5 Jun 2009, 10:20 AM
directFn is used when there is only one action such as in Tree, you can only load a tree.

api is used when there are multiple actions such as in a Form or Store. You can load or submit a Form and you can read, create, update and destroy on an Ext.data.Store.

DirectStore is just a convenience class of an Ext.data.Store that uses a DirectProxy to communicate with the server. There are several classes which bind to a store such as Grid, DataView and ComboBox. DirectStore is just a special type of Store and supports binding to any of these Components.