Class: AppRecord

Inherits:
NetSystem::Record show all
Defined in:
app/net/records/app_record.rb

Direct Known Subclasses

PostRecord, UserRecord

Class Method Summary collapse

Methods inherited from NetSystem::Record

db, inherited

Methods inherited from Liza::Controller

color, inherited, on_connected

Methods inherited from Liza::Unit

const_missing, division, part, system, #system, test_class

Class Method Details

.create_tables!Object



4
5
6
7
8
9
10
11
12
# File 'app/net/records/app_record.rb', line 4

def self.create_tables!
  db.call <<-SQLITE
CREATE TABLE #{get :table} (
id integer,
name text,
text text
);
SQLITE
end

.drop_tables!Object



14
15
16
17
18
# File 'app/net/records/app_record.rb', line 14

def self.drop_tables!
  db.call <<-SQLITE
DROP TABLE #{get :table};
SQLITE
end