Class BowireODataProtocol
- Namespace
- Kuestenlogik.Bowire.Protocol.OData
- Assembly
- Kuestenlogik.Bowire.Protocol.OData.dll
Bowire protocol plugin for OData v4 services. Discovers entity sets and operations via the $metadata endpoint, maps them to Bowire services and methods.
Discovery: GET {baseUrl}/$metadata → parse EDMX → entity sets become services, CRUD verbs (GET/POST/PATCH/DELETE) become methods, and the functions and actions bound to an entity type or its collection become additional methods of its set; unbound function and action imports form one more service named after the container (#529).
Auto-discovered by BowireProtocolRegistry.
public sealed class BowireODataProtocol : IBowireProtocol, IBowireManualEntry, IBowireProxySupport, IBowireUploadedSchemaReader, IDisposable
- Inheritance
-
BowireODataProtocol
- Implements
- Inherited Members
Constructors
BowireODataProtocol()
public BowireODataProtocol()
Properties
Description
One-line description shown next to the plugin's display name
in Settings → Plugins. Optional; defaults to empty so
the row falls back to "DisplayName + version" without the
description line. Keep it short (≤ 100 characters) — the row
truncates anything wider than the manage panel.
public string Description { get; }
Property Value
DescriptionKey
#691 — optional catalogue key for Description. When the workbench's active locale has an entry for it, that entry is shown; otherwise Description is, exactly as before. Third-party plugins leave it empty and keep today's behaviour.
public string DescriptionKey { get; }
Property Value
IconSvg
SVG icon for the protocol tab.
public string IconSvg { get; }
Property Value
Id
Short identifier (e.g., "grpc", "signalr").
public string Id { get; }
Property Value
Name
Protocol name shown in UI tabs.
public string Name { get; }
Property Value
ProxySupport
How far this plugin's connections follow the proxy.
public BowireProxySupport ProxySupport { get; }
Property Value
UploadedSchemaKinds
The service's $metadata document saved to a file, for a
service that does not serve it (#994).
public IReadOnlyList<BowireUploadedSchemaKind> UploadedSchemaKinds { get; }
Property Value
Methods
DescribeManualEntry()
The method types the freeform form offers (#995); the workbench has its own form for this protocol.
public BowireManualEntryForm DescribeManualEntry()
Returns
DiscoverAsync(string, bool, CancellationToken)
Discover available services and methods.
public Task<List<BowireServiceInfo>> DiscoverAsync(string serverUrl, bool showInternalServices, CancellationToken ct = default)
Parameters
serverUrlstringshowInternalServicesboolctCancellationToken
Returns
Dispose()
Dispose the lazily-built HttpClient. Owners (registry or test 'using var') release the handler at scope exit.
public void Dispose()
Initialize(IServiceProvider?)
Called after registration to inject the app's service provider (embedded mode).
public void Initialize(IServiceProvider? serviceProvider)
Parameters
serviceProviderIServiceProvider
InvokeAsync(string, string, string, List<string>, bool, Dictionary<string, string>?, CancellationToken)
Invoke a unary or client-streaming call.
public Task<InvokeResult> InvokeAsync(string serverUrl, string service, string method, List<string> jsonMessages, bool showInternalServices, Dictionary<string, string>? metadata = null, CancellationToken ct = default)
Parameters
serverUrlstringservicestringmethodstringjsonMessagesList<string>showInternalServicesboolmetadataDictionary<string, string>ctCancellationToken
Returns
InvokeStreamAsync(string, string, string, List<string>, bool, Dictionary<string, string>?, CancellationToken)
Invoke a server-streaming or duplex call.
public IAsyncEnumerable<string> InvokeStreamAsync(string serverUrl, string service, string method, List<string> jsonMessages, bool showInternalServices, Dictionary<string, string>? metadata = null, CancellationToken ct = default)
Parameters
serverUrlstringservicestringmethodstringjsonMessagesList<string>showInternalServicesboolmetadataDictionary<string, string>ctCancellationToken
Returns
LooksLikeUploadedSchema(string, ReadOnlyMemory<byte>)
An EDMX document's root element is Edmx, which is what tells
one saved as .xml from a WSDL.
public bool LooksLikeUploadedSchema(string kind, ReadOnlyMemory<byte> document)
Parameters
kindstringdocumentReadOnlyMemory<byte>
Returns
OpenChannelAsync(string, string, string, bool, Dictionary<string, string>?, CancellationToken)
Open an interactive channel (for duplex/client-streaming).
public Task<IBowireChannel?> OpenChannelAsync(string serverUrl, string service, string method, bool showInternalServices, Dictionary<string, string>? metadata = null, CancellationToken ct = default)
Parameters
serverUrlstringservicestringmethodstringshowInternalServicesboolmetadataDictionary<string, string>ctCancellationToken
Returns
ReadUploadedSchema(string, ReadOnlyMemory<byte>, string)
The entity sets an uploaded EDMX document declares, as discovery
reports them from $metadata.
public IReadOnlyList<BowireServiceInfo> ReadUploadedSchema(string kind, ReadOnlyMemory<byte> document, string sourceName)
Parameters
kindstringdocumentReadOnlyMemory<byte>sourceNamestring