Class: UnimatrixCLI::Cartographer::Region::CreateCommand
- Inherits:
-
UnimatrixCLI::Command
- Object
- UnimatrixCLI::Command
- UnimatrixCLI::Cartographer::Region::CreateCommand
- Defined in:
- lib/unimatrix_cli/cartographer/region/create_command.rb
Instance Method Summary collapse
Methods inherited from UnimatrixCLI::Command
available_commands, descendants, #initialize, #read_file, #validate, #validate_collection, #write
Methods included from UnimatrixParser
Constructor Details
This class inherits a constructor from UnimatrixCLI::Command
Instance Method Details
#execute ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/unimatrix_cli/cartographer/region/create_command.rb', line 11 def execute region = create_region if validate( region, 'Cartographer::Region' ) write( message: "Region id: #{ region.id }" ) else write( message: "Error creating region: #{ region.inspect }", error: true ) end end |