You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Pavel Tupitsyn (JIRA)" <ji...@apache.org> on 2017/04/06 11:21:41 UTC

[jira] [Updated] (IGNITE-1894) .NET: Delegate support in the API via extension methods

     [ https://issues.apache.org/jira/browse/IGNITE-1894?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pavel Tupitsyn updated IGNITE-1894:
-----------------------------------
    Fix Version/s:     (was: 2.0)
                   2.1

> .NET: Delegate support in the API via extension methods
> -------------------------------------------------------
>
>                 Key: IGNITE-1894
>                 URL: https://issues.apache.org/jira/browse/IGNITE-1894
>             Project: Ignite
>          Issue Type: Improvement
>          Components: platforms
>    Affects Versions: 1.1.4
>            Reporter: Pavel Tupitsyn
>            Priority: Minor
>              Labels: .net
>             Fix For: 2.1
>
>
> In many places we require a single-method interface implementation from the user:
> {code:title=ICompute}
> TRes Call<TRes>(IComputeFunc<TRes> clo);
> {code}
> All of these can be extended to accept a delegate:
> {code:title=ICompute}
> TRes Call<TRes>(Func<TRes> clo);
> {code}
> We can't replace interfaces with delegates completely (which is desirable), because it will take away serialization control from the user. So the interface approach has to stay as a primary.
> Delegate support can be added via extension methods, which wrap provided delegates into a class that implements corresponding interface.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)