Java Doc for RegistryPersistence.java in  » IDE-Eclipse » ui-workbench » org » eclipse » ui » internal » services » 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 Eclipse » ui workbench » org.eclipse.ui.internal.services 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.eclipse.ui.internal.services.RegistryPersistence

All known Subclasses:   org.eclipse.ui.internal.services.PreferencePersistence,  org.eclipse.ui.internal.menus.LegacyActionPersistence,  org.eclipse.ui.internal.commands.CommandImagePersistence,  org.eclipse.ui.internal.menus.MenuPersistence,  org.eclipse.ui.internal.commands.CommandPersistence,  org.eclipse.ui.internal.handlers.HandlerPersistence,  org.eclipse.ui.internal.contexts.ContextPersistence,
RegistryPersistence
abstract public class RegistryPersistence implements IDisposable,IWorkbenchRegistryConstants(Code)

A manager for items parsed from the registry. This attaches a listener to the registry after the first read, and monitors the registry for changes from that point on. When RegistryPersistence.dispose() is called, the listener is detached.

This class is only intended for internal use within the org.eclipse.ui.workbench plug-in.


since:
   3.2


Field Summary
final protected static  ExpressionERROR_EXPRESSION
     The expression to return when there is an error.
protected  booleanregistryListenerAttached
     Whether the preference and registry change listeners have been attached yet.

Constructor Summary
protected  RegistryPersistence()
     Constructs a new instance of RegistryPersistence .

Method Summary
final protected static  voidaddElementToIndexedArray(IConfigurationElement elementToAdd, IConfigurationElement[][] indexedArray, int index, int currentCount)
     Inserts the given element into the indexed two-dimensional array in the array at the index.
final protected static  voidaddWarning(List warningsToLog, String message, IConfigurationElement element)
     Adds a warning to be logged at some later point in time.
final protected static  voidaddWarning(List warningsToLog, String message, IConfigurationElement element, String id)
     Adds a warning to be logged at some later point in time.
final protected static  voidaddWarning(List warningsToLog, String message, IConfigurationElement element, String id, String extraAttributeName, String extraAttributeValue)
     Adds a warning to be logged at some later point in time.
final protected static  booleancheckClass(IConfigurationElement configurationElement, List warningsToLog, String message, String id)
     Checks that the class attribute or element exists for this element.
public  voiddispose()
     Detaches the registry change listener from the registry.
abstract protected  booleanisChangeImportant(IRegistryChangeEvent event)
     Checks whether the registry change could affect this persistence class.
Parameters:
  event - The event indicating the registry change; must not benull.
final protected static  booleanisPulldown(IConfigurationElement element)
     Checks to see whether the configuration element represents a pulldown action.
final protected static  voidlogWarnings(List warningsToLog, String message)
     Logs any warnings in warningsToLog.
protected  voidread()
     Reads the various elements from the registry.
final protected static  booleanreadBoolean(IConfigurationElement configurationElement, String attribute, boolean defaultValue)
     Reads a boolean attribute from an element.
Parameters:
  configurationElement - The configuration element from which to read the attribute;must not be null.
Parameters:
  attribute - The attribute to read; must not be null.
Parameters:
  defaultValue - The default boolean value.
final protected static  StringreadOptional(IConfigurationElement configurationElement, String attribute)
     Reads an optional attribute from an element.
final protected static  ParameterizedCommandreadParameterizedCommand(IConfigurationElement configurationElement, ICommandService commandService, List warningsToLog, String message, String id)
     Reads the parameterized command from a parent configuration element.
final protected static  ParameterizedCommandreadParameters(IConfigurationElement configurationElement, List warningsToLog, Command command)
     Reads the parameters from a parent configuration element.
final protected static  StringreadRequired(IConfigurationElement configurationElement, String attribute, List warningsToLog, String message)
     Reads a required attribute from the configuration element.
Parameters:
  configurationElement - The configuration element from which to read; must not benull.
Parameters:
  attribute - The attribute to read; must not be null.
Parameters:
  warningsToLog - The list of warnings; must not be null.
Parameters:
  message - The warning message to use if the attribute is missing; mustnot be null.
