// Function from file: dbcore.dm public bool Close( ) { this.item.len = 0; this.columns = null; this.conversions = null; return(DB13.close(this._db_query)); }
public Database_Query(Database query = null, params object[] _) : base(query) { ByTable _args = new ByTable(new object[] { query }).Extend(_); DB13.op(this, 5, (_args.len > 1 ? _args : _args[1])); return; }
public void Add(dynamic query = null, params object[] _) { ByTable _args = new ByTable(new object[] { query }).Extend(_); DB13.op(this, 5, (_args.len > 1 ? _args : _args[1])); return; }
// Function from file: dbcore.dm public ByTable Columns( ) { if (!(this.columns != null)) { this.columns = DB13.columns(this._db_query, typeof(DBColumn)); } return(this.columns); }
// Function from file: dbcore.dm public bool Execute(string sql_query = null, dynamic cursor_handler = null) { sql_query = sql_query ?? this.sql; cursor_handler = cursor_handler ?? this.default_cursor; this.Close(); return(DB13.execute(this._db_query, sql_query, this.db_connection._db_con, cursor_handler, null)); }
// Function from file: dbcore.dm public DBConnection(dynamic dbi_handler = null, dynamic username = null, dynamic password_handler = null, dynamic cursor_handler = null) { this.dbi = dbi_handler; this.user = username; this.password = password_handler; this.default_cursor = cursor_handler; this._db_con = DB13.new_con(); return; }
public dynamic Execute(Database database = null) { if (database != null && !(database is Database)) { database = new Database(database); } this.database = database != null || this.database; return(DB13.op(this, 8, this.database)); }
// Function from file: dbcore.dm public bool IsConnected( ) { bool success = false; if (!GlobalVars.config.sql_enabled) { return(false); } success = DB13.is_connected(this._db_con); return(success); }
// Function from file: dbcore.dm public DBQuery(string sql_query = null, DBConnection connection_handler = null, dynamic cursor_handler = null) { if (Lang13.Bool(sql_query)) { this.sql = sql_query; } if (connection_handler != null) { this.db_connection = connection_handler; } if (Lang13.Bool(cursor_handler)) { this.default_cursor = cursor_handler; } this._db_query = DB13.new_query(); // Warning: Super call was HERE! If anything above HERE is needed by the super call, it might break!; return; }
// Function from file: dbcore.dm public bool Connect(string dbi_handler = null, string user_handler = null, string password_handler = null, bool?cursor_handler = null) { dbi_handler = dbi_handler ?? this.dbi; user_handler = user_handler ?? this.user; password_handler = password_handler ?? this.password; if (!GlobalVars.config.sql_enabled) { return(false); } if (!(this != null)) { return(false); } cursor_handler = Lang13.BoolNullable(this.default_cursor); if (!(cursor_handler == true)) { cursor_handler = false; } return(DB13.connect(this._db_con, dbi_handler, user_handler, password_handler, cursor_handler, null)); }
// Function from file: dbcore.dm public bool NextRow( ) { return(DB13.next_row(this._db_query, this.item, this.conversions)); }
// Function from file: dbcore.dm public string ErrorMsg( ) { return(DB13.error_msg(this._db_con)); }
// Function from file: dbcore.dm public string Quote(dynamic str = null) { return(DB13.quote(this._db_con, str)); }
public virtual void Open(Database filename = null) { DB13.op(this, 0, filename); return; }
public override dynamic Close( ) { return(DB13.op(this, 10)); }
public dynamic Reset( ) { return(DB13.op(this, 11)); }
public virtual dynamic Close( ) { DB13.op(this, 1); return(null); }
public dynamic GetRowData( ) { return(DB13.op(this, 18)); }
public dynamic ErrorMsg( ) { return(DB13.op(this, 3)); }
public dynamic GetColumn(dynamic column = null) { return(DB13.op(this, 17, column - 1)); }
public void Clear( ) { DB13.op(this, 4); return; }
// Function from file: dbcore.dm public int RowsAffected( ) { return(DB13.rows_affected(this._db_query)); }
public dynamic NextRow( ) { return(DB13.op(this, 9)); }
public dynamic RowsAffected( ) { return(DB13.op(this, 12)); }
// Function from file: dbcore.dm public bool Disconnect( ) { return(DB13.close(this._db_con)); }
public dynamic Error( ) { return(DB13.op(this, 2)); }
// Function from file: dbcore.dm public int RowCount( ) { return(DB13.row_count(this._db_query)); }
public dynamic Columns(dynamic column = null) { return(DB13.op(this, 16, (Lang13.Bool(Lang13.IsNumber(column)) ? column - 1 : column))); }