M. Vernier
2004-09-23 17:14:40 UTC
Ok, I am puzzled with the code. I need the media type used in a search in
order to instantiate different types of columns (audio, video ) for the
results.
The media type is accessible from info.
The columns are instantiated in the constructor of ResultPanelModel and
ResultPanelModel itself is instantiated in the contructor of the super-class
of ResultPanel: AbstractTableMediator.
I wanted to put SearchInformation as a parameter of the constructor of
AbstractTableMediator but AbstractTableMediator is supposed to be generic
and other panels inherit from it, not just ResultPanel.
How can I access info from ResultPanel::setupConstants?
/**
* Constructs a new ResultPanel for search results.
*
* @param guid the guid of the query. Used to match results.
* @param info the info of the search
*/
ResultPanel(GUID guid, SearchInformation info) {
super("SEARCH_TABLE");
SEARCH_INFO = info;
this.guid = guid;
setupRealTable();
}
order to instantiate different types of columns (audio, video ) for the
results.
The media type is accessible from info.
The columns are instantiated in the constructor of ResultPanelModel and
ResultPanelModel itself is instantiated in the contructor of the super-class
of ResultPanel: AbstractTableMediator.
I wanted to put SearchInformation as a parameter of the constructor of
AbstractTableMediator but AbstractTableMediator is supposed to be generic
and other panels inherit from it, not just ResultPanel.
How can I access info from ResultPanel::setupConstants?
/**
* Constructs a new ResultPanel for search results.
*
* @param guid the guid of the query. Used to match results.
* @param info the info of the search
*/
ResultPanel(GUID guid, SearchInformation info) {
super("SEARCH_TABLE");
SEARCH_INFO = info;
this.guid = guid;
setupRealTable();
}