Class: Castkit::CLI::List
- Inherits:
-
Thor
- Object
- Thor
- Castkit::CLI::List
- Defined in:
- lib/castkit/cli/list.rb
Overview
CLI commands for listing internal Castkit registry components.
Supports listing:
-
Registered types (‘castkit list types`)
-
Available validators (‘castkit list validators`)
Instance Method Summary collapse
-
#contracts ⇒ void
Lists all Castkit contract classes defined in the file system or registered under the Castkit namespace.
-
#dataobjects ⇒ void
Lists all Castkit DataObjects classes defined in the file system or registered under the Castkit namespace.
-
#serializers ⇒ void
Lists all Castkit serializers classes defined in the file system or registered under the Castkit namespace.
-
#types ⇒ void
Lists registered Castkit types, grouped into native and custom-defined.
-
#validators ⇒ void
Lists all Castkit validator classes defined in the file system or registered under the Castkit namespace.
Instance Method Details
#contracts ⇒ void
This method returns an undefined value.
Lists all Castkit contract classes defined in the file system or registered under the Castkit namespace.
42 43 44 |
# File 'lib/castkit/cli/list.rb', line 42 def contracts list_files("contracts") end |
#dataobjects ⇒ void
This method returns an undefined value.
Lists all Castkit DataObjects classes defined in the file system or registered under the Castkit namespace.
50 51 52 |
# File 'lib/castkit/cli/list.rb', line 50 def dataobjects list_files("data_objects") end |
#serializers ⇒ void
This method returns an undefined value.
Lists all Castkit serializers classes defined in the file system or registered under the Castkit namespace.
58 59 60 |
# File 'lib/castkit/cli/list.rb', line 58 def serializers list_files("serializers") end |
#types ⇒ void
This method returns an undefined value.
Lists registered Castkit types, grouped into native and custom-defined.
30 31 32 33 34 35 36 |
# File 'lib/castkit/cli/list.rb', line 30 def types all_keys = Castkit.configuration.types default_keys = Castkit::Configuration::DEFAULT_TYPES.keys native_types(all_keys, default_keys) custom_types(all_keys, default_keys) end |
#validators ⇒ void
This method returns an undefined value.
Lists all Castkit validator classes defined in the file system or registered under the Castkit namespace.
66 67 68 |
# File 'lib/castkit/cli/list.rb', line 66 def validators list_files("validators") end |