Java Doc for WaitScreen.java in  » IDE-Netbeans » vmd.analyzer » org » netbeans » microedition » lcdui » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Netbeans » vmd.analyzer » org.netbeans.microedition.lcdui 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.netbeans.microedition.lcdui.AbstractInfoScreen
   org.netbeans.microedition.lcdui.WaitScreen

WaitScreen
public class WaitScreen extends AbstractInfoScreen (Code)
This component suits as a wait screen, which let the user to execute a blocking background task (e.g. a network communication) and waits for it until finished.

The background task is being started immediately prior the component is being shown on the screen.

When the background task is finished, this component calls commandAction method on assigned CommandListener object. In the case of success, the commandAction method is called with SUCCESS_COMMAND as parameter, in the case of failure, the commandAction method is called with FAILURE_COMMAND as parameter.

The functionality from previous version, where the component automatically swiches to another Displayable objects is still available, but has beeen deprecated.

The deprecated behavior is the following - in the case of success (i.e. the task finished successfully), it switches to displayable(s) supplied by setNextDisplayable() methods, in the case of failure, it switched to displaybles(s) supplied by setFailureDisplayable() methods. In the case there is not set failure displayable, WaitScreen even in the case of failure switches to displayables specified by the setNextDisplayable() method. In the case there is even no next displayable specified, after the task is finished, WaitScreen switches back to the screen it was previously visible on the display.
author:
   breh



Field Summary
final public static  CommandFAILURE_COMMAND
    
final public static  CommandSUCCESS_COMMAND
    

Constructor Summary
public  WaitScreen(Display display)
     Creates a new instance of WaitScreen for given Display object.

Method Summary
public  CancellableTaskgetTask()
     Gets the background task.
public  voidsetFailureDisplayable(Displayable failureDisplayble)
     Sets the displayable to be used to switch to in the case of the background task failure.
public  voidsetFailureDisplayable(Alert failureAlert, Displayable failureDisplayble)
     Requests that the specified Alert is going to be shown in the case of failure, and failureDisplayable be made current after the Alert is dismissed.

The failureDisplayable parameter cannot be Alert and in the case failureAlert is not null, it also cannot be null.
Parameters:
  failureAlert - alert to be shown, or null if the component should always switch to nextDisplayable
Parameters:
  failureDisplayble - a displayable to be shown after the alert is being dismissed.

public  voidsetTask(CancellableTask task)
     Sets the task to be run on the background.
protected  voidshowNotify()
    

Field Detail
FAILURE_COMMAND
final public static Command FAILURE_COMMAND(Code)
Command fired when the background task failed (threw exception)



SUCCESS_COMMAND
final public static Command SUCCESS_COMMAND(Code)
Command fired when the background task was finished succesfully




Constructor Detail
WaitScreen
public WaitScreen(Display display) throws IllegalArgumentException(Code)
Creates a new instance of WaitScreen for given Display object.
Parameters:
  display - A non-null display object.
throws:
  IllegalArgumentException - when the supplied argument is null




Method Detail
getTask
public CancellableTask getTask()(Code)
Gets the background task. task being executed in background while this component is being shownon the screen



setFailureDisplayable
public void setFailureDisplayable(Displayable failureDisplayble)(Code)
Sets the displayable to be used to switch to in the case of the background task failure.
Parameters:
  failureDisplayble - displayable, or null if the component should switch to nextDisplayableeven in the case of failure.



setFailureDisplayable
public void setFailureDisplayable(Alert failureAlert, Displayable failureDisplayble) throws IllegalArgumentException(Code)
Requests that the specified Alert is going to be shown in the case of failure, and failureDisplayable be made current after the Alert is dismissed.

The failureDisplayable parameter cannot be Alert and in the case failureAlert is not null, it also cannot be null.
Parameters:
  failureAlert - alert to be shown, or null if the component should always switch to nextDisplayable
Parameters:
  failureDisplayble - a displayable to be shown after the alert is being dismissed. This displayablecannot be null if the failureAlert is not null and it also cannot beAlert.
throws:
  java.lang.IllegalArgumentException - If the failureAlert is not null and failureDisplay is null at the same time, orif the failureDisplayable is instance of Alert




setTask
public void setTask(CancellableTask task)(Code)
Sets the task to be run on the background.
Parameters:
  task - task to be executed



showNotify
protected void showNotify()(Code)
starts the supplied task



Methods inherited from org.netbeans.microedition.lcdui.AbstractInfoScreen
public ColorSchema getColorSchema()(Code)(Java Doc)
final protected CommandListener getCommandListener()(Code)(Java Doc)
protected Display getDisplay()(Code)(Java Doc)
public Image getImage()(Code)(Java Doc)
protected Alert getNextAlert()(Code)(Java Doc)
protected Displayable getNextDisplayable()(Code)(Java Doc)
public String getText()(Code)(Java Doc)
public Font getTextFont()(Code)(Java Doc)
protected void paint(Graphics g)(Code)(Java Doc)
public void setColorSchema(ColorSchema colorSchema)(Code)(Java Doc)
public void setCommandListener(CommandListener commandListener)(Code)(Java Doc)
public void setImage(Image image)(Code)(Java Doc)
public void setNextDisplayable(Displayable nextDisplayable)(Code)(Java Doc)
public void setNextDisplayable(Alert nextAlert, Displayable nextDisplayable) throws IllegalArgumentException(Code)(Java Doc)
public void setText(String text)(Code)(Java Doc)
public void setTextFont(Font font)(Code)(Java Doc)
protected void showNotify()(Code)(Java Doc)
protected void sizeChanged(int w, int h)(Code)(Java Doc)
protected static void switchToDisplayable(Display display, Alert alert, Displayable displayable)(Code)(Java Doc)
protected void switchToNextDisplayable()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.