final protected static  StringreadRequired(IConfigurationElement configurationElement, String attribute, List warningsToLog, String message, String id)
     Reads a required attribute from the configuration element.
final protected static  ExpressionreadWhenElement(IConfigurationElement parentElement, String whenElementName, String id, List warningsToLog)
     Reads a when child element from the given configuration element.

Field Detail
ERROR_EXPRESSION
final protected static Expression ERROR_EXPRESSION(Code)
The expression to return when there is an error. Never null.



registryListenerAttached
protected boolean registryListenerAttached(Code)
Whether the preference and registry change listeners have been attached yet.




Constructor Detail
RegistryPersistence
protected RegistryPersistence()(Code)
Constructs a new instance of RegistryPersistence . A registry change listener is created.




Method Detail
addElementToIndexedArray
final protected static void addElementToIndexedArray(IConfigurationElement elementToAdd, IConfigurationElement[][] indexedArray, int index, int currentCount)(Code)
Inserts the given element into the indexed two-dimensional array in the array at the index. The array is grown as necessary.
Parameters:
  elementToAdd - The element to add to the indexed array; may benull
Parameters:
  indexedArray - The two-dimensional array that is indexed by element type;must not be null.
Parameters:
  index - The index at which the element should be added; must be avalid index.
Parameters:
  currentCount - The current number of items in the array at the index.



addWarning
final protected static void addWarning(List warningsToLog, String message, IConfigurationElement element)(Code)
Adds a warning to be logged at some later point in time.
Parameters:
  warningsToLog - The collection of warnings to be logged; must not benull.
Parameters:
  message - The mesaage to log; must not be null.
Parameters:
  element - The element from which the warning originates; may benull.



addWarning
final protected static void addWarning(List warningsToLog, String message, IConfigurationElement element, String id)(Code)
Adds a warning to be logged at some later point in time. This logs the identifier of the item.
Parameters:
  warningsToLog - The collection of warnings to be logged; must not benull.
Parameters:
  message - The mesaage to log; must not be null.
Parameters:
  element - The element from which the warning originates; may benull.
Parameters:
  id - The identifier of the item for which a warning is beinglogged; may be null.



addWarning
final protected static void addWarning(List warningsToLog, String message, IConfigurationElement element, String id, String extraAttributeName, String extraAttributeValue)(Code)
Adds a warning to be logged at some later point in time. This logs the identifier of the item, as well as an extra attribute.
Parameters:
  warningsToLog - The collection of warnings to be logged; must not benull.
Parameters:
  message - The mesaage to log; must not be null.
Parameters:
  element - The element from which the warning originates; may benull.
Parameters:
  id - The identifier of the item for which a warning is beinglogged; may be null.
Parameters:
  extraAttributeName - The name of extra attribute to be logged; may benull.
Parameters:
  extraAttributeValue - The value of the extra attribute to be logged; may benull.



checkClass
final protected static boolean checkClass(IConfigurationElement configurationElement, List warningsToLog, String message, String id)(Code)
Checks that the class attribute or element exists for this element. This is used for executable extensions that are being read in.
Parameters:
  configurationElement - The configuration element which should contain a classattribute or a class child element; must not benull.
Parameters:
  warningsToLog - The list of warnings to be logged; never null.
Parameters:
  message - The message to log if something goes wrong; may benull.
Parameters:
  id - The identifier of the handle object; may be null. true if the class attribute or element exists;false otherwise.



dispose
public void dispose()(Code)
Detaches the registry change listener from the registry.



isChangeImportant
abstract protected boolean isChangeImportant(IRegistryChangeEvent event)(Code)
Checks whether the registry change could affect this persistence class.
Parameters:
  event - The event indicating the registry change; must not benull. true if the persistence instance is affected bythis change; false otherwise.



isPulldown
final protected static boolean isPulldown(IConfigurationElement element)(Code)
Checks to see whether the configuration element represents a pulldown action. This involves reading the style and pulldown attributes.
Parameters:
  element - The element to check; must not be null. true if the element is a pulldown action;false otherwise.



logWarnings
final protected static void logWarnings(List warningsToLog, String message)(Code)
Logs any warnings in warningsToLog.
Parameters:
  warningsToLog - The warnings to log; may be null.
Parameters:
  message - The message to include in the log entry; must not benull.



read
protected void read()(Code)
Reads the various elements from the registry. Subclasses should extend, but must not override.



readBoolean
final protected static boolean readBoolean(IConfigurationElement configurationElement, String attribute, boolean defaultValue)(Code)
Reads a boolean attribute from an element.
Parameters:
  configurationElement - The configuration element from which to read the attribute;must not be null.
Parameters:
  attribute - The attribute to read; must not be null.
Parameters:
  defaultValue - The default boolean value. The attribute's value; may be null if none.



readOptional
final protected static String readOptional(IConfigurationElement configurationElement, String attribute)(Code)
Reads an optional attribute from an element. This converts zero-length strings into null.
Parameters:
  configurationElement - The configuration element from which to read the attribute;must not be null.
Parameters:
  attribute - The attribute to read; must not be null. The attribute's value; may be null if none.



readParameterizedCommand
final protected static ParameterizedCommand readParameterizedCommand(IConfigurationElement configurationElement, ICommandService commandService, List warningsToLog, String message, String id)(Code)
Reads the parameterized command from a parent configuration element. This is used to read the parameter sub-elements from a key element, as well as the command id. Each parameter is guaranteed to be valid. If invalid parameters are found, then a warning status will be appended to the warningsToLog list. The command id is required, or a warning will be logged.
Parameters:
  configurationElement - The configuration element from which the parameters should beread; must not be null.
Parameters:
  commandService - The service providing commands for the workbench; must not benull.
Parameters:
  warningsToLog - The list of warnings found during parsing. Warnings found willparsing the parameters will be appended to this list. Thisvalue must not be null.
Parameters:
  message - The message to print if the command identifier is not present;must not be null. The array of parameters found for this configuration element;null if none can be found.



readParameters
final protected static ParameterizedCommand readParameters(IConfigurationElement configurationElement, List warningsToLog, Command command)(Code)
Reads the parameters from a parent configuration element. This is used to read the parameter sub-elements from a key element. Each parameter is guaranteed to be valid. If invalid parameters are found, then a warning status will be appended to the warningsToLog list.
Parameters:
  configurationElement - The configuration element from which the parameters should beread; must not be null.
Parameters:
  warningsToLog - The list of warnings found during parsing. Warnings found willparsing the parameters will be appended to this list. Thisvalue must not be null.
Parameters:
  command - The command around which the parameterization should becreated; must not be null. The array of parameters found for this configuration element;null if none can be found.



readRequired
final protected static String readRequired(IConfigurationElement configurationElement, String attribute, List warningsToLog, String message)(Code)
Reads a required attribute from the configuration element.
Parameters:
  configurationElement - The configuration element from which to read; must not benull.
Parameters:
  attribute - The attribute to read; must not be null.
Parameters:
  warningsToLog - The list of warnings; must not be null.
Parameters:
  message - The warning message to use if the attribute is missing; mustnot be null. The required attribute; may be null if missing.



readRequired
final protected static String readRequired(IConfigurationElement configurationElement, String attribute, List warningsToLog, String message, String id)(Code)
Reads a required attribute from the configuration element. This logs the identifier of the item if this required element cannot be found.
Parameters:
  configurationElement - The configuration element from which to read; must not benull.
Parameters:
  attribute - The attribute to read; must not be null.
Parameters:
  warningsToLog - The list of warnings; must not be null.
Parameters:
  message - The warning message to use if the attribute is missing; mustnot be null.
Parameters:
  id - The identifier of the element for which this is a requiredattribute; may be null. The required attribute; may be null if missing.



readWhenElement
final protected static Expression readWhenElement(IConfigurationElement parentElement, String whenElementName, String id, List warningsToLog)(Code)
Reads a when child element from the given configuration element. Warnings will be appended to warningsToLog.
Parameters:
  parentElement - The configuration element which might have a whenelement as a child; never null.
Parameters:
  whenElementName - The name of the when element to find; never null.
Parameters:
  id - The identifier of the menu element whose whenexpression is being read; never null.
Parameters:
  warningsToLog - The list of warnings while parsing the extension point; nevernull. The when expression for theconfigurationElement, if any; otherwise,null.



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(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.