java.lang.Object
org.omnifaces.cdi.push.PushExtension
- All Implemented Interfaces:
Extension
This CDI extension detects @Inject @Push PushContext injection points during bean discovery. This enables automatic registration of the
SocketEndpoint and/or SseEndpoint without requiring explicit configuration.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidActivate the push transport associated with the given type.<T> voidcollect(ProcessInjectionPoint<T, PushContext> event) Collect injection points of typePushContextqualified withPushand detect whether Web Socket and/or SSE push is used.
-
Constructor Details
-
PushExtension
public PushExtension()
-
-
Method Details
-
collect
Collect injection points of typePushContextqualified withPushand detect whether Web Socket and/or SSE push is used.- Type Parameters:
T- The generic bean type.- Parameters:
event- The process injection point event.
-
activate
Activate the push transport associated with the given type. This is intended for integrations in environments which do not support CDI portable extensions, such as Quarkus, where the@Pushinjection points are instead detected at build time. It must be invoked before the servlet context is initialized, because that is whenSocketandSseregister their endpoint.- Parameters:
type- The push type to activate.- Since:
- 5.4.4
-