kit-organizer edge

Context module
Kit::Organizer::Services::Context
View Source

Handle context operations.


Link to this section Summary ⚠️ Private APIs are currently hidden.

Used instance mixins: Contract::Mixin

Link to this section Class methods 2 ⚠️ Private APIs are currently hidden.

Link to this method

.generate_callable_ctx(callable:, ctx:)

View Source APIPrivate
⚠️ This method is part of a private API. You should avoid using it as it may be removed or be changed in the future. 🗒 Notes:
  • This id done by using introspection on the callable.

Extract needed key from the organizer context to send them to the callable.

Examples:

generate_callable_ctx(callable: ->(a:), { a: 1, b: 2, c: 3 }) => { a: 1 }
generate_callable_ctx(callable: ->(a:, **), { a: 1, b: 2, c: 3 }) => { a: 1, b: 2, c: 3 }
Link to this method

.update_context(ctx:, local_ctx:)

View Source APIPrivate
⚠️ This method is part of a private API. You should avoid using it as it may be removed or be changed in the future. 🗒 Notes:
  • The content of the `:errors` key is merged manually.

Performs a 1 level deep merge on the organizer context.