zeroc-ice 3.8.0__cp312-cp312-macosx_10_13_universal2.whl → 3.8.0.post1__cp312-cp312-macosx_10_13_universal2.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- Ice/BTEndpointType.py +7 -0
- Ice/BTSEndpointType.py +7 -0
- Ice/Blobject.py +1 -1
- Ice/Communicator.py +130 -118
- Ice/CompressBatch.py +12 -12
- Ice/Current.py +5 -6
- Ice/EndpointSelectionType.py +8 -8
- Ice/EventLoopAdapter.py +4 -4
- Ice/Exception.py +6 -8
- Ice/FormatType.py +8 -1
- Ice/Future.py +78 -78
- Ice/IcePyTypes.py +2 -0
- Ice/ImplicitContext.py +28 -35
- Ice/InitializationData.py +23 -22
- Ice/InvocationFuture.py +31 -34
- Ice/LocalException.py +1 -1
- Ice/LocalExceptions.py +82 -94
- Ice/LogMessageType.py +16 -15
- Ice/Logger.py +10 -10
- Ice/Object.py +22 -17
- Ice/ObjectAdapter.py +200 -167
- Ice/ObjectPrx.py +196 -202
- Ice/OperationMode.py +19 -14
- Ice/ProcessLogger.py +18 -2
- Ice/Properties.py +63 -79
- Ice/Proxy.py +73 -10
- Ice/ReplyStatus.py +42 -35
- Ice/SSLEndpointType.py +7 -0
- Ice/ServantLocator.py +30 -35
- Ice/SliceInfo.py +3 -3
- Ice/SlicedData.py +1 -1
- Ice/TCPEndpointType.py +7 -0
- Ice/ToStringMode.py +19 -19
- Ice/UDPEndpointType.py +7 -0
- Ice/URIEndpointType.py +7 -0
- Ice/UnknownSlicedValue.py +11 -3
- Ice/UserException.py +1 -1
- Ice/Util.py +27 -26
- Ice/Value.py +7 -7
- Ice/WSEndpointType.py +7 -0
- Ice/WSSEndpointType.py +7 -0
- Ice/__init__.py +2 -0
- Ice/iAPEndpointType.py +7 -0
- Ice/iAPSEndpointType.py +7 -0
- IceGrid/LoadSample.py +12 -12
- IceGrid/ServerState.py +29 -25
- IcePy-stubs/__init__.pyi +151 -152
- IcePy.cpython-312-darwin.so +0 -0
- {zeroc_ice-3.8.0.dist-info → zeroc_ice-3.8.0.post1.dist-info}/METADATA +1 -1
- {zeroc_ice-3.8.0.dist-info → zeroc_ice-3.8.0.post1.dist-info}/RECORD +53 -53
- {zeroc_ice-3.8.0.dist-info → zeroc_ice-3.8.0.post1.dist-info}/WHEEL +0 -0
- {zeroc_ice-3.8.0.dist-info → zeroc_ice-3.8.0.post1.dist-info}/entry_points.txt +0 -0
- {zeroc_ice-3.8.0.dist-info → zeroc_ice-3.8.0.post1.dist-info}/top_level.txt +0 -0
Ice/BTEndpointType.py
CHANGED
Ice/BTSEndpointType.py
CHANGED
Ice/Blobject.py
CHANGED
|
@@ -35,7 +35,7 @@ class Blobject(Object, ABC):
|
|
|
35
35
|
|
|
36
36
|
Returns
|
|
37
37
|
-------
|
|
38
|
-
tuple
|
|
38
|
+
tuple[bool, bytes] | Awaitable[tuple[bool, bytes]]
|
|
39
39
|
- bool True if the operation succeeded, False if it raised a user exception.
|
|
40
40
|
- bytes The encoded form of the operation's results or the user exception.
|
|
41
41
|
"""
|
Ice/Communicator.py
CHANGED
|
@@ -37,8 +37,8 @@ class Communicator:
|
|
|
37
37
|
- creating and destroying object adapters
|
|
38
38
|
- loading plug-ins
|
|
39
39
|
- managing properties (configuration), retries, logging, instrumentation, and more.
|
|
40
|
-
|
|
41
|
-
communicators in a single program, but this is not common.
|
|
40
|
+
A communicator is usually the first object you create when programming with Ice.
|
|
41
|
+
You can create multiple communicators in a single program, but this is not common.
|
|
42
42
|
|
|
43
43
|
Example
|
|
44
44
|
-------
|
|
@@ -75,15 +75,15 @@ class Communicator:
|
|
|
75
75
|
|
|
76
76
|
Parameters
|
|
77
77
|
----------
|
|
78
|
-
args : list
|
|
79
|
-
The command-line arguments, parsed into Ice properties by this
|
|
80
|
-
eventLoop : asyncio.AbstractEventLoop, optional
|
|
78
|
+
args : list[str] | None, optional
|
|
79
|
+
The command-line arguments, parsed into Ice properties by this function.
|
|
80
|
+
eventLoop : asyncio.AbstractEventLoop | None, optional
|
|
81
81
|
An asyncio event loop used to run coroutines and wrap futures. If provided, a new event loop adapter is
|
|
82
82
|
created and configured with the communicator. This adapter is responsible for executing coroutines returned
|
|
83
83
|
by Ice asynchronous dispatch methods and for wrapping Ice futures (from Ice Async APIs) into asyncio
|
|
84
84
|
futures. This argument and the `initData` argument are mutually exclusive. If the `initData` argument is
|
|
85
85
|
provided, the event loop adapter can be set using the :attr:`InitializationData.eventLoopAdapter` attribute.
|
|
86
|
-
initData : InitializationData, optional
|
|
86
|
+
initData : InitializationData | None, optional
|
|
87
87
|
Options for the new communicator. This argument and the `args` argument are mutually exclusive.
|
|
88
88
|
"""
|
|
89
89
|
eventLoopAdapter = None
|
|
@@ -115,12 +115,12 @@ class Communicator:
|
|
|
115
115
|
@property
|
|
116
116
|
def eventLoopAdapter(self) -> EventLoopAdapter | None:
|
|
117
117
|
"""
|
|
118
|
-
|
|
118
|
+
Returns this communicator's event loop adapter, or ``None`` if the communicator does not have one.
|
|
119
119
|
|
|
120
120
|
Returns
|
|
121
121
|
-------
|
|
122
122
|
EventLoopAdapter | None
|
|
123
|
-
The event loop adapter used
|
|
123
|
+
The event loop adapter used by this communicator.
|
|
124
124
|
"""
|
|
125
125
|
|
|
126
126
|
return self._eventLoopAdapter
|
|
@@ -130,17 +130,17 @@ class Communicator:
|
|
|
130
130
|
|
|
131
131
|
def destroy(self) -> None:
|
|
132
132
|
"""
|
|
133
|
-
Destroys this communicator. This
|
|
134
|
-
object adapters, and closes all outgoing connections.
|
|
133
|
+
Destroys this communicator. This function calls :func:`shutdown` implicitly. Calling this function destroys all
|
|
134
|
+
object adapters, and closes all outgoing connections. This function waits for all outstanding dispatches to
|
|
135
135
|
complete before returning. This includes "bidirectional dispatches" that execute on outgoing connections.
|
|
136
136
|
"""
|
|
137
137
|
self._impl.destroy()
|
|
138
138
|
|
|
139
139
|
def destroyAsync(self) -> Awaitable[None]:
|
|
140
140
|
"""
|
|
141
|
-
Destroys this communicator asynchronously.
|
|
142
|
-
|
|
143
|
-
|
|
141
|
+
Destroys this communicator asynchronously.
|
|
142
|
+
|
|
143
|
+
See :func:`destroy`.
|
|
144
144
|
"""
|
|
145
145
|
future = Future()
|
|
146
146
|
|
|
@@ -156,16 +156,16 @@ class Communicator:
|
|
|
156
156
|
|
|
157
157
|
def shutdown(self) -> None:
|
|
158
158
|
"""
|
|
159
|
-
Shuts down this communicator. This
|
|
160
|
-
communicator. Shutting down a communicator has no effect on outgoing connections.
|
|
159
|
+
Shuts down this communicator. This function calls :func:`ObjectAdapter.deactivate` on all object adapters
|
|
160
|
+
created by this communicator. Shutting down a communicator has no effect on outgoing connections.
|
|
161
161
|
"""
|
|
162
162
|
self._impl.shutdown()
|
|
163
163
|
|
|
164
164
|
def waitForShutdown(self) -> None:
|
|
165
165
|
"""
|
|
166
|
-
Waits for shutdown to complete. This
|
|
167
|
-
created by this communicator. In a client application that does not accept incoming connections, this
|
|
168
|
-
|
|
166
|
+
Waits for shutdown to complete. This function calls :func:`ObjectAdapter.waitForDeactivate` on all object
|
|
167
|
+
adapters created by this communicator. In a client application that does not accept incoming connections, this
|
|
168
|
+
function returns as soon as another thread calls :func:`shutdown` or :func:`destroy` on this communicator.
|
|
169
169
|
"""
|
|
170
170
|
# If invoked by the main thread, waitForShutdown only blocks for the specified timeout in order to give us a
|
|
171
171
|
# chance to handle signals.
|
|
@@ -174,9 +174,13 @@ class Communicator:
|
|
|
174
174
|
|
|
175
175
|
def shutdownCompleted(self) -> Awaitable[None]:
|
|
176
176
|
"""
|
|
177
|
-
|
|
177
|
+
Returns an :class:`Awaitable` that completes when the communicator's shutdown completes.
|
|
178
|
+
This task always completes successfully.
|
|
178
179
|
|
|
179
|
-
|
|
180
|
+
Notes
|
|
181
|
+
-----
|
|
182
|
+
The shutdown of a communicator completes when all its incoming connections are closed.
|
|
183
|
+
Awaiting this task is equivalent to awaiting :func:`waitForShutdown`.
|
|
180
184
|
|
|
181
185
|
Returns
|
|
182
186
|
-------
|
|
@@ -187,61 +191,56 @@ class Communicator:
|
|
|
187
191
|
|
|
188
192
|
def isShutdown(self) -> bool:
|
|
189
193
|
"""
|
|
190
|
-
Checks whether or not shutdown was called on this communicator.
|
|
194
|
+
Checks whether or not :func:`shutdown` was called on this communicator.
|
|
191
195
|
|
|
192
196
|
Returns
|
|
193
197
|
-------
|
|
194
198
|
bool
|
|
195
|
-
True if shutdown was called on this communicator
|
|
199
|
+
``True`` if :func:`shutdown` was called on this communicator, ``False`` otherwise
|
|
196
200
|
"""
|
|
197
201
|
return self._impl.isShutdown()
|
|
198
202
|
|
|
199
203
|
def stringToProxy(self, str: str) -> ObjectPrx | None:
|
|
200
204
|
"""
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
For example, `MyCategory/MyObject:tcp -h some_host -p 10000` creates a proxy that refers to the Ice object
|
|
204
|
-
having an identity with a name "MyObject" and a category "MyCategory", with the server running on host "some_host",
|
|
205
|
-
port 10000. If the proxy string representation does not parse correctly, the operation throws ParseException.
|
|
206
|
-
Refer to the Ice manual for a detailed description of the syntax supported by proxy strings.
|
|
205
|
+
Converts a stringified proxy into a proxy.
|
|
207
206
|
|
|
208
207
|
Parameters
|
|
209
208
|
----------
|
|
210
|
-
|
|
211
|
-
The proxy
|
|
209
|
+
str : str
|
|
210
|
+
The stringified proxy to convert into a proxy.
|
|
212
211
|
|
|
213
212
|
Returns
|
|
214
213
|
-------
|
|
215
214
|
ObjectPrx | None
|
|
216
|
-
The proxy, or None if
|
|
215
|
+
The proxy, or ``None`` if ``str`` is an empty string.
|
|
217
216
|
|
|
218
217
|
Raises
|
|
219
218
|
------
|
|
220
219
|
ParseException
|
|
221
|
-
If
|
|
220
|
+
If ``str`` is not a valid proxy string.
|
|
222
221
|
"""
|
|
223
222
|
return self._impl.stringToProxy(str)
|
|
224
223
|
|
|
225
224
|
def proxyToString(self, proxy: ObjectPrx | None) -> str:
|
|
226
225
|
"""
|
|
227
|
-
|
|
226
|
+
Converts a proxy into a string.
|
|
228
227
|
|
|
229
228
|
Parameters
|
|
230
229
|
----------
|
|
231
230
|
proxy : ObjectPrx | None
|
|
232
|
-
The proxy to convert into a
|
|
231
|
+
The proxy to convert into a stringified proxy.
|
|
233
232
|
|
|
234
233
|
Returns
|
|
235
234
|
-------
|
|
236
235
|
str
|
|
237
|
-
The proxy
|
|
236
|
+
The stringified proxy, or an empty string if ``proxy`` is ``None``.
|
|
238
237
|
"""
|
|
239
238
|
return self._impl.proxyToString(proxy)
|
|
240
239
|
|
|
241
240
|
def propertyToProxy(self, property: str) -> ObjectPrx | None:
|
|
242
241
|
"""
|
|
243
|
-
Converts a set of proxy properties into a proxy. The "base" name supplied in the property argument refers
|
|
244
|
-
property containing a stringified proxy, such as
|
|
242
|
+
Converts a set of proxy properties into a proxy. The "base" name supplied in the ``property`` argument refers
|
|
243
|
+
to a property containing a stringified proxy, such as ``MyProxy=id:tcp -h localhost -p 10000``.
|
|
245
244
|
Additional properties configure local settings for the proxy.
|
|
246
245
|
|
|
247
246
|
Parameters
|
|
@@ -252,18 +251,18 @@ class Communicator:
|
|
|
252
251
|
Returns
|
|
253
252
|
-------
|
|
254
253
|
ObjectPrx | None
|
|
255
|
-
The proxy, or None if the property is not set.
|
|
254
|
+
The proxy, or ``None`` if the property is not set.
|
|
256
255
|
"""
|
|
257
256
|
return self._impl.propertyToProxy(property)
|
|
258
257
|
|
|
259
258
|
def proxyToProperty(self, proxy: ObjectPrx, property: str) -> dict[str, str]:
|
|
260
259
|
"""
|
|
261
|
-
|
|
260
|
+
Converts a proxy into a set of proxy properties.
|
|
262
261
|
|
|
263
262
|
Parameters
|
|
264
263
|
----------
|
|
265
264
|
proxy : ObjectPrx
|
|
266
|
-
The proxy
|
|
265
|
+
The proxy.
|
|
267
266
|
property : str
|
|
268
267
|
The base property name.
|
|
269
268
|
|
|
@@ -276,7 +275,7 @@ class Communicator:
|
|
|
276
275
|
|
|
277
276
|
def identityToString(self, identity: Identity) -> str:
|
|
278
277
|
"""
|
|
279
|
-
|
|
278
|
+
Converts an identity into a string.
|
|
280
279
|
|
|
281
280
|
Parameters
|
|
282
281
|
----------
|
|
@@ -286,18 +285,17 @@ class Communicator:
|
|
|
286
285
|
Returns
|
|
287
286
|
-------
|
|
288
287
|
str
|
|
289
|
-
The
|
|
288
|
+
The "stringified" identity.
|
|
290
289
|
"""
|
|
291
290
|
return self._impl.identityToString(identity)
|
|
292
291
|
|
|
293
292
|
def createObjectAdapter(self, name: str) -> ObjectAdapter:
|
|
294
293
|
"""
|
|
295
|
-
|
|
294
|
+
Creates a new object adapter. The endpoints for the object adapter are taken from the property
|
|
295
|
+
``name.Endpoints``.
|
|
296
296
|
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
or by collocated invocations that originate from the same communicator as is used by the adapter. Attempts to create
|
|
300
|
-
a named object adapter for which no configuration can be found raise an InitializationException.
|
|
297
|
+
It is legal to create an object adapter with the empty string as its name. Such an object adapter is
|
|
298
|
+
accessible via bidirectional connections or by collocated invocations.
|
|
301
299
|
|
|
302
300
|
Parameters
|
|
303
301
|
----------
|
|
@@ -314,17 +312,16 @@ class Communicator:
|
|
|
314
312
|
|
|
315
313
|
def createObjectAdapterWithEndpoints(self, name: str, endpoints: str) -> ObjectAdapter:
|
|
316
314
|
"""
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
convenience function. Calling this operation with an empty name will result in a UUID being generated for the name.
|
|
315
|
+
Creates a new object adapter with endpoints. This function sets the property ``name.Endpoints``,
|
|
316
|
+
and then calls :func:`createObjectAdapter`. It is provided as a convenience function. Calling this function
|
|
317
|
+
with an empty name will result in a UUID being generated for the name.
|
|
321
318
|
|
|
322
319
|
Parameters
|
|
323
320
|
----------
|
|
324
321
|
name : str
|
|
325
322
|
The object adapter name.
|
|
326
323
|
endpoints : str
|
|
327
|
-
The endpoints
|
|
324
|
+
The endpoints of the object adapter.
|
|
328
325
|
|
|
329
326
|
Returns
|
|
330
327
|
-------
|
|
@@ -336,9 +333,8 @@ class Communicator:
|
|
|
336
333
|
|
|
337
334
|
def createObjectAdapterWithRouter(self, name: str, router: RouterPrx) -> ObjectAdapter:
|
|
338
335
|
"""
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
This operation creates a routed object adapter. Calling this operation with an empty name will result in a UUID being generated for the name.
|
|
336
|
+
Creates a new object adapter with a router. This function creates a routed object adapter.
|
|
337
|
+
Calling this function with an empty name will result in a UUID being generated for the name.
|
|
342
338
|
|
|
343
339
|
Parameters
|
|
344
340
|
----------
|
|
@@ -357,19 +353,26 @@ class Communicator:
|
|
|
357
353
|
|
|
358
354
|
def getDefaultObjectAdapter(self) -> ObjectAdapter | None:
|
|
359
355
|
"""
|
|
360
|
-
|
|
361
|
-
communicator. This
|
|
356
|
+
Gets the object adapter that is associated by default with new outgoing connections created by this
|
|
357
|
+
communicator. This function returns ``None`` unless you set a non-``None`` default object adapter using
|
|
358
|
+
:func:`setDefaultObjectAdapter`.
|
|
362
359
|
|
|
363
360
|
Returns
|
|
364
361
|
-------
|
|
365
362
|
ObjectAdapter | None
|
|
366
363
|
The object adapter associated by default with new outgoing connections.
|
|
364
|
+
|
|
365
|
+
Raises
|
|
366
|
+
------
|
|
367
|
+
CommunicatorDestroyedException
|
|
368
|
+
If the communicator has been destroyed.
|
|
367
369
|
"""
|
|
368
370
|
return self._impl.getDefaultObjectAdapter()
|
|
369
371
|
|
|
370
372
|
def setDefaultObjectAdapter(self, adapter: ObjectAdapter | None):
|
|
371
373
|
"""
|
|
372
|
-
|
|
374
|
+
Sets the object adapter that will be associated with new outgoing connections created by this communicator.
|
|
375
|
+
This function has no effect on existing outgoing connections, or on incoming connections.
|
|
373
376
|
|
|
374
377
|
Parameters
|
|
375
378
|
----------
|
|
@@ -378,14 +381,15 @@ class Communicator:
|
|
|
378
381
|
"""
|
|
379
382
|
self._impl.setDefaultObjectAdapter(adapter)
|
|
380
383
|
|
|
381
|
-
def getImplicitContext(self):
|
|
384
|
+
def getImplicitContext(self) -> ImplicitContext | None:
|
|
382
385
|
"""
|
|
383
|
-
|
|
386
|
+
Gets the implicit context associated with this communicator.
|
|
384
387
|
|
|
385
388
|
Returns
|
|
386
389
|
-------
|
|
387
|
-
ImplicitContext
|
|
388
|
-
The implicit context associated with this communicator
|
|
390
|
+
ImplicitContext | None
|
|
391
|
+
The implicit context associated with this communicator; returns ``None`` when the property
|
|
392
|
+
``Ice.ImplicitContext`` is not set or is set to ``None``.
|
|
389
393
|
"""
|
|
390
394
|
context = self._impl.getImplicitContext()
|
|
391
395
|
if context is None:
|
|
@@ -395,24 +399,24 @@ class Communicator:
|
|
|
395
399
|
|
|
396
400
|
def getProperties(self) -> Properties:
|
|
397
401
|
"""
|
|
398
|
-
|
|
402
|
+
Gets the properties of this communicator.
|
|
399
403
|
|
|
400
404
|
Returns
|
|
401
405
|
-------
|
|
402
406
|
Properties
|
|
403
|
-
|
|
407
|
+
This communicator's properties.
|
|
404
408
|
"""
|
|
405
409
|
properties = self._impl.getProperties()
|
|
406
410
|
return Properties(properties=properties)
|
|
407
411
|
|
|
408
412
|
def getLogger(self) -> Logger:
|
|
409
413
|
"""
|
|
410
|
-
|
|
414
|
+
Gets the logger of this communicator.
|
|
411
415
|
|
|
412
416
|
Returns
|
|
413
417
|
-------
|
|
414
418
|
Logger
|
|
415
|
-
|
|
419
|
+
This communicator's logger.
|
|
416
420
|
"""
|
|
417
421
|
logger = self._impl.getLogger()
|
|
418
422
|
if isinstance(logger, Logger):
|
|
@@ -422,65 +426,69 @@ class Communicator:
|
|
|
422
426
|
|
|
423
427
|
def getDefaultRouter(self) -> RouterPrx | None:
|
|
424
428
|
"""
|
|
425
|
-
|
|
429
|
+
Gets the default router of this communicator.
|
|
426
430
|
|
|
427
431
|
Returns
|
|
428
432
|
-------
|
|
429
433
|
RouterPrx | None
|
|
430
|
-
The default router
|
|
434
|
+
The default router of this communicator, or ``None`` if no default router has been set.
|
|
435
|
+
|
|
436
|
+
Raises
|
|
437
|
+
------
|
|
438
|
+
CommunicatorDestroyedException
|
|
439
|
+
If the communicator has been destroyed.
|
|
431
440
|
"""
|
|
432
441
|
return self._impl.getDefaultRouter()
|
|
433
442
|
|
|
434
443
|
def setDefaultRouter(self, router: RouterPrx | None):
|
|
435
444
|
"""
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
All newly created proxies will use this default router. To disable the default router, pass `None`.
|
|
439
|
-
Note that this operation has no effect on existing proxies.
|
|
445
|
+
Sets the default router of this communicator. All newly created proxies will use this default router.
|
|
446
|
+
This function has no effect on existing proxies.
|
|
440
447
|
|
|
441
|
-
|
|
442
|
-
|
|
448
|
+
Notes
|
|
449
|
+
-----
|
|
450
|
+
You can set a router for an individual proxy by calling :func:`ObjectPrx.ice_router` on the proxy.
|
|
443
451
|
|
|
444
452
|
Parameters
|
|
445
453
|
----------
|
|
446
454
|
router : RouterPrx | None
|
|
447
|
-
The default router to
|
|
455
|
+
The new default router. Use ``None`` to remove the default router.
|
|
448
456
|
"""
|
|
449
457
|
self._impl.setDefaultRouter(router)
|
|
450
458
|
|
|
451
459
|
def getDefaultLocator(self) -> LocatorPrx | None:
|
|
452
460
|
"""
|
|
453
|
-
|
|
461
|
+
Gets the default locator of this communicator.
|
|
454
462
|
|
|
455
463
|
Returns
|
|
456
464
|
-------
|
|
457
465
|
LocatorPrx | None
|
|
458
|
-
The default locator
|
|
466
|
+
The default locator of this communicator, or ``None`` if no default locator has been set.
|
|
459
467
|
"""
|
|
460
468
|
return self._impl.getDefaultLocator()
|
|
461
469
|
|
|
462
470
|
def setDefaultLocator(self, locator: LocatorPrx | None):
|
|
463
471
|
"""
|
|
464
|
-
|
|
472
|
+
Sets the default locator of this communicator. All newly created proxies will use this default locator.
|
|
473
|
+
This function has no effect on existing proxies or object adapters.
|
|
465
474
|
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
proxy, or for an object adapter by calling `ObjectAdapter.setLocator` on the object adapter.
|
|
475
|
+
Notes
|
|
476
|
+
-----
|
|
477
|
+
You can set a locator for an individual proxy by calling :func:`ObjectPrx.ice_locator` on the proxy,
|
|
478
|
+
or for an object adapter by calling :func:`ObjectAdapter.setLocator` on the object adapter.
|
|
471
479
|
|
|
472
480
|
Parameters
|
|
473
481
|
----------
|
|
474
482
|
locator : LocatorPrx | None
|
|
475
|
-
The default locator to
|
|
483
|
+
The new default locator. Use ``None`` to remove the default locator.
|
|
476
484
|
"""
|
|
477
485
|
self._impl.setDefaultLocator(locator)
|
|
478
486
|
|
|
479
487
|
def flushBatchRequests(self, compress: CompressBatch):
|
|
480
488
|
"""
|
|
481
|
-
|
|
482
|
-
for all connections associated with the communicator.
|
|
483
|
-
ignored.
|
|
489
|
+
Flushes any pending batch requests of this communicator. This means all batch requests invoked on fixed
|
|
490
|
+
proxies for all connections associated with the communicator. Errors that occur while flushing a connection
|
|
491
|
+
are ignored.
|
|
484
492
|
|
|
485
493
|
Parameters
|
|
486
494
|
----------
|
|
@@ -491,30 +499,33 @@ class Communicator:
|
|
|
491
499
|
|
|
492
500
|
def flushBatchRequestsAsync(self, compress: CompressBatch) -> Awaitable[None]:
|
|
493
501
|
"""
|
|
494
|
-
|
|
495
|
-
for all connections associated with the communicator.
|
|
496
|
-
ignored.
|
|
502
|
+
Flushes any pending batch requests of this communicator. This means all batch requests invoked on fixed
|
|
503
|
+
proxies for all connections associated with the communicator. Errors that occur while flushing a connection
|
|
504
|
+
are ignored.
|
|
497
505
|
|
|
498
506
|
Parameters
|
|
499
507
|
----------
|
|
500
508
|
compress : CompressBatch
|
|
501
509
|
Specifies whether or not the queued batch requests should be compressed before being sent over the wire.
|
|
510
|
+
|
|
511
|
+
Returns
|
|
512
|
+
-------
|
|
513
|
+
Awaitable[None]
|
|
514
|
+
An :class:`Awaitable` that completes when all batch requests have been sent.
|
|
502
515
|
"""
|
|
503
516
|
return self._impl.flushBatchRequestsAsync(compress)
|
|
504
517
|
|
|
505
518
|
def createAdmin(self, adminAdapter: ObjectAdapter | None, adminId: Identity) -> ObjectPrx:
|
|
506
519
|
"""
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
Admin's Process facet with the Locator's LocatorRegistry. ``createAdmin`` must only be called once;
|
|
511
|
-
subsequent calls raise `InitializationException`.
|
|
520
|
+
Adds the Admin object with all its facets to the provided object adapter.
|
|
521
|
+
If ``Ice.Admin.ServerId`` is set and the provided object adapter has a :class:`Locator`,
|
|
522
|
+
this function registers the Admin's Process facet with the :class:`Locator`'s :class:`LocatorRegistry`.
|
|
512
523
|
|
|
513
524
|
Parameters
|
|
514
525
|
----------
|
|
515
526
|
adminAdapter : ObjectAdapter | None
|
|
516
|
-
The object adapter used to host the Admin object
|
|
517
|
-
|
|
527
|
+
The object adapter used to host the Admin object; if it is ``None`` and ``Ice.Admin.Endpoints`` is set,
|
|
528
|
+
this function uses the ``Ice.Admin`` object adapter, after creating and activating this adapter.
|
|
518
529
|
adminId : Identity
|
|
519
530
|
The identity of the Admin object.
|
|
520
531
|
|
|
@@ -526,24 +537,29 @@ class Communicator:
|
|
|
526
537
|
Raises
|
|
527
538
|
------
|
|
528
539
|
InitializationException
|
|
529
|
-
If
|
|
540
|
+
If this function is called more than once.
|
|
530
541
|
"""
|
|
531
542
|
return self._impl.createAdmin(adminAdapter, adminId)
|
|
532
543
|
|
|
533
544
|
def getAdmin(self) -> ObjectPrx | None:
|
|
534
545
|
"""
|
|
535
|
-
|
|
546
|
+
Gets a proxy to the main facet of the Admin object.
|
|
536
547
|
|
|
537
|
-
|
|
538
|
-
object if ``Ice.Admin.Endpoints``
|
|
539
|
-
``{value of Ice.Admin.InstanceName}/admin``, or ``{UUID}/admin`` when ``Ice.Admin.InstanceName``
|
|
540
|
-
|
|
541
|
-
|
|
548
|
+
``getAdmin`` also creates the Admin object and creates and activates the ``Ice.Admin`` object adapter to host
|
|
549
|
+
this Admin object if ``Ice.Admin.Endpoints`` is set. The identity of the Admin object created by ``getAdmin``
|
|
550
|
+
is ``{value of Ice.Admin.InstanceName}/admin``, or ``{UUID}/admin`` when ``Ice.Admin.InstanceName`` is not set.
|
|
551
|
+
If ``Ice.Admin.DelayCreation`` is ``0`` or not set, ``getAdmin`` is called by the communicator initialization,
|
|
552
|
+
after initialization of all plugins.
|
|
542
553
|
|
|
543
554
|
Returns
|
|
544
555
|
-------
|
|
545
556
|
ObjectPrx | None
|
|
546
|
-
A proxy to the main ("") facet of the Admin object, or None if no Admin object is configured.
|
|
557
|
+
A proxy to the main ("") facet of the Admin object, or ``None`` if no Admin object is configured.
|
|
558
|
+
|
|
559
|
+
Raises
|
|
560
|
+
------
|
|
561
|
+
CommunicatorDestroyedException
|
|
562
|
+
If the communicator has been destroyed.
|
|
547
563
|
"""
|
|
548
564
|
return self._impl.getAdmin()
|
|
549
565
|
|
|
@@ -551,8 +567,6 @@ class Communicator:
|
|
|
551
567
|
"""
|
|
552
568
|
Adds a new facet to the Admin object.
|
|
553
569
|
|
|
554
|
-
This method adds a new servant implementing the specified Admin facet.
|
|
555
|
-
|
|
556
570
|
Parameters
|
|
557
571
|
----------
|
|
558
572
|
servant : Object
|
|
@@ -563,36 +577,34 @@ class Communicator:
|
|
|
563
577
|
Raises
|
|
564
578
|
------
|
|
565
579
|
AlreadyRegisteredException
|
|
566
|
-
If
|
|
580
|
+
If a facet with the same name is already registered.
|
|
567
581
|
"""
|
|
568
582
|
self._impl.addAdminFacet(servant, facet)
|
|
569
583
|
|
|
570
584
|
def removeAdminFacet(self, facet: str) -> Object:
|
|
571
585
|
"""
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
Removing a facet that was not previously registered throws a NotRegisteredException.
|
|
586
|
+
Removes a facet from the Admin object.
|
|
575
587
|
|
|
576
588
|
Parameters
|
|
577
589
|
----------
|
|
578
590
|
facet : str
|
|
579
|
-
The name of the Admin facet
|
|
591
|
+
The name of the Admin facet.
|
|
580
592
|
|
|
581
593
|
Returns
|
|
582
594
|
-------
|
|
583
595
|
Object
|
|
584
|
-
The servant associated with
|
|
596
|
+
The servant associated with this Admin facet.
|
|
585
597
|
|
|
586
598
|
Raises
|
|
587
599
|
------
|
|
588
600
|
NotRegisteredException
|
|
589
|
-
If
|
|
601
|
+
If no facet with the given name is registered.
|
|
590
602
|
"""
|
|
591
603
|
return self._impl.removeAdminFacet(facet)
|
|
592
604
|
|
|
593
605
|
def findAdminFacet(self, facet: str) -> Object | None:
|
|
594
606
|
"""
|
|
595
|
-
|
|
607
|
+
Returns a facet of the Admin object.
|
|
596
608
|
|
|
597
609
|
Parameters
|
|
598
610
|
----------
|
|
@@ -602,18 +614,18 @@ class Communicator:
|
|
|
602
614
|
Returns
|
|
603
615
|
-------
|
|
604
616
|
Object | None
|
|
605
|
-
The servant associated with
|
|
617
|
+
The servant associated with this Admin facet, or ``None`` if no facet is registered with the given name.
|
|
606
618
|
"""
|
|
607
619
|
return self._impl.findAdminFacet(facet)
|
|
608
620
|
|
|
609
621
|
def findAllAdminFacets(self) -> dict[str, Object]:
|
|
610
622
|
"""
|
|
611
|
-
|
|
623
|
+
Returns a map of all facets of the Admin object.
|
|
612
624
|
|
|
613
625
|
Returns
|
|
614
626
|
-------
|
|
615
627
|
dict[str, Object]
|
|
616
|
-
A
|
|
628
|
+
A collection containing all the facet names and servants of the Admin object.
|
|
617
629
|
"""
|
|
618
630
|
return self._impl.findAllAdminFacets()
|
|
619
631
|
|
Ice/CompressBatch.py
CHANGED
|
@@ -6,20 +6,20 @@ from enum import Enum
|
|
|
6
6
|
|
|
7
7
|
class CompressBatch(Enum):
|
|
8
8
|
"""
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
Enumerators:
|
|
12
|
-
|
|
13
|
-
- Yes:
|
|
14
|
-
Compress the batch requests.
|
|
15
|
-
|
|
16
|
-
- No:
|
|
17
|
-
Don't compress the batch requests.
|
|
18
|
-
|
|
19
|
-
- BasedOnProxy:
|
|
20
|
-
Compress the batch requests if at least one request was made on a compressed proxy.
|
|
9
|
+
Represents batch compression options for flushing queued batch requests.
|
|
21
10
|
"""
|
|
22
11
|
|
|
23
12
|
Yes = 0
|
|
13
|
+
"""
|
|
14
|
+
Compress the batch requests.
|
|
15
|
+
"""
|
|
16
|
+
|
|
24
17
|
No = 1
|
|
18
|
+
"""
|
|
19
|
+
Don't compress the batch requests.
|
|
20
|
+
"""
|
|
21
|
+
|
|
25
22
|
BasedOnProxy = 2
|
|
23
|
+
"""
|
|
24
|
+
Compress the batch requests if at least one request was made on a compressed proxy.
|
|
25
|
+
"""
|