Module: Belt
- Defined in:
- lib/belt.rb,
lib/belt/version.rb,
lib/belt/action_router.rb,
lib/belt/observability.rb,
lib/belt/lambda_handler.rb,
lib/belt/helpers/response.rb,
lib/belt/helpers/cors_origin.rb,
lib/belt/helpers/error_logging.rb
Defined Under Namespace
Modules: Helpers, LambdaHandler, Observability Classes: ActionNotFound, ActionRouter, AuthenticationError, RecordNotFound
Constant Summary collapse
- VERSION =
'0.0.6'
Class Attribute Summary collapse
-
.controller_paths ⇒ Object
readonly
Returns the value of attribute controller_paths.
Class Method Summary collapse
-
.all_controller_paths ⇒ Object
All controller paths: app-defined + gem-discovered.
-
.all_model_paths ⇒ Object
All gem model paths that exist on disk.
-
.gem_controller_paths ⇒ Object
Auto-discover lambda/controllers dirs in all loaded gems.
-
.gem_model_paths ⇒ Object
Auto-discover lambda/models dirs in all loaded gems.
-
.reset_gem_paths! ⇒ Object
Reset cached paths (useful in tests).
Class Attribute Details
.controller_paths ⇒ Object (readonly)
Returns the value of attribute controller_paths.
17 18 19 |
# File 'lib/belt.rb', line 17 def controller_paths @controller_paths end |
Class Method Details
.all_controller_paths ⇒ Object
All controller paths: app-defined + gem-discovered
30 31 32 |
# File 'lib/belt.rb', line 30 def all_controller_paths controller_paths + gem_controller_paths end |
.all_model_paths ⇒ Object
All gem model paths that exist on disk
35 36 37 |
# File 'lib/belt.rb', line 35 def all_model_paths gem_model_paths end |
.gem_controller_paths ⇒ Object
Auto-discover lambda/controllers dirs in all loaded gems
20 21 22 |
# File 'lib/belt.rb', line 20 def gem_controller_paths @gem_controller_paths ||= discover_gem_paths('lambda/controllers') end |
.gem_model_paths ⇒ Object
Auto-discover lambda/models dirs in all loaded gems
25 26 27 |
# File 'lib/belt.rb', line 25 def gem_model_paths @gem_model_paths ||= discover_gem_paths('lambda/models') end |
.reset_gem_paths! ⇒ Object
Reset cached paths (useful in tests)
40 41 42 43 |
# File 'lib/belt.rb', line 40 def reset_gem_paths! @gem_controller_paths = nil @gem_model_paths = nil end |