-
how define trait for a arbitary struct as actix handler for use in app route and service |
Beta Was this translation helpful? Give feedback.
Answered by
robjtede
Feb 3, 2021
Replies: 1 comment
-
The closest you can do is implementing Admittedly, the docs are scarce for this trait so I recommend looking at the docs for |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
robjtede
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The closest you can do is implementing
HttpServiceFactory
for use in{App, Scope, Resource}::service
.Admittedly, the docs are scarce for this trait so I recommend looking at the docs for
AppService
and implementations for Resource and Scope for some guidance.