Class: ARGFWrapper

Inherits:
Object
  • Object
show all
Defined in:
lib/flv/core_extensions.rb

Instance Method Summary collapse

Instance Method Details

#read(length) ⇒ Object



118
119
120
# File 'lib/flv/core_extensions.rb', line 118

def read(length)
  ARGF.read(length)
end

#read__STRING(length) ⇒ Object



138
139
140
# File 'lib/flv/core_extensions.rb', line 138

def read__STRING(length)
  read length
end

#read__UI16Object



126
127
128
# File 'lib/flv/core_extensions.rb', line 126

def read__UI16
  (readchar << 8) + readchar
end

#read__UI24Object



130
131
132
# File 'lib/flv/core_extensions.rb', line 130

def read__UI24
  (readchar << 16) + (readchar << 8) + readchar
end

#read__UI32Object



134
135
136
# File 'lib/flv/core_extensions.rb', line 134

def read__UI32
  (readchar << 24) + (readchar << 16) + (readchar << 8) + readchar
end

#read__UI8Object



122
123
124
# File 'lib/flv/core_extensions.rb', line 122

def read__UI8
  readchar
end

#readcharObject



114
115
116
# File 'lib/flv/core_extensions.rb', line 114

def readchar
  ARGF.readchar
end