Module: Higan::Configuration::ClassMethods

Defined in:
lib/higan/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#basicObject

Returns the value of attribute basic.



4
5
6
# File 'lib/higan/configuration.rb', line 4

def basic
  @basic
end

#element_storeObject

Returns the value of attribute element_store.



4
5
6
# File 'lib/higan/configuration.rb', line 4

def element_store
  @element_store
end

#ftp_storeObject

Returns the value of attribute ftp_store.



4
5
6
# File 'lib/higan/configuration.rb', line 4

def ftp_store
  @ftp_store
end

#local_storeObject

Returns the value of attribute local_store.



4
5
6
# File 'lib/higan/configuration.rb', line 4

def local_store
  @local_store
end

Instance Method Details

#add_element(name, &block) ⇒ Object



18
19
20
# File 'lib/higan/configuration.rb', line 18

def add_element(name, &block)
  element_store[name] = Target.new(TargetReceiver.out(&block))
end

#add_ftp(name, &block) ⇒ Object



10
11
12
# File 'lib/higan/configuration.rb', line 10

def add_ftp(name, &block)
  ftp_store[name] = Remote.new(FtpReceiver.out(&block))
end

#base(&block) ⇒ Object



14
15
16
# File 'lib/higan/configuration.rb', line 14

def base(&block)
  self.basic = BaseReceiver.out(&block)
end

#configure(&block) ⇒ Object



6
7
8
# File 'lib/higan/configuration.rb', line 6

def configure(&block)
  instance_eval(&block) if block_given?
end

#inspectObject



22
23
24
25
26
27
28
29
# File 'lib/higan/configuration.rb', line 22

def inspect
  {
    basic: basic,
    ftp: ftp_store,
    local: local_store,
    element: element_store
  }
end