- java.lang.Object
-
- io.helidon.webserver.cors.CorsSupportBase<ServerRequest,ServerResponse,CorsSupport,CorsSupport.Builder>
-
- io.helidon.webserver.cors.CorsSupport
-
- All Implemented Interfaces:
Handler,Service,BiConsumer<ServerRequest,ServerResponse>
public class CorsSupport extends CorsSupportBase<ServerRequest,ServerResponse,CorsSupport,CorsSupport.Builder> implements Service, Handler
SE implementation ofCorsSupportBase.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCorsSupport.Builder-
Nested classes/interfaces inherited from class io.helidon.webserver.cors.CorsSupportBase
CorsSupportBase.RequestAdapter<T>, CorsSupportBase.ResponseAdapter<T>
-
Nested classes/interfaces inherited from interface io.helidon.webserver.Handler
Handler.EntityHandler<T>
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(ServerRequest request, ServerResponse response)static CorsSupport.Builderbuilder()static CorsSupportcreate()static CorsSupportcreate(Config config)Creates a newCorsSupportinstance based on the provided configuration expected to match the basicCrossOriginConfigformat.static CorsSupportcreateMapped(Config config)Creates a newCorsSupportinstance based on the provided configuration expected to contain mapped cross-origin config information.StringtoString()voidupdate(Routing.Rules rules)UpdatesRouting.Ruleswithhandlersrepresenting this service.-
Methods inherited from class io.helidon.webserver.cors.CorsSupportBase
describe, helper, name, prepareResponse, processRequest
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.function.BiConsumer
andThen
-
-
-
-
Method Detail
-
builder
public static CorsSupport.Builder builder()
- Returns:
- new builder for CorsSupport
-
create
public static CorsSupport create()
- Returns:
- new CorsSupport with default settings
-
update
public void update(Routing.Rules rules)
Description copied from interface:ServiceUpdatesRouting.Ruleswithhandlersrepresenting this service.
-
accept
public void accept(ServerRequest request, ServerResponse response)
Description copied from interface:Handler- Specified by:
acceptin interfaceBiConsumer<ServerRequest,ServerResponse>- Specified by:
acceptin interfaceHandler- Parameters:
request- an HTTP server request.response- an HTTP server response.
-
create
public static CorsSupport create(Config config)
Creates a newCorsSupportinstance based on the provided configuration expected to match the basicCrossOriginConfigformat.- Parameters:
config- node containing the cross-origin information- Returns:
- initialized
CorsSupportinstance
-
createMapped
public static CorsSupport createMapped(Config config)
Creates a newCorsSupportinstance based on the provided configuration expected to contain mapped cross-origin config information.- Parameters:
config- node containing the mapped cross-origin information- Returns:
- initialized
CorsSupportinstance
-
-