/* --------------------- db index ------------ */ SQL.Key = function(owner, type, name) { this.owner = owner; this.rows = []; this.type = type || "INDEX"; this.name = name || ""; SQL.Visual.apply(this); } SQL.Key.prototype = Object.create(SQL.Visual.prototype); SQL.Key.prototype.setName = function(n) { this.name = n; } SQL.Key.prototype.getName = function() { return this.name; } SQL.Key.prototype.setType = function(t) { if (!t) { return; } this.type = t; for (var i=0;i\n'; for (var i=0;i\n'; } xml += '\n'; return xml; } SQL.Key.prototype.fromXML = function(node) { this.setType(node.getAttribute("type")); this.setName(node.getAttribute("name")); var parts = node.getElementsByTagName("part"); for (var i=0;i