Class: Network::Graph

Inherits:
Object
  • Object
show all
Defined in:
app/models/network/graph.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(project, ref, commit, filter_ref) ⇒ Graph

Returns a new instance of Graph


9
10
11
12
13
14
15
16
17
18
19
# File 'app/models/network/graph.rb', line 9

def initialize(project, ref, commit, filter_ref)
  @project = project
  @ref = ref
  @commit = commit
  @filter_ref = filter_ref
  @repo = project.repository

  @commits = collect_commits
  @days = index_commits
  @notes = collect_notes
end

Instance Attribute Details

#commitsObject (readonly)

Returns the value of attribute commits


3
4
5
# File 'app/models/network/graph.rb', line 3

def commits
  @commits
end

#daysObject (readonly)

Returns the value of attribute days


3
4
5
# File 'app/models/network/graph.rb', line 3

def days
  @days
end

#mapObject (readonly)

Returns the value of attribute map


3
4
5
# File 'app/models/network/graph.rb', line 3

def map
  @map
end

#notesObject (readonly)

Returns the value of attribute notes


3
4
5
# File 'app/models/network/graph.rb', line 3

def notes
  @notes
end

#repoObject (readonly)

Returns the value of attribute repo


3
4
5
# File 'app/models/network/graph.rb', line 3

def repo
  @repo
end

Class Method Details

.max_countObject


5
6
7
# File 'app/models/network/graph.rb', line 5

def self.max_count
  @max_count ||= 650
end