{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet-state-machine/stateless/issues/77","repository_url":"https://api.github.com/repos/dotnet-state-machine/stateless","labels_url":"https://api.github.com/repos/dotnet-state-machine/stateless/issues/77/labels{/name}","comments_url":"https://api.github.com/repos/dotnet-state-machine/stateless/issues/77/comments","events_url":"https://api.github.com/repos/dotnet-state-machine/stateless/issues/77/events","html_url":"https://github.com/dotnet-state-machine/stateless/issues/77","id":177005434,"number":77,"title":"Add support for do-Activities","user":{"login":"heltonbiker","id":683725,"avatar_url":"https://avatars.githubusercontent.com/u/683725?v=3","gravatar_id":"","url":"https://api.github.com/users/heltonbiker","html_url":"https://github.com/heltonbiker","followers_url":"https://api.github.com/users/heltonbiker/followers","following_url":"https://api.github.com/users/heltonbiker/following{/other_user}","gists_url":"https://api.github.com/users/heltonbiker/gists{/gist_id}","starred_url":"https://api.github.com/users/heltonbiker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/heltonbiker/subscriptions","organizations_url":"https://api.github.com/users/heltonbiker/orgs","repos_url":"https://api.github.com/users/heltonbiker/repos","events_url":"https://api.github.com/users/heltonbiker/events{/privacy}","received_events_url":"https://api.github.com/users/heltonbiker/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-09-14T20:00:20Z","updated_at":"2016-09-14T22:28:03Z","closed_at":null,"body":"Some FSM models consider the existence of a `do-Activity`, that is, a process that keeps running while the machine is in a given state, such as a `Thread` or a `Task`.\r\n\r\nA suggested \"API\" would be, say:\r\n\r\n<pre>\r\n     _phone.Configure(State.Ringing)\r\n        <b>.Do(_phone.RingingTask)</b>\r\n        .Permit(Trigger.HungUp, State.OffHook)\r\n        .Permit(Trigger.CallConnected, State.Connected);\r\n</pre>\r\n\r\nIs there such feature, currently? Is this a planned feature? If not, would there be the intention to add it?"},"comment":{"url":"https://api.github.com/repos/dotnet-state-machine/stateless/issues/comments/247176640","html_url":"https://github.com/dotnet-state-machine/stateless/issues/77#issuecomment-247176640","issue_url":"https://api.github.com/repos/dotnet-state-machine/stateless/issues/77","id":247176640,"user":{"login":"nblumhardt","id":342712,"avatar_url":"https://avatars.githubusercontent.com/u/342712?v=3","gravatar_id":"","url":"https://api.github.com/users/nblumhardt","html_url":"https://github.com/nblumhardt","followers_url":"https://api.github.com/users/nblumhardt/followers","following_url":"https://api.github.com/users/nblumhardt/following{/other_user}","gists_url":"https://api.github.com/users/nblumhardt/gists{/gist_id}","starred_url":"https://api.github.com/users/nblumhardt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nblumhardt/subscriptions","organizations_url":"https://api.github.com/users/nblumhardt/orgs","repos_url":"https://api.github.com/users/nblumhardt/repos","events_url":"https://api.github.com/users/nblumhardt/events{/privacy}","received_events_url":"https://api.github.com/users/nblumhardt/received_events","type":"User","site_admin":false},"created_at":"2016-09-14T22:28:03Z","updated_at":"2016-09-14T22:28:03Z","body":"Hey, very interesting idea! No, there's nothing direct: `OnEntry()` could call an async method passinga `CancellationToken` and `OnExit()` could cancel it/`Wait()` for the task, but I imagine it's a bit more subtle than that to get working smoothly.\r\n\r\nIs it possible to build as an extension atop the existing API? That would probably make a good litmus test for how aligned it is with the current design of the library.\r\n\r\nAlso, do you have a scenario you're keen to apply this in presently, or just investigating the idea (which is neat, regardless)?\r\n\r\nCheers,\r\nNick"}}
{"actor":{"display_login":"nblumhardt"}}