VContainer icon indicating copy to clipboard operation
VContainer copied to clipboard

Add API to define the execution order of player loop timings.

Open 4nonym0us opened this issue 3 years ago • 3 comments

Implements #271

4nonym0us avatar Jul 22 '21 18:07 4nonym0us

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/hadashia/vcontainer/7E8J3Nm4D4dYyzxmdn3LGqTWZq9k
✅ Preview: https://vcontainer-git-fork-4nonym0us-master-hadashia.vercel.app

vercel[bot] avatar Jul 22 '21 18:07 vercel[bot]

The ExecutionOrder feature may need to be considered.

However, I was not satisfied with this pull request.

  1. I think that the ExecutionOrder setting is a concern of the application layer. I don't want to bring this into the DI configuration too much.
  2. I think ExecutionOrder has no effect on anything other than EntryPoint, so adding this feature to IRegistration seems excessive.

hadashiA avatar Aug 26 '21 03:08 hadashiA

It's just a sample draft to start the discussion and find out whether you are interested in the feature at all. I aggree that using IRegistration to store execution order is an overkill.

  • What do you think about creating new extension method(s) for ContainerBuilder, which allow to explicitly set execution order of specific type?
  • Another option would be to modify signature of RegisterEntryPoint methods to include execution order, but this approach will pollute registration API.
  • Some DI containers use C# attributes to configure execution order in a declarative way, but this approach is worse performance-wise.

4nonym0us avatar Aug 27 '21 10:08 4nonym0us

Sorry, but we could not adopt this specification and would like to close this case.

hadashiA avatar Dec 18 '23 10:12 hadashiA