wxPg::Row_binding Class Reference

Binding widgets to display values from wxPg::Data_row. More...

Inheritance diagram for wxPg::Row_binding:

wxPg::Binding wxPg::UI_updater wxPg::Updatable_row_binding

List of all members.

Public Member Functions

 Row_binding ()
 Creates new object.
 Row_binding (Data_row_provider *data)
 Creates new object.
virtual ~Row_binding ()
 Destroys the object.
Data_row_providerdata ()
 Returns currently used data row.
void data (Data_row_provider *data)
 Sets currently used data row.
void bind (wxWindow_updater *updater)
 Binds widget.
virtual void unbind (wxWindow *w)
 Unbind widget.
virtual void update_UI ()
 Update UI.

Protected Attributes

Data_row_providerdata_
std::vector< wxWindow_updater * > ctrl_bindings_


Detailed Description

Binding widgets to display values from wxPg::Data_row.


Constructor & Destructor Documentation

wxPg::Row_binding::Row_binding (  ) 

Creates new object.

Call data() to complete initialization of object.

wxPg::Row_binding::Row_binding ( Data_row_provider data  )  [explicit]

Creates new object.

Parameters:
data - a row of query result to be used.

virtual wxPg::Row_binding::~Row_binding (  )  [virtual]

Destroys the object.


Member Function Documentation

void wxPg::Row_binding::bind ( wxWindow_updater updater  ) 

Binds widget.

When update_UI() is called, updater is called with this as argument.
Usually you don't need to call this method directly - use binding macros, defined in binding_macros.h. Use this for your own wxWindow_updater descendant.

Parameters:
updater - function object, responsible for setting control value.

void wxPg::Row_binding::data ( Data_row_provider data  )  [inline]

Sets currently used data row.

Parameters:
data - new data row to be used.

Data_row_provider* wxPg::Row_binding::data (  )  [inline]

Returns currently used data row.

Returns:
currently used data row.

Reimplemented in wxPg::Updatable_row_binding.

virtual void wxPg::Row_binding::unbind ( wxWindow *  w  )  [virtual]

Unbind widget.

Parameters:
w is no longer updated.

Implements wxPg::Binding.

virtual void wxPg::Row_binding::update_UI (  )  [virtual]

Update UI.

Sets values of binded widgets to specified field values.

Implements wxPg::UI_updater.


Generated on Wed Oct 7 23:14:40 2009 for wxPostgres by  doxygen 1.5.8