Class: MetaCommit::Contracts::Diff

Inherits:
Object
  • Object
show all
Defined in:
lib/meta_commit_contracts/diff.rb

Overview

Diff contains data from changed element and is responsible for printing structured, user friendly message about change

Constant Summary collapse

TYPE_ADDITION =
:addition
TYPE_DELETION =
:deletion
TYPE_REPLACE =
:replace
SUPPORTS_ALL_PARSERS_WILDCARD =
:*

Instance Method Summary collapse

Instance Method Details

#string_representationString

Returns:

  • (String)


33
34
35
# File 'lib/meta_commit_contracts/diff.rb', line 33

def string_representation

end

#supports_change(type, old_file_name, new_file_name, old_ast_path, new_ast_path) ⇒ Boolean

Parameters:

  • type (Symbol)
  • old_file_name (String)
  • new_file_name (String)
  • []

    old_ast_path

  • []

    new_ast_path

Returns:

  • (Boolean)


23
24
25
# File 'lib/meta_commit_contracts/diff.rb', line 23

def supports_change(type, old_file_name, new_file_name, old_ast_path, new_ast_path)

end

#supports_parser?(parser) ⇒ Boolean

Parameters:

  • parser (Class)

Returns:

  • (Boolean)


13
14
15
# File 'lib/meta_commit_contracts/diff.rb', line 13

def supports_parser?(parser)

end

#to_sString

Returns:

  • (String)


28
29
30
# File 'lib/meta_commit_contracts/diff.rb', line 28

def to_s

end

#type_addition?Boolean

Returns:

  • (Boolean)


38
39
40
# File 'lib/meta_commit_contracts/diff.rb', line 38

def type_addition?

end

#type_deletion?Boolean

Returns:

  • (Boolean)


43
44
45
# File 'lib/meta_commit_contracts/diff.rb', line 43

def type_deletion?

end

#type_replace?Boolean

Returns:

  • (Boolean)


48
49
50
# File 'lib/meta_commit_contracts/diff.rb', line 48

def type_replace?

end