libyui-ncurses  2.44.1
NCursesUserPanel< T > Class Template Reference

Associate user data with a panel. We use templates to provide a typesafe mechanism to associate user data with a panel. A NCursesUserPanel<T> is a panel associated with some user data of type T. More...

#include <ncursesp.h>

Inheritance diagram for NCursesUserPanel< T >:
Collaboration diagram for NCursesUserPanel< T >:

List of all members.

Public Member Functions

 NCursesUserPanel (int lines, int cols, int begin_y=0, int begin_x=0, const T *p_UserData=(T *) 0)
 NCursesUserPanel (const T *p_UserData=(T *) 0)
T * UserData (void) const
virtual void setUserData (const T *p_UserData)

Static Public Member Functions

static T * UserDataOf (const PANEL &pan)

Detailed Description

template<class T>
class NCursesUserPanel< T >

Associate user data with a panel. We use templates to provide a typesafe mechanism to associate user data with a panel. A NCursesUserPanel<T> is a panel associated with some user data of type T.

Definition at line 289 of file ncursesp.h.


Constructor & Destructor Documentation

template<class T>
NCursesUserPanel< T >::NCursesUserPanel ( int  lines,
int  cols,
int  begin_y = 0,
int  begin_x = 0,
const T *  p_UserData = ( T* )0 
) [inline]

This creates an user panel of the requested size with associated user data pointed to by p_UserData.

Definition at line 297 of file ncursesp.h.

template<class T>
NCursesUserPanel< T >::NCursesUserPanel ( const T *  p_UserData = ( T* )0) [inline]

This creates an user panel associated with the ::stdscr and user data pointed to by p_UserData.

Definition at line 312 of file ncursesp.h.


Member Function Documentation

template<class T>
virtual void NCursesUserPanel< T >::setUserData ( const T *  p_UserData) [inline, virtual]

Associate the user panel with the user data pointed to by p_UserData.

Definition at line 331 of file ncursesp.h.

template<class T>
T* NCursesUserPanel< T >::UserData ( void  ) const [inline]

Retrieve the user data associated with the panel.

Definition at line 323 of file ncursesp.h.

template<class T>
static T* NCursesUserPanel< T >::UserDataOf ( const PANEL &  pan) [inline, static]

Retrieve the user data if associated with the PANEL.

Definition at line 340 of file ncursesp.h.


The documentation for this class was generated from the following file:
 All Classes Functions Variables