Class ProtoHttpOptionsResolver
Resolves the response and attachment options a protocol registered under its own key, so REST and GraphQL never share configuration even though they use the same base option types. A protocol integration resolves its own options through these methods, matching the key it registered with ProtoHttpOptionsRegistration.
public static class ProtoHttpOptionsResolver
- Inheritance
-
ProtoHttpOptionsResolver
- Inherited Members
Methods
ResolveAttachmentOptions(ProtoExecutionContext, string)
Resolves the attachment options registered for protocolName, or
null when the protocol has not opted into attachment capture. Absence is the
opt-in signal, so no default instance is invented here; the parameterless type's
ProtoTest:Http:Attachments section binds wherever the type is resolved through
ProtoOptionsRegistration.
public static ProtoHttpAttachmentOptions? ResolveAttachmentOptions(this ProtoExecutionContext context, string protocolName)
Parameters
contextProtoExecutionContextprotocolNamestring
Returns
ResolveResponseOptions(ProtoExecutionContext, string)
Resolves the response options registered for protocolName, or the shared
ProtoTest:Http:Responses defaults when the protocol registered none. The fallback resolves
through Resolve<TOptions>(IServiceProvider, Func<TOptions>, Action<TOptions>?)
so the parameterless type's documented default section really binds.
public static ProtoHttpResponseOptions ResolveResponseOptions(this ProtoExecutionContext context, string protocolName)
Parameters
contextProtoExecutionContextprotocolNamestring