| Package | com.iwobanas.controls |
| Class | public class MDataGrid |
| Inheritance | MDataGrid mx.controls.DataGrid |
| Implements | ISearchable |
| Property | Defined by | ||
|---|---|---|---|
| copyDataProvider : Boolean = true
Flag indicating if data provider should be copied.
| MDataGrid | ||
| found : Boolean [read-only]
Flag indicating if last search ended successfully
true or not false. | MDataGrid | ||
| originalCollection : ICollectionView
If
copyDataProvider is set this variable will store
original data provider converted to ICollectionView if needed while
dataProvider will store a copy of data provider. | MDataGrid | ||
| searchExpression : RegExp [read-only]
String wildcard converted to the regular expression (RegExp).
| MDataGrid | ||
| searchString : String [read-only]
String wildcard used in last search.
| MDataGrid | ||
| Method | Defined by | ||
|---|---|---|---|
|
find(wildcard:String, caseInsensitive:Boolean = true):Boolean
Find item matching given wildcard and assign first match to selectedItem.
| MDataGrid | ||
|
findNext():Boolean
Find next match using parameters specified in last call to
found() function. | MDataGrid | ||
|
findPrevious():Boolean
Find previous match using parameters specified in last call to
found() function. | MDataGrid | ||
|
invalidateColumnFilters():void
Mark datagrid so that data provider will be refreshed
(new filters values will take effect) on next call commitProperties().
| MDataGrid | ||
| Event | Summary | Defined by | ||
|---|---|---|---|---|
Dispatched when the originalCollection property changes. | MDataGrid | |||
| copyDataProvider | property |
public var copyDataProvider:Boolean = true
Flag indicating if data provider should be copied.
If true shallow copy of data provider is created
and filters applied to data provider doesn't affect data provider.
If false filters are applied to original data provider.
NOTE: Changing this value when dataProvider is set
will take effect after next call to dataProvider setter.
| found | property |
found:Boolean [read-only]
Flag indicating if last search ended successfully true or not false.
This property can be used as the source for data binding.
Implementation public function get found():Boolean
| originalCollection | property |
public var originalCollection:ICollectionView
If copyDataProvider is set this variable will store
original data provider converted to ICollectionView if needed while
dataProvider will store a copy of data provider.
If copyDataProvider is false this will equal
to dataProvider.
This property can be used as the source for data binding.
| searchExpression | property |
searchExpression:RegExp [read-only]String wildcard converted to the regular expression (RegExp).
This property can be used as the source for data binding.
Implementation public function get searchExpression():RegExp
| searchString | property |
searchString:String [read-only]String wildcard used in last search.
This should equal to the string passed to the find() function.
This property can be used as the source for data binding.
Implementation public function get searchString():String
| find | () | method |
public function find(wildcard:String, caseInsensitive:Boolean = true):BooleanFind item matching given wildcard and assign first match to selectedItem.
Unlike standard findSting() function this functions searches labels of all visible columns.
It also supports wildcards containing "?" or " characters
interpreted as any character or any character sequence respectively.
The search starts at selectedIndex location and if match is find stops immediately.
If it reaches the end of the data provider it starts over from the beginning.
If you need to navigate between matches user findNext() / findPrevious() functions.
wildcard:String — text to search for
|
|
caseInsensitive:Boolean (default = true) — flag indicating whether search should be case insensitive
|
Boolean — true if text was fond or false if not
|
See also
| findNext | () | method |
public function findNext():Boolean
Find next match using parameters specified in last call to found() function.
Boolean |
| findPrevious | () | method |
public function findPrevious():Boolean
Find previous match using parameters specified in last call to found() function.
Boolean |
| invalidateColumnFilters | () | method |
public function invalidateColumnFilters():void
Mark datagrid so that data provider will be refreshed
(new filters values will take effect) on next call commitProperties().
This function may eventually be called by "filteChange"
and "filterValueChange" event handlers but for now
it is directly called by ColumnFilterBase.
| originalCollectionChange | event |
com.iwobanas.controls.dataGridClasses.MDataGridEvent
Dispatched when the originalCollection property changes.