Java Doc for BeanContextServices.java in  » 6.0-JDK-Core » beans » java » beans » beancontext » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Home
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
26.ERP CRM Financial
27.ESB
28.Forum
29.Game
30.GIS
31.Graphic 3D
32.Graphic Library
33.Groupware
34.HTML Parser
35.IDE
36.IDE Eclipse
37.IDE Netbeans
38.Installer
39.Internationalization Localization
40.Inversion of Control
41.Issue Tracking
42.J2EE
43.J2ME
44.JBoss
45.JMS
46.JMX
47.Library
48.Mail Clients
49.Music
50.Net
51.Parser
52.PDF
53.Portal
54.Profiler
55.Project Management
56.Report
57.RSS RDF
58.Rule Engine
59.Science
60.Scripting
61.Search Engine
62.Security
63.Sevlet Container
64.Source Control
65.Swing Library
66.Template Engine
67.Test Coverage
68.Testing
69.UML
70.Web Crawler
71.Web Framework
72.Web Mail
73.Web Server
74.Web Services
75.Web Services apache cxf 2.2.6
76.Web Services AXIS2
77.Wiki Engine
78.Workflow Engines
79.XML
80.XML UI
Java Source Code / Java Documentation » 6.0 JDK Core » beans » java.beans.beancontext 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.beans.beancontext.BeanContextServices

All known Subclasses:   java.beans.beancontext.BeanContextServicesSupport,
BeanContextServices
public interface BeanContextServices extends BeanContext,BeanContextServicesListener(Code)

The BeanContextServices interface provides a mechanism for a BeanContext to expose generic "services" to the BeanContextChild objects within.





Method Summary
 voidaddBeanContextServicesListener(BeanContextServicesListener bcsl)
    
 booleanaddService(Class serviceClass, BeanContextServiceProvider serviceProvider)
     Adds a service to this BeanContext. BeanContextServiceProviders call this method to register a particular service with this context.
 IteratorgetCurrentServiceClasses()
     Gets the currently available services for this context.
 IteratorgetCurrentServiceSelectors(Class serviceClass)
     Gets the list of service dependent service parameters (Service Selectors) for the specified service, by calling getCurrentServiceSelectors() on the underlying BeanContextServiceProvider.
 ObjectgetService(BeanContextChild child, Object requestor, Class serviceClass, Object serviceSelector, BeanContextServiceRevokedListener bcsrl)
     A BeanContextChild, or any arbitrary object associated with a BeanContextChild, may obtain a reference to a currently registered service from its nesting BeanContextServices via invocation of this method.
 booleanhasService(Class serviceClass)
     Reports whether or not a given service is currently available from this context.
 voidreleaseService(BeanContextChild child, Object requestor, Object service)
     Releases a BeanContextChild's (or any arbitrary object associated with a BeanContextChild) reference to the specified service by calling releaseService() on the underlying BeanContextServiceProvider.
 voidremoveBeanContextServicesListener(BeanContextServicesListener bcsl)
    
 voidrevokeService(Class serviceClass, BeanContextServiceProvider serviceProvider, boolean revokeCurrentServicesNow)
     BeanContextServiceProviders wishing to remove a currently registered service from this context may do so via invocation of this method.



Method Detail
addBeanContextServicesListener
void addBeanContextServicesListener(BeanContextServicesListener bcsl)(Code)
Adds a BeanContextServicesListener to this BeanContext
Parameters:
  bcsl - the BeanContextServicesListener to add



addService
boolean addService(Class serviceClass, BeanContextServiceProvider serviceProvider)(Code)
Adds a service to this BeanContext. BeanContextServiceProviders call this method to register a particular service with this context. If the service has not previously been added, the BeanContextServices associates the service with the BeanContextServiceProvider and fires a BeanContextServiceAvailableEvent to all currently registered BeanContextServicesListeners. The method then returns true, indicating that the addition of the service was successful. If the given service has already been added, this method simply returns false.
Parameters:
  serviceClass - the service to add
Parameters:
  serviceProvider - the BeanContextServiceProvider associated with the service



getCurrentServiceClasses
Iterator getCurrentServiceClasses()(Code)
Gets the currently available services for this context. an Iterator consisting of the currently available services



getCurrentServiceSelectors
Iterator getCurrentServiceSelectors(Class serviceClass)(Code)
Gets the list of service dependent service parameters (Service Selectors) for the specified service, by calling getCurrentServiceSelectors() on the underlying BeanContextServiceProvider.
Parameters:
  serviceClass - the specified service the currently available service selectors for the named serviceClass



getService
Object getService(BeanContextChild child, Object requestor, Class serviceClass, Object serviceSelector, BeanContextServiceRevokedListener bcsrl) throws TooManyListenersException(Code)
A BeanContextChild, or any arbitrary object associated with a BeanContextChild, may obtain a reference to a currently registered service from its nesting BeanContextServices via invocation of this method. When invoked, this method gets the service by calling the getService() method on the underlying BeanContextServiceProvider.
Parameters:
  child - the BeanContextChild associated with this request
Parameters:
  requestor - the object requesting the service
Parameters:
  serviceClass - class of the requested service
Parameters:
  serviceSelector - the service dependent parameter
Parameters:
  bcsrl - the BeanContextServiceRevokedListener to notifyif the service should later become revoked
throws:
  TooManyListenersException - a reference to this context's named Service as requested or null



hasService
boolean hasService(Class serviceClass)(Code)
Reports whether or not a given service is currently available from this context.
Parameters:
  serviceClass - the service in question true if the service is available



releaseService
void releaseService(BeanContextChild child, Object requestor, Object service)(Code)
Releases a BeanContextChild's (or any arbitrary object associated with a BeanContextChild) reference to the specified service by calling releaseService() on the underlying BeanContextServiceProvider.
Parameters:
  child - the BeanContextChild
Parameters:
  requestor - the requestor
Parameters:
  service - the service



removeBeanContextServicesListener
void removeBeanContextServicesListener(BeanContextServicesListener bcsl)(Code)
Removes a BeanContextServicesListener from this BeanContext
Parameters:
  bcsl - the BeanContextServicesListener to remove from this context



revokeService
void revokeService(Class serviceClass, BeanContextServiceProvider serviceProvider, boolean revokeCurrentServicesNow)(Code)
BeanContextServiceProviders wishing to remove a currently registered service from this context may do so via invocation of this method. Upon revocation of the service, the BeanContextServices fires a BeanContextServiceRevokedEvent to its list of currently registered BeanContextServiceRevokedListeners and BeanContextServicesListeners.
Parameters:
  serviceClass - the service to revoke from this BeanContextServices
Parameters:
  serviceProvider - the BeanContextServiceProvider associated withthis particular service that is being revoked
Parameters:
  revokeCurrentServicesNow - a value of true indicates an exceptional circumstance where the BeanContextServiceProvider orBeanContextServices wishes to immediately terminate service to all currently outstanding references to the specified service.



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