| | 1 | | // Copyright (c) ZeroC, Inc. |
| | 2 | |
|
| | 3 | | #nullable enable |
| | 4 | |
|
| | 5 | | using System.Collections.Immutable; |
| | 6 | | using System.Net.Security; |
| | 7 | |
|
| | 8 | | namespace Ice; |
| | 9 | |
|
| | 10 | | /// <summary> |
| | 11 | | /// A class that encapsulates data to initialize a communicator. |
| | 12 | | /// </summary> |
| 1 | 13 | | public sealed record class InitializationData |
| | 14 | | { |
| | 15 | | /// <summary> |
| | 16 | | /// Gets or sets the properties for the communicator. |
| | 17 | | /// </summary> |
| | 18 | | /// <remarks>When not null, this is the object returned by <see cref="Communicator.getProperties"/>.</remarks> |
| 1 | 19 | | public Properties? properties { get; set; } |
| | 20 | |
|
| | 21 | | /// <summary> |
| | 22 | | /// Gets or sets the logger for the communicator. |
| | 23 | | /// </summary> |
| 1 | 24 | | public Logger? logger { get; set; } |
| | 25 | |
|
| | 26 | | /// <summary> |
| | 27 | | /// Gets or sets the communicator observer used by the Ice run-time. |
| | 28 | | /// </summary> |
| 1 | 29 | | public Instrumentation.CommunicatorObserver? observer { get; set; } |
| | 30 | |
|
| | 31 | | /// <summary> |
| | 32 | | /// Gets or sets the thread start hook for the communicator. |
| | 33 | | /// </summary> |
| | 34 | | /// <value> |
| | 35 | | /// The Ice runtime calls this hook for each new thread it creates. The call is made by the newly-started thread. |
| | 36 | | /// </value> |
| 1 | 37 | | public Action? threadStart { get; set; } |
| | 38 | |
|
| | 39 | | /// <summary> |
| | 40 | | /// Gets or sets the thread stop hook for the communicator. |
| | 41 | | /// </summary> |
| | 42 | | /// <value> |
| | 43 | | /// The Ice runtime calls stop before it destroys a thread. The call is made by thread that is about to be |
| | 44 | | /// destroyed. |
| | 45 | | /// </value> |
| 1 | 46 | | public Action? threadStop { get; set; } |
| | 47 | |
|
| | 48 | | /// <summary> |
| | 49 | | /// Gets or sets the executor for the communicator. |
| | 50 | | /// </summary> |
| 1 | 51 | | public Action<Action, Connection?>? executor { get; set; } |
| | 52 | |
|
| | 53 | | /// <summary> |
| | 54 | | /// Gets or sets the batch request interceptor. |
| | 55 | | /// </summary> |
| 1 | 56 | | public Action<BatchRequest, int, int>? batchRequestInterceptor { get; set; } |
| | 57 | |
|
| | 58 | | /// <summary> |
| | 59 | | /// Gets or sets the <see cref="SslClientAuthenticationOptions"/> used by the client-side ssl transport. |
| | 60 | | /// </summary> |
| 1 | 61 | | public SslClientAuthenticationOptions? clientAuthenticationOptions { get; set; } |
| | 62 | |
|
| | 63 | | /// <summary> |
| | 64 | | /// Gets or sets the plug-in factories. The corresponding plug-ins are created during communicator initialization, |
| | 65 | | /// in order, before all other plug-ins. |
| | 66 | | /// </summary> |
| 1 | 67 | | public IList<PluginFactory> pluginFactories { get; set; } = ImmutableList<PluginFactory>.Empty; |
| | 68 | |
|
| | 69 | | /// <summary> |
| | 70 | | /// Gets or sets the Slice loader. The Slice loader is used to unmarshal Slice classes and exceptions. |
| | 71 | | /// </summary> |
| 1 | 72 | | public SliceLoader? sliceLoader { get; set; } |
| | 73 | | } |