Class: SafeDb::Use

Inherits:
Controller show all
Defined in:
lib/controller/access/use.rb

Overview

The use use case borrowed from the database world denotes which domain will be used for now (and evermore) on the workstation until another use command is issued.

Observable Value

The workstation configuration file will point to the domain name specified marking it as the current and correct domain to use.

Alternative / Error Flows

Error - if the domain name is not listed in the configuration file. Error - if the (dictionary) path to the domain’s base does not exist

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Controller

#check_post_conditions, #check_pre_conditions, #flow, #initialize, #open_remote_backend_location, #post_validation, #read_verse, #set_verse, #update_verse

Constructor Details

This class inherits a constructor from SafeDb::Controller

Instance Attribute Details

#domain_name=(value) ⇒ Object (writeonly)

Sets the attribute domain_name

Parameters:

  • value

    the value to set the attribute domain_name to.



21
22
23
# File 'lib/controller/access/use.rb', line 21

def domain_name=(value)
  @domain_name = value
end

Instance Method Details

#executeObject

The use use case is borrowed from the database world and it denotes the domain to be used for now (and evermore) for this workstation until another use command is issued.

The parameter domain_name must be set after an object instance is acquired but before the execute method runs.



30
31
# File 'lib/controller/access/use.rb', line 30

def execute
end

#pre_validationObject



34
35
# File 'lib/controller/access/use.rb', line 34

def pre_validation
end