Module: RIO::Ext::Mp3Info

Extended by:
Fwd
Included in:
Ops::File::Existing
Defined in:
lib/rio/ext/mp3info.rb

Instance Method Summary collapse

Methods included from Fwd

fwd, fwd_reader, fwd_readers, fwd_writer, fwd_writers

Instance Method Details

#album ⇒ Object



39
# File 'lib/rio/ext/mp3info.rb', line 39

def album() _chop0(tag.album) end

#artist ⇒ Object



40
# File 'lib/rio/ext/mp3info.rb', line 40

def artist() _chop0(tag.artist) end

#mp3info ⇒ Object



31
# File 'lib/rio/ext/mp3info.rb', line 31

def mp3info() ::Mp3Info.new(self.fspath) end

#mp3length ⇒ Object



42
# File 'lib/rio/ext/mp3info.rb', line 42

def mp3length() mp3info.length end

#time ⇒ Object



45
46
47
48
# File 'lib/rio/ext/mp3info.rb', line 45

def time() 
  t = Time.at(mp3length).getutc
  t.strftime(t.hour == 0 ? "%M:%S" : "%H:%M:%S") 
end

#title ⇒ Object



38
# File 'lib/rio/ext/mp3info.rb', line 38

def title() _chop0(tag.title) end

#vbr ⇒ Object Also known as: vbr?



43
# File 'lib/rio/ext/mp3info.rb', line 43

def vbr() mp3info.vbr end

#year ⇒ Object



41
# File 'lib/rio/ext/mp3info.rb', line 41

def year() _chop0(tag.year.to_s) end