Class: TrackBlock

Inherits:
TrackBlockOrigin show all
Defined in:
lib/ting_model/track_block.rb

Constant Summary

Constants inherited from TrackBlockOrigin

TrackBlockOrigin::MIN_SECONDS_PER_BLOCK, TrackBlockOrigin::TRACK_MAX_BLOCKS

Class Method Summary collapse

Methods inherited from TrackBlockOrigin

#get_block_idx_by_second, #increase_by_second

Methods included from TrackBlockExtender

#next_id

Class Method Details

.gtn(key) ⇒ Object



10
11
12
# File 'lib/ting_model/track_block.rb', line 10

def self.gtn(key)
  TrackBlockNode.seek(key).table_name
end

.shard(key) ⇒ Object



6
7
8
# File 'lib/ting_model/track_block.rb', line 6

def self.shard(key)
  Object.const_get(TrackBlockNode.seek(key).class_name)
end

.stn(key) ⇒ Object



14
15
16
17
# File 'lib/ting_model/track_block.rb', line 14

def self.stn(key)
  self.table_name = self.gtn(key)
  self
end