Java Doc for InstallStateImpl.java in  » 6.0-JDK-Modules » j2me » com » sun » midp » jump » installer » 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 » 6.0 JDK Modules » j2me » com.sun.midp.jump.installer 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.sun.midp.jump.installer.InstallStateImpl

InstallStateImpl
public class InstallStateImpl implements InstallState,MIDletSuite(Code)
Holds the state of an installation, so it can restarted after it has been stopped.


Field Summary
public  intbeginTransferDataStatus
     Status to signal the beginning of the data transfer.
public  InvalidJadExceptionexception
     exception that stopped the installation.
public  Filefile
     Cached File object.
public  booleanforce
     Option to force an overwrite of existing components without any version comparison.
public  booleanignoreCancel
    
public  InstallInfoinstallInfo
    
public  booleanisPreviousVersion
     Signals that previous version exists.
public  byte[]jad
     Raw JAD.
public  StringjadEncoding
     character encoding of the JAD.
public  JadPropertiesjadProps
     Parsed JAD.
public  ManifestPropertiesjarProps
     Parsed manifest.
public  InstallListenerlistener
     Receives warnings and status.
public  StringlocalJadUrl
    
public  StringlocalJarUrl
    
public  byte[]manifest
     Holds the unzipped JAR manifest to be saved.
public  MIDletSuiteStoragemidletSuiteStorage
     Cache of MIDlet suite storage object.
public  intnextStep
     What to do next.
protected  Stringpassword
     Password for authentication.
public  InstallInfopreviousInstallInfo
     Previous MIDlet suite install info.
public  MIDletSuiteImplpreviousSuite
     Previous MIDlet suite info.
public  StringproxyPassword
     Password for proxy authentication.
public  StringproxyUsername
     User name for proxyAuthentication.
public  booleanremoveRMS
     Option to force the RMS data of the suite to be overwritten to be removed without comparison to the new suite.
public  SecurityHandlersecurityHandler
     Security Handler.
public  longstartTime
     When the install started, in milliseconds.
public  booleanstopInstallation
     Signals the installation to stop.
public  RandomAccessStreamstorage
     Cache of storage object.
public  intstorageId
     ID of the storage where the new midlet suite will be installed.
public  StringstorageRoot
     The root of all MIDP persistent system data.
public  SuiteSettingssuiteSettings
    
public  inttransferStatus
     Status for the data transfer method to give to the listener.
protected  Stringusername
     User name for authentication.

Constructor Summary
public  InstallStateImpl()
     Constructor.

Method Summary
public  voidcheckForPermission(int permission, String resource)
     Checks for permission and throw an exception if not allowed.
public  voidcheckForPermission(int permission, String resource, String extraValue)
     Checks for permission and throw an exception if not allowed.
public  voidcheckIfPermissionAllowed(int permission)
     Checks to see the suite has the ALLOW level for specific permission.
public  intcheckPermission(String permission)
     Gets the status of the specified permission.
public  voidclose()
    
public  StringgetAppProperty(String key)
     Gets a property of the application to be installed.
public  String[]getAuthPath()
     Gets the authorization path of this suite.
public  StringgetDisplayName()
     Returns the suite's name to display to the user.
public  intgetID()
     Gets the unique ID that the installed suite was stored with.
public  intgetJarSize()
     Gets the expected size of the JAR.
public  StringgetJarUrl()
     Gets the URL of the JAR.
public  InvalidJadExceptiongetLastException()
     Gets the last recoverable exception that stopped the install.
public  StringgetMIDletName(String classname)
     Get the name of a MIDlet.
public  MIDletInfogetMidletInfo()
     Returns the information about the first midlet in the suite.
public  intgetNumberOfMIDlets()
     Counts the number of MIDlets from its properties.
public  byte[]getPermissions()
     Gets list of permissions for this suite.
public  StringgetProperty(String key)
     Gets a property of the suite.
public  bytegetPushInterruptSetting()
     Gets push setting for interrupting other MIDlets.
public  intgetPushOptions()
     Gets push options for this suite.
public  StringgetSuiteName()
     Gets the label for the downloaded JAR.
public  booleanisEnabled()
     Determine if the a MIDlet from this suite can be run.
public  booleanisRegistered(String midletName)
     Indicates if the named MIDlet is registered in the suite with MIDlet-<n> record in the manifest or application descriptor.
public  booleanisTrusted()
     Indicates if this suite is trusted.
public  booleanisVerified()
     Check if the suite classes were successfully verified during the suite installation.
public  booleanpermissionToInterrupt(String connection)
     Asks the user want to interrupt the current MIDlet with a new MIDlet that has received network data.
public  voidsaveSettings()
     Saves any the settings (security or others) that the user may have changed.
public  voidsetPassword(String thePassword)
     Sets the password to be used for HTTP authentication.
public  voidsetProxyPassword(String thePassword)
     Sets the password to be used for HTTP proxy authentication.
public  voidsetProxyUsername(String theUsername)
     Sets the username to be used for HTTP proxy authentication.
