Class: Cue

Inherits:
Object
  • Object
show all
Defined in:
lib/subtitle-library/cue.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(start, ending, text) ⇒ Cue

Returns a new instance of Cue.



4
5
6
7
8
# File 'lib/subtitle-library/cue.rb', line 4

def initialize(start, ending, text)
  @start = start
  @ending = ending
  @text = text
end

Instance Attribute Details

#endingObject

Returns the value of attribute ending.



2
3
4
# File 'lib/subtitle-library/cue.rb', line 2

def ending
  @ending
end

#startObject

Returns the value of attribute start.



2
3
4
# File 'lib/subtitle-library/cue.rb', line 2

def start
  @start
end

#textObject

Returns the value of attribute text.



2
3
4
# File 'lib/subtitle-library/cue.rb', line 2

def text
  @text
end

Instance Method Details

#==(other_cue) ⇒ Object



10
11
12
13
14
# File 'lib/subtitle-library/cue.rb', line 10

def ==(other_cue)
  @start == other_cue.start and
    @ending == other_cue.ending and
      @text == other_cue.text
end