[External] : Re: Synchronous executor interface
Attila Kelemen
attila.kelemen85 at gmail.com
Fri Aug 11 18:23:56 UTC 2023
To elaborate more, your executor can be created for any type, but that is
almost pointless for an executor, because an executor instance has to
support all types. Similarly you can't create a simplified
`ExecutorService` as `Function<Callable<T>, Future<T>>`. Such an executor
would be very limited in usefulness, because to simply put: An executor
cannot have a type argument.
Attila Kelemen <attila.kelemen85 at gmail.com> ezt írta (időpont: 2023. aug.
11., P, 20:16):
>
> It isn’t. I think you need to think about this some more.
>>
>>
>>
> Ok, then how do you implement what I wrote with functions and similar? It
> is impossible, because the executor can't know "T", it is a private detail
> to its user of the executor, and not only that but it can be different
> everywhere. For you it works, because your "executor" after instantiated
> only supports strings.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/loom-dev/attachments/20230811/036d2520/attachment.htm>
More information about the loom-dev
mailing list