|
SalesPoint Framework v3.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsale.Shop.ProcessHandle
A ProcessContext for one remote or background process.
| Field Summary | |
protected Display |
m_d
The display to be used. |
protected DataBasket |
m_db
The DataBasket to be used. |
protected SaleProcess |
m_p
The process for which this is the context. |
protected User |
m_usr
The user to be used as the current user for the process. |
| Constructor Summary | |
Shop.ProcessHandle(SaleProcess p,
Display d,
User usr,
DataBasket db)
Create a new ProcessHandle. |
|
| Method Summary | |
boolean |
canShutdown(boolean fContextDestroy)
Check whether the process that is handled by this ProcessHandle can be quitted. |
Catalog |
getCatalog(String sName)
Get a Catalog by its name. |
User |
getCurrentUser(SaleProcess p)
Get the user currently associated with the given process. |
Stock |
getStock(String sName)
Get a Stock by its name. |
boolean |
hasUseableDisplay(SaleProcess p)
True if the ProcessContext has a useable display for the given process. |
void |
log(SaleProcess p,
Loggable la)
Put an entry into the ProcessContext's log stream for a process. |
void |
popUpFormSheet(SaleProcess p,
FormSheet fs)
Pop up a FormSheet for a process. |
void |
processFinished(SaleProcess p)
Notification that a process was finished in this ProcessContext. |
void |
processStarted(SaleProcess p)
Notification that a process was started in this ProcessContext. |
void |
resume()
Resume the process that is handled by this ProcessHandle. |
void |
setFormSheet(SaleProcess p,
FormSheet fs)
Set a FormSheet for a process. |
void |
setMenuSheet(SaleProcess p,
MenuSheet ms)
Set a MenuSheet for a process. |
void |
suspend()
Suspend the process that is handled by this ProcessHandle. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected SaleProcess m_p
protected Display m_d
NullDisplay.s_ndGlobal.
protected User m_usr
protected DataBasket m_db
| Constructor Detail |
public Shop.ProcessHandle(SaleProcess p,
Display d,
User usr,
DataBasket db)
| Method Detail |
public void setFormSheet(SaleProcess p,
FormSheet fs)
throws InterruptedException
ProcessContextThe FormSheet will be displayed on the ProcessContext's display for the given process, if there
is one and it is useable. Setting a null FormSheet will remove any FormSheet
currently being displayed.
setFormSheet in interface ProcessContextp - the process that wishes to set a FormSheetfs - the FormSheet that is to be set.
InterruptedException - if an interrupt occurred while waiting for the FormSheet to be
closed. See Display.setFormSheet for details.Display.setFormSheet(sale.FormSheet)
public void popUpFormSheet(SaleProcess p,
FormSheet fs)
throws InterruptedException
ProcessContextThe FormSheet will be popped up on the ProcessContext's display for the given process, if there is one and it is useable.
popUpFormSheet in interface ProcessContextp - the process that wishes to pop up a FormSheetfs - the FormSheet that is to be set.
InterruptedException - if an interrupt occurred while waiting for the FormSheet to be
closed. See Display.popUpFormSheet for details.Display.popUpFormSheet(sale.FormSheet)
public void setMenuSheet(SaleProcess p,
MenuSheet ms)
ProcessContextThe MenuSheet will be displayed on the ProcessContext's display for the given process, if there
is one and it is useable. Setting a null MenuSheet will remove any MenuSheet
currently being displayed.
setMenuSheet in interface ProcessContextp - the process that wishes to set a MenuSheetms - the MenuSheet that is to be set.Display.setMenuSheet(sale.MenuSheet)public boolean hasUseableDisplay(SaleProcess p)
ProcessContext
hasUseableDisplay in interface ProcessContextp - the process whose display is to be checked.Display.isUseableDisplay()
public void log(SaleProcess p,
Loggable la)
throws IOException
ProcessContext
log in interface ProcessContextp - the process that wishes to put data into the log stream.la - the information that is to be logged.
IOException - if any problems occurred while writing to the log stream.public User getCurrentUser(SaleProcess p)
ProcessContext
getCurrentUser in interface ProcessContextp - the process that wishes to know its current user.
public Stock getStock(String sName)
ProcessContextThe Stock's name is resolved relative to the ProcessContext, so that the same call can result in different Stocks in different ProcessContexts.
getStock in interface ProcessContextsName - the name of the Stock to be returned.
public Catalog getCatalog(String sName)
ProcessContextThe Catalog's name is resolved relative to the ProcessContext, so that the same call can result in different Catalogs in different ProcessContexts.
getCatalog in interface ProcessContextsName - the name of the Catalog to be returned.
public void processStarted(SaleProcess p)
ProcessContextThis method is usually not called directly, but rather the Framework calls it as appropriate.
processStarted in interface ProcessContextp - the process that was started.public void processFinished(SaleProcess p)
ProcessContextThis method is usually not called directly, but rather the Framework calls it as appropriate.
processFinished in interface ProcessContextp - the process that was finished.
public void suspend()
throws InterruptedException
InterruptedExceptionpublic void resume()
public boolean canShutdown(boolean fContextDestroy)
The default implementation simply calls
m_p.canQuit (fContextDestroy);
Called by canShutdown(boolean).
|
SalesPoint Framework v3.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||