Module: ModuleCluster::CascadeFeatures::ClusterStack

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.cluster_stack(class_or_module) ⇒ Object

self.cluster_stack #



18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'lib/module-cluster/_private_/ModuleCluster/CascadeFeatures/ClusterStack.rb', line 18

def self.cluster_stack( class_or_module )
  
  cluster_stack_for_class_or_module = nil
  
  unless cluster_stack_for_class_or_module = cluster_stacks[ class_or_module ]
    
    cluster_stack_for_class_or_module = ::ModuleCluster::ClusterStack.new
    
    cluster_stacks[ class_or_module ] = cluster_stack_for_class_or_module
    
  end

  return cluster_stack_for_class_or_module
   
end

.cluster_stacksObject

self.cluster_stacks #



8
9
10
11
12
# File 'lib/module-cluster/_private_/ModuleCluster/CascadeFeatures/ClusterStack.rb', line 8

def self.cluster_stacks
  
  return @cluster_stacks ||= Hash.new
  
end

Instance Method Details

#cluster_stackObject

cluster_stack #



38
39
40
41
42
# File 'lib/module-cluster/_private_/ModuleCluster/CascadeFeatures/ClusterStack.rb', line 38

def cluster_stack
  
  return ::ModuleCluster::CascadeFeatures::ClusterStack.cluster_stack( self )
   
end