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


org.eclipse.ui.contexts.IWorkbenchContextSupport

All known Subclasses:   org.eclipse.ui.internal.contexts.WorkbenchContextSupport,
IWorkbenchContextSupport
public interface IWorkbenchContextSupport (Code)

An instance of this interface provides support for managing contexts at the IWorkbench level. This provides the functionality necessary to enabled contexts, disable or enabled the key binding service, as well as register shells as particular types of windows.

This interface is not intended to be extended or implemented by clients.


since:
   3.0
See Also:   org.eclipse.ui.contexts.IContextService
See Also:   org.eclipse.ui.keys.IBindingService


Field Summary
final public static  StringCONTEXT_ID_DIALOG
     The identifier for the context that is active when a shell registered as a dialog.
final public static  StringCONTEXT_ID_DIALOG_AND_WINDOW
     The identifier for the context that is active when a shell is registered as either a window or a dialog.
final public static  StringCONTEXT_ID_WINDOW
     The identifier for the context that is active when a shell is registered as a window.
final public static  intTYPE_DIALOG
     The type used for registration indicating that the shell should be treated as a dialog.
final public static  intTYPE_NONE
     The type used for registration indicating that the shell should not receive any key bindings be default.
final public static  intTYPE_WINDOW
     The type used for registration indicating that the shell should be treated as a window.


Method Summary
 voidaddEnabledSubmission(EnabledSubmission enabledSubmission)
    

Add a single enabled submission for consideration.

 voidaddEnabledSubmissions(Collection enabledSubmissions)
    

Adds zero or more enabled submissions for consideration.

 IContextManagergetContextManager()
     Returns the context manager for the workbench. the context manager for the workbench.
public  intgetShellType(Shell shell)
     Returns the shell type for the given shell.
Parameters:
  shell - The shell for which the type should be determined.
public  booleanisKeyFilterEnabled()
     Tests whether the global key binding architecture is currently active.
public  voidopenKeyAssistDialog()
     Opens the key assistant dialog positioned near the key binding entry in the status bar.
public  booleanregisterShell(Shell shell, int type)
    

Registers a shell to automatically promote or demote some basic types of contexts.

 voidremoveEnabledSubmission(EnabledSubmission enabledSubmission)
    

Removes a single enabled submission from consideration.

 voidremoveEnabledSubmissions(Collection enabledSubmissions)
    

Removes a collection of enabled submissions from consideration.

public  voidsetKeyFilterEnabled(boolean enabled)
     Enables or disables the global key binding architecture.
public  booleanunregisterShell(Shell shell)
    

Unregisters a shell that was previously registered.


Field Detail
CONTEXT_ID_DIALOG
final public static String CONTEXT_ID_DIALOG(Code)
The identifier for the context that is active when a shell registered as a dialog.



CONTEXT_ID_DIALOG_AND_WINDOW
final public static String CONTEXT_ID_DIALOG_AND_WINDOW(Code)
The identifier for the context that is active when a shell is registered as either a window or a dialog.



CONTEXT_ID_WINDOW
final public static String CONTEXT_ID_WINDOW(Code)
The identifier for the context that is active when a shell is registered as a window.



TYPE_DIALOG
final public static int TYPE_DIALOG(Code)
The type used for registration indicating that the shell should be treated as a dialog. When the given shell is active, the "In Dialogs" context should also be active.



TYPE_NONE
final public static int TYPE_NONE(Code)
The type used for registration indicating that the shell should not receive any key bindings be default. When the given shell is active, we should not provide any EnabledSubmission instances for the "In Dialogs" or "In Windows" contexts.



TYPE_WINDOW
final public static int TYPE_WINDOW(Code)
The type used for registration indicating that the shell should be treated as a window. When the given shell is active, the "In Windows" context should also be active.





Method Detail
addEnabledSubmission
void addEnabledSubmission(EnabledSubmission enabledSubmission)(Code)

Add a single enabled submission for consideration. An enabled submission is a description of certain criteria under which a particular context should become active. All added submissions will be check when the conditions in the workbench change, and zero or more contexts will be selected as active.

Just because an enabled submission is added, it does not mean that the corresponding context will become active. The workbench will consider the request, but other factors (such as conflicts) may prevent the context from becoming active.


Parameters:
  enabledSubmission - The enabled submission to be considered; must not benull.



addEnabledSubmissions
void addEnabledSubmissions(Collection enabledSubmissions)(Code)

