zeroc-ice 3.8.0__cp313-cp313-win_amd64.whl → 3.8.0.post1__cp313-cp313-win_amd64.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.cp313-win_amd64.pdb +0 -0
- IcePy.cp313-win_amd64.pyd +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 +54 -54
- {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/InitializationData.py
CHANGED
|
@@ -8,9 +8,8 @@ from typing import TYPE_CHECKING
|
|
|
8
8
|
if TYPE_CHECKING:
|
|
9
9
|
from collections.abc import Callable
|
|
10
10
|
|
|
11
|
-
from IcePy import BatchRequest, Connection
|
|
12
|
-
|
|
13
11
|
from .EventLoopAdapter import EventLoopAdapter
|
|
12
|
+
from .IcePyTypes import BatchRequest, Connection
|
|
14
13
|
from .Logger import Logger
|
|
15
14
|
from .Properties import Properties
|
|
16
15
|
from .UserException import UserException
|
|
@@ -20,35 +19,37 @@ if TYPE_CHECKING:
|
|
|
20
19
|
@dataclass
|
|
21
20
|
class InitializationData:
|
|
22
21
|
"""
|
|
23
|
-
|
|
22
|
+
Represents a set of options that you can specify when initializing a communicator.
|
|
24
23
|
|
|
25
24
|
Attributes
|
|
26
25
|
----------
|
|
27
26
|
properties : Ice.Properties | None
|
|
28
|
-
The properties
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
The properties for the communicator.
|
|
28
|
+
If not ``None``, this corresponds to the object returned by the :func:`Communicator.getProperties` function.
|
|
29
|
+
logger : Ice.Logger | None
|
|
30
|
+
The logger for the communicator.
|
|
31
31
|
threadStart : Callable[[], None] | None
|
|
32
|
-
A
|
|
32
|
+
A :class:`Callable` that is invoked whenever the communicator starts a new thread.
|
|
33
33
|
threadStop : Callable[[], None] | None
|
|
34
|
-
A
|
|
34
|
+
A :class:`Callable` that is invoked whenever a thread created by the communicator is about to be destroyed.
|
|
35
35
|
executor : Callable[[Callable[[], None], Connection], None] | None
|
|
36
|
-
A
|
|
37
|
-
receives two arguments: a callable and an Ice.Connection object.
|
|
38
|
-
eventually invoke the callable with no arguments.
|
|
39
|
-
batchRequestInterceptor : Callable[[BatchRequest, int, int], None] | None
|
|
40
|
-
A
|
|
41
|
-
three arguments: a BatchRequest object, an integer representing the number of requests
|
|
42
|
-
in the queue, and an integer representing the number of bytes consumed by the requests
|
|
43
|
-
|
|
36
|
+
A :class:`Callable` that the communicator invokes to execute dispatches and async invocation callbacks.
|
|
37
|
+
The callable receives two arguments: a callable and an Ice.Connection object.
|
|
38
|
+
The executor must eventually invoke the callable with no arguments.
|
|
39
|
+
batchRequestInterceptor : Callable[[Ice.BatchRequest, int, int], None] | None
|
|
40
|
+
A :class:`Callable` that is invoked by the Ice runtime to enqueue a batch request.
|
|
41
|
+
The callable receives three arguments: a BatchRequest object, an integer representing the number of requests
|
|
42
|
+
currently in the queue, and an integer representing the number of bytes consumed by the requests in the queue.
|
|
43
|
+
The interceptor must eventually invoke the enqueue function on the BatchRequest object.
|
|
44
44
|
eventLoopAdapter : Ice.EventLoopAdapter | None
|
|
45
|
-
An event loop adapter used to run coroutines and wrap futures. If provided
|
|
46
|
-
executing coroutines returned by Ice asynchronous dispatch
|
|
45
|
+
An event loop adapter used to run coroutines and wrap futures. If provided, this adapter is responsible for
|
|
46
|
+
executing coroutines returned by Ice asynchronous dispatch functions and for wrapping Ice futures (from Ice
|
|
47
47
|
Async APIs) into futures that can be awaited in the application's event loop.
|
|
48
|
-
sliceLoader : Callable[[str], Value | UserException | None] | None
|
|
49
|
-
A
|
|
50
|
-
|
|
51
|
-
ID
|
|
48
|
+
sliceLoader : Callable[[str], Ice.Value | Ice.UserException | None] | None
|
|
49
|
+
A :class:`Callable` used to create instances of Slice classes and user exceptions.
|
|
50
|
+
Applications can supply a custom slice loader that the Ice runtime will use during unmarshaling.
|
|
51
|
+
The callable receives one argument: a type ID or compact type ID (as a string) and returns a new instance of the
|
|
52
|
+
corresponding class or exception, or ``None`` if no such class or exception could be found.
|
|
52
53
|
"""
|
|
53
54
|
|
|
54
55
|
properties: Properties | None = None
|
Ice/InvocationFuture.py
CHANGED
|
@@ -13,12 +13,13 @@ class InvocationFuture(Future):
|
|
|
13
13
|
"""
|
|
14
14
|
A Future object representing the result of an AMI (Asynchronous Method Invocation) request.
|
|
15
15
|
|
|
16
|
-
InvocationFuture
|
|
17
|
-
|
|
18
|
-
available.
|
|
16
|
+
Instances of ``InvocationFuture`` are returned by AMI requests, and applications can either wait for the result
|
|
17
|
+
of the request to become available, or register a callback which will be invoked when the result becomes available.
|
|
19
18
|
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
Notes
|
|
20
|
+
-----
|
|
21
|
+
This class provides the same functionality as :class:`Ice.Future` with the addition of "sent callbacks";
|
|
22
|
+
callbacks which are invoked when the request has been sent.
|
|
22
23
|
"""
|
|
23
24
|
|
|
24
25
|
def __init__(self, asyncInvocationContext: IcePy.AsyncInvocationContext):
|
|
@@ -33,16 +34,18 @@ class InvocationFuture(Future):
|
|
|
33
34
|
"""
|
|
34
35
|
Cancels the invocation.
|
|
35
36
|
|
|
36
|
-
This
|
|
37
|
-
successful, the associated invocation is also cancelled.
|
|
37
|
+
This function invokes :func:`Future.cancel` to cancel the underlying future.
|
|
38
|
+
If the cancellation is successful, the associated invocation is also cancelled.
|
|
38
39
|
|
|
39
|
-
Cancelling an invocation prevents a queued invocation from being sent.
|
|
40
|
-
cancellation ensures that any reply from the server is ignored.
|
|
40
|
+
Cancelling an invocation prevents a queued invocation from being sent.
|
|
41
|
+
If the invocation has already been sent, cancellation ensures that any reply from the server is ignored.
|
|
41
42
|
|
|
42
|
-
|
|
43
|
+
After cancellation, :func:`done` returns ``True``, and attempting to retrieve the result raises an
|
|
44
|
+
:class:`Ice.InvocationCanceledException`.
|
|
43
45
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
+
Notes
|
|
47
|
+
-----
|
|
48
|
+
Cancellation is a local operation with no effect on the server.
|
|
46
49
|
|
|
47
50
|
Returns
|
|
48
51
|
-------
|
|
@@ -56,40 +59,38 @@ class InvocationFuture(Future):
|
|
|
56
59
|
|
|
57
60
|
def is_sent(self) -> bool:
|
|
58
61
|
"""
|
|
59
|
-
|
|
62
|
+
Checks if the request has been sent.
|
|
60
63
|
|
|
61
64
|
Returns
|
|
62
65
|
-------
|
|
63
66
|
bool
|
|
64
|
-
True if the request has been sent, otherwise False
|
|
67
|
+
``True`` if the request has been sent, otherwise ``False``.
|
|
65
68
|
"""
|
|
66
69
|
with self._condition:
|
|
67
70
|
return self._sent
|
|
68
71
|
|
|
69
72
|
def is_sent_synchronously(self) -> bool:
|
|
70
73
|
"""
|
|
71
|
-
|
|
74
|
+
Checks if the request was sent synchronously.
|
|
72
75
|
|
|
73
76
|
Returns
|
|
74
77
|
-------
|
|
75
78
|
bool
|
|
76
|
-
True if the request was sent synchronously, otherwise False
|
|
79
|
+
``True`` if the request was sent synchronously, otherwise ``False``.
|
|
77
80
|
"""
|
|
78
81
|
with self._condition:
|
|
79
82
|
return self._sentSynchronously
|
|
80
83
|
|
|
81
84
|
def add_sent_callback(self, fn: Callable[[bool], None]) -> None:
|
|
82
85
|
"""
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
The callback `fn` is called with a boolean argument, indicating whether the invocation was sent synchronously.
|
|
86
|
-
|
|
87
|
-
If the future has already been sent, `fn` is called immediately from the calling thread.
|
|
86
|
+
Attaches a callback function which will be called when the invocation is sent.
|
|
87
|
+
If the invocation has already been sent, ``fn`` is called immediately from the calling thread.
|
|
88
88
|
|
|
89
89
|
Parameters
|
|
90
90
|
----------
|
|
91
|
-
fn : Callable
|
|
91
|
+
fn : Callable[[bool], None]
|
|
92
92
|
The function to execute when the invocation is sent.
|
|
93
|
+
It accepts a single boolean argument which is only ``True`` if the invocation was sent synchronously.
|
|
93
94
|
"""
|
|
94
95
|
with self._condition:
|
|
95
96
|
if not self._sent:
|
|
@@ -99,31 +100,27 @@ class InvocationFuture(Future):
|
|
|
99
100
|
|
|
100
101
|
def sent(self, timeout: int | float | None = None) -> bool:
|
|
101
102
|
"""
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
This method waits up to `timeout` seconds for the operation to be sent and then returns
|
|
105
|
-
whether it was sent synchronously.
|
|
103
|
+
Waits until the invocation has been sent.
|
|
106
104
|
|
|
107
|
-
If the
|
|
108
|
-
If the future was cancelled before being sent, an `InvocationCanceledException` is raised.
|
|
105
|
+
If the invocation has not been sent, this function will wait up to ``timeout``-many seconds for it to send.
|
|
109
106
|
|
|
110
107
|
Parameters
|
|
111
108
|
----------
|
|
112
|
-
timeout : int | float, optional
|
|
113
|
-
Maximum time (in seconds) to wait for the
|
|
114
|
-
indefinitely.
|
|
109
|
+
timeout : int | float | None, optional
|
|
110
|
+
Maximum time (in seconds) to wait for the invocation to be sent.
|
|
111
|
+
If ``None`` (the default), this function waits indefinitely.
|
|
115
112
|
|
|
116
113
|
Returns
|
|
117
114
|
-------
|
|
118
115
|
bool
|
|
119
|
-
True if the
|
|
116
|
+
``True`` if the invocation was sent synchronously, otherwise ``False``.
|
|
120
117
|
|
|
121
118
|
Raises
|
|
122
119
|
------
|
|
123
120
|
TimeoutException
|
|
124
|
-
If the
|
|
121
|
+
If the invocation was not sent within the specified timeout.
|
|
125
122
|
InvocationCanceledException
|
|
126
|
-
If the
|
|
123
|
+
If the invocation was cancelled before it was sent.
|
|
127
124
|
"""
|
|
128
125
|
with self._condition:
|
|
129
126
|
if not self._wait(timeout, lambda: not self._sent):
|