public  voidsetTempProperty(SecurityToken token, String key, String value)
     Replace or add a property to the suite for this run only.
public  voidsetUsername(String theUsername)
     Sets the username to be used for HTTP authentication.

Field Detail
beginTransferDataStatus
public int beginTransferDataStatus(Code)
Status to signal the beginning of the data transfer.



exception
public InvalidJadException exception(Code)
exception that stopped the installation.



file
public File file(Code)
Cached File object.



force
public boolean force(Code)
Option to force an overwrite of existing components without any version comparison.



ignoreCancel
public boolean ignoreCancel(Code)
Signals that installation is at a point where cancel requests are ignored



installInfo
public InstallInfo installInfo(Code)
Contains the data obtained during the installation process



isPreviousVersion
public boolean isPreviousVersion(Code)
Signals that previous version exists.



jad
public byte[] jad(Code)
Raw JAD.



jadEncoding
public String jadEncoding(Code)
character encoding of the JAD.



jadProps
public JadProperties jadProps(Code)
Parsed JAD.



jarProps
public ManifestProperties jarProps(Code)
Parsed manifest.



listener
public InstallListener listener(Code)
Receives warnings and status.



localJadUrl
public String localJadUrl(Code)
Location for the downloaded JAD, could be null



localJarUrl
public String localJarUrl(Code)
Location for the downloaded JAR



manifest
public byte[] manifest(Code)
Holds the unzipped JAR manifest to be saved.



midletSuiteStorage
public MIDletSuiteStorage midletSuiteStorage(Code)
Cache of MIDlet suite storage object.



nextStep
public int nextStep(Code)
What to do next.



password
protected String password(Code)
Password for authentication.



previousInstallInfo
public InstallInfo previousInstallInfo(Code)
Previous MIDlet suite install info.



previousSuite
public MIDletSuiteImpl previousSuite(Code)
Previous MIDlet suite info.



proxyPassword
public String proxyPassword(Code)
Password for proxy authentication.



proxyUsername
public String proxyUsername(Code)
User name for proxyAuthentication.



removeRMS
public boolean removeRMS(Code)
Option to force the RMS data of the suite to be overwritten to be removed without comparison to the new suite.



securityHandler
public SecurityHandler securityHandler(Code)
Security Handler.



startTime
public long startTime(Code)
When the install started, in milliseconds.



stopInstallation
public boolean stopInstallation(Code)
Signals the installation to stop.



storage
public RandomAccessStream storage(Code)
Cache of storage object.



storageId
public int storageId(Code)
ID of the storage where the new midlet suite will be installed.



storageRoot
public String storageRoot(Code)
The root of all MIDP persistent system data.



suiteSettings
public SuiteSettings suiteSettings(Code)
Contains the data obtained during the installation process



transferStatus
public int transferStatus(Code)
Status for the data transfer method to give to the listener.



username
protected String username(Code)
User name for authentication.




Constructor Detail
InstallStateImpl
public InstallStateImpl()(Code)
Constructor.




Method Detail
checkForPermission
public void checkForPermission(int permission, String resource) throws InterruptedException(Code)
Checks for permission and throw an exception if not allowed. May block to ask the user a question.
Parameters:
  permission - ID of the permission to check for,the ID must be fromcom.sun.midp.security.Permissions
Parameters:
  resource - string to insert into the question, can be null ifno %2 in the question
exception:
  SecurityException - if the permission is notallowed by this token
exception:
  InterruptedException - if another thread interrupts thecalling thread while this method is waiting to preempt thedisplay.



checkForPermission
public void checkForPermission(int permission, String resource, String extraValue) throws InterruptedException(Code)
Checks for permission and throw an exception if not allowed. May block to ask the user a question.
Parameters:
  permission - ID of the permission to check for,the ID must be fromcom.sun.midp.security.Permissions
Parameters:
  resource - string to insert into the question, can be null ifno %2 in the question
Parameters:
  extraValue - string to insert into the question,can be null if no %3 in the question
exception:
  SecurityException - if the permission is notallowed by this token
exception:
  InterruptedException - if another thread interrupts thecalling thread while this method is waiting to preempt thedisplay.



checkIfPermissionAllowed
public void checkIfPermissionAllowed(int permission)(Code)
Checks to see the suite has the ALLOW level for specific permission. This is used for by internal APIs that only provide access to trusted system applications.

Only trust this method if the object has been obtained from the MIDletStateHandler of the suite.
Parameters:
  permission - permission ID fromcom.sun.midp.security.Permissions
exception:
  SecurityException - if the suite is notallowed to perform the specified action




checkPermission
public int checkPermission(String permission)(Code)
Gets the status of the specified permission. If no API on the device defines the specific permission requested then it must be reported as denied. If the status of the permission is not known because it might require a user interaction then it should be reported as unknown.
Parameters:
  permission - to check if denied, allowed, or unknown 0 if the permission is denied; 1 if the permission isallowed; -1 if the status is unknown



close
public void close()(Code)
Close the opened MIDletSuite



getAppProperty
public String getAppProperty(String key)(Code)
Gets a property of the application to be installed. First from the jaD, then if not found, the JAR manifeSt.
Parameters:
  key - key of the property value of the property or null if not found



getAuthPath
public String[] getAuthPath()(Code)
Gets the authorization path of this suite. The path starts with the most trusted CA that authorized this suite. array of CA names or null if the suite was not signed



getDisplayName
public String getDisplayName()(Code)
Returns the suite's name to display to the user. suite's name that will be displayed to the user



getID
public int getID()(Code)
Gets the unique ID that the installed suite was stored with. storage name that can be used to load the suite



getJarSize
public int getJarSize()(Code)
Gets the expected size of the JAR. size of the JAR in K bytes rounded up



getJarUrl
public String getJarUrl()(Code)
Gets the URL of the JAR. URL of the JAR



getLastException
public InvalidJadException getLastException()(Code)
Gets the last recoverable exception that stopped the install. Non-recoverable exceptions are thrown and not saved in the state. last exception that stopped the install



getMIDletName
public String getMIDletName(String classname)(Code)
Get the name of a MIDlet.
Parameters:
  classname - classname of a MIDlet in the suite name of a MIDlet to show the user



getMidletInfo
public MIDletInfo getMidletInfo()(Code)
Returns the information about the first midlet in the suite. MIDletInfo structure describing the first midletor null if it is not available



getNumberOfMIDlets
public int getNumberOfMIDlets()(Code)
Counts the number of MIDlets from its properties. IMPL_NOTE: refactor to avoid duplication with MIDletSuiteImpl. number of midlet in the suite



getPermissions
public byte[] getPermissions()(Code)
Gets list of permissions for this suite. array of permissions from Permissions



getProperty
public String getProperty(String key)(Code)
Gets a property of the suite. A property is an attribute from either the application descriptor or JAR Manifest.
Parameters:
  key - the name of the property A string with the value of the property.null is returned if no valueis available for the key.



getPushInterruptSetting
public byte getPushInterruptSetting()(Code)
Gets push setting for interrupting other MIDlets. Reuses the Permissions. push setting for interrupting MIDlets the valuewill be permission level from Permissions



getPushOptions
public int getPushOptions()(Code)
Gets push options for this suite. push options are defined in PushRegistryImpl



getSuiteName
public String getSuiteName()(Code)
Gets the label for the downloaded JAR. suite name



isEnabled
public boolean isEnabled()(Code)
Determine if the a MIDlet from this suite can be run. Note that disable suites can still have their settings changed and their install info displayed. true if suite is enabled, false otherwise



isRegistered
public boolean isRegistered(String midletName)(Code)
Indicates if the named MIDlet is registered in the suite with MIDlet-<n> record in the manifest or application descriptor.
Parameters:
  midletName - class name of the MIDlet to be checked true if the MIDlet is registered



isTrusted
public boolean isTrusted()(Code)
Indicates if this suite is trusted. (not to be confused with a domain named "trusted", this is used to determine if a trusted symbol should be displayed to the user and not used for permissions) true if the suite is trusted false if not



isVerified
public boolean isVerified()(Code)
Check if the suite classes were successfully verified during the suite installation. true if the suite classes are verified, false otherwise



permissionToInterrupt
public boolean permissionToInterrupt(String connection)(Code)
Asks the user want to interrupt the current MIDlet with a new MIDlet that has received network data.
Parameters:
  connection - connection to place in the permission question ornull for alarm true if the use wants interrupt the current MIDlet,else false



saveSettings
public void saveSettings()(Code)
Saves any the settings (security or others) that the user may have changed. Normally called by the scheduler after the last running MIDlet in the suite is destroyed. However it could be call during a suspend of the VM so that persistent settings of the suite can be preserved.



setPassword
public void setPassword(String thePassword)(Code)
Sets the password to be used for HTTP authentication.
Parameters:
  thePassword - 8 bit password



setProxyPassword
public void setProxyPassword(String thePassword)(Code)
Sets the password to be used for HTTP proxy authentication.
Parameters:
  thePassword - 8 bit password



setProxyUsername
public void setProxyUsername(String theUsername)(Code)
Sets the username to be used for HTTP proxy authentication.
Parameters:
  theUsername - 8 bit username, cannot contain a ":"



setTempProperty
public void setTempProperty(SecurityToken token, String key, String value)(Code)
Replace or add a property to the suite for this run only.
Parameters:
  token - token with the AMS permission set to allowed
Parameters:
  key - the name of the property
Parameters:
  value - the value of the property
exception:
  SecurityException - if the caller's token does not haveinternal AMS permission



setUsername
public void setUsername(String theUsername)(Code)
Sets the username to be used for HTTP authentication.
Parameters:
  theUsername - 8 bit username, cannot contain a ":"



Methods inherited from java.lang.Object
public boolean equals(Object obj)(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(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.