Adds zero or more enabled submissions for consideration. An enabled submission is a description of certain criteria under which a particular context should become active. All added submissions will be check when the conditions in the workbench change, and zero or more contexts will be selected as active.

Just because an enabled submission is added, it does not mean that the corresponding context will become active. The workbench will consider the request, but other factors (such as conflicts) may prevent the context from becoming active.


Parameters:
  enabledSubmissions - The enabled submissions to be considered; must not benull, but may be empty. Every element in thecollection must be an instance ofEnabledSubmission.



getContextManager
IContextManager getContextManager()(Code)
Returns the context manager for the workbench. the context manager for the workbench. Guaranteed not to benull.



getShellType
public int getShellType(Shell shell)(Code)
Returns the shell type for the given shell.
Parameters:
  shell - The shell for which the type should be determined. If thisvalue is null, thenIWorkbenchContextSupport.TYPE_NONE is returned. IWorkbenchContextSupport.TYPE_WINDOW,IWorkbenchContextSupport.TYPE_DIALOG, orIWorkbenchContextSupport.TYPE_NONE.
since:
   3.1



isKeyFilterEnabled
public boolean isKeyFilterEnabled()(Code)
Tests whether the global key binding architecture is currently active. true if the key bindings are active;false otherwise.



openKeyAssistDialog
public void openKeyAssistDialog()(Code)
Opens the key assistant dialog positioned near the key binding entry in the status bar.
since:
   3.1



registerShell
public boolean registerShell(Shell shell, int type)(Code)

Registers a shell to automatically promote or demote some basic types of contexts. The "In Dialogs" and "In Windows" contexts are provided by the system. This a convenience method to ensure that these contexts are promoted when the given is shell is active.

If a shell is registered as a window, then the "In Windows" context is enabled when that shell is active. If a shell is registered as a dialog -- or is not registered, but has a parent shell -- then the "In Dialogs" context is enabled when that shell is active. If the shell is registered as none -- or is not registered, but has no parent shell -- then the neither of the contexts will be enabled (by us -- someone else can always enabled them).

If the provided shell has already been registered, then this method will change the registration.


Parameters:
  shell - The shell to register for key bindings; must not benull.
Parameters:
  type - The type of shell being registered. This value must be one ofthe constants given in this interface. true if the shell had already been registered(i.e., the registration has changed); falseotherwise.



removeEnabledSubmission
void removeEnabledSubmission(EnabledSubmission enabledSubmission)(Code)

Removes a single enabled submission from consideration. Only the same enabled submission will be removed; equivalent submissions will not be removed. Removing an enabled submission does not necessarily mean that the corresponding context will become inactive. It is possible that other parts of the application have requested that the context be enabled.

There is no way to disable a context. It is only possible to not enable it.


Parameters:
  enabledSubmission - The enabled submission to be removed; must not benull.



removeEnabledSubmissions
void removeEnabledSubmissions(Collection enabledSubmissions)(Code)

Removes a collection of enabled submissions from consideration. Only the same enabled submissions will be removed; equivalent submissions will not be removed. Removing an enabled submission does not necessarily mean that the corresponding context will become inactive. It is possible that other parts of the application have requested that the context be enabled.

There is no way to disable a context. It is only possible to not enable it.


Parameters:
  enabledSubmissions - The enabled submissions to be removed; must not benull, but may be empty. The collection mustonly contain instances of EnabledSubmission.



setKeyFilterEnabled
public void setKeyFilterEnabled(boolean enabled)(Code)
Enables or disables the global key binding architecture. The architecture should be enabled by default. When enabled, keyboard shortcuts are active, and that key events can trigger commands. This also means that widgets may not see all key events (as they might be trapped as a keyboard shortcut). When disabled, no key events will trapped as keyboard shortcuts, and that no commands can be triggered by keyboard events. (Exception: it is possible that someone listening for key events on a widget could trigger a command.)
Parameters:
  enabled - Whether the key filter should be enabled.



unregisterShell
public boolean unregisterShell(Shell shell)(Code)

Unregisters a shell that was previously registered. After this method completes, the shell will be treated as if it had never been registered at all. If you have registered a shell, you should ensure that this method is called when the shell is disposed. Otherwise, a potential memory leak will exist.

If the shell was never registered, or if the shell is null, then this method returns false and does nothing.
Parameters:
  shell - The shell to be unregistered; does nothing if this value isnull. true if the shell had been registered;false otherwise.




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