Class: SqlFootprint::FootprintSerializer

Inherits:
Object
  • Object
show all
Defined in:
lib/sql_footprint/footprint_serializer.rb

Constant Summary collapse

NEWLINE =
"\n".freeze

Instance Method Summary collapse

Constructor Details

#initialize(statements) ⇒ FootprintSerializer

Returns a new instance of FootprintSerializer.



5
6
7
# File 'lib/sql_footprint/footprint_serializer.rb', line 5

def initialize statements
  @statements = statements
end

Instance Method Details

#to_sObject



9
10
11
# File 'lib/sql_footprint/footprint_serializer.rb', line 9

def to_s
  @statements.sort.join(NEWLINE) + NEWLINE
end