Module: Nest::ClassMethods

Defined in:
lib/nest.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#mount_pointObject (readonly)

Returns the value of attribute mount_point.



11
12
13
# File 'lib/nest.rb', line 11

def mount_point
  @mount_point
end

Instance Method Details

#mount(path) ⇒ Object



13
14
15
16
# File 'lib/nest.rb', line 13

def mount( path )
  @mount_point = path
  raise "invalid path" unless valid?
end

#rootObject



22
23
24
# File 'lib/nest.rb', line 22

def root
  new '/'
end

#valid?Boolean

Returns:

  • (Boolean)


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

def valid?
  root.valid?
end