Class: RailsGraph::Graph::Nodes::Database

Inherits:
RailsGraph::Graph::Node show all
Defined in:
lib/rails_graph/graph/nodes/database.rb

Instance Attribute Summary collapse

Attributes inherited from RailsGraph::Graph::Node

#labels

Attributes inherited from Entity

#id, #name, #properties

Instance Method Summary collapse

Methods inherited from RailsGraph::Graph::Node

#as_json

Constructor Details

#initialize(configs) ⇒ Database

Returns a new instance of Database.



11
12
13
14
15
# File 'lib/rails_graph/graph/nodes/database.rb', line 11

def initialize(configs)
  @configs = configs

  super(labels: "Database", name: configs.name, properties: build_properties)
end

Instance Attribute Details

#configsObject (readonly)

Returns the value of attribute configs.



9
10
11
# File 'lib/rails_graph/graph/nodes/database.rb', line 9

def configs
  @configs
end

Instance Method Details

#identifierObject



17
18
19
# File 'lib/rails_graph/graph/nodes/database.rb', line 17

def identifier
  "database_#{name}"
end