Package org.lealone.engine

Examples of org.lealone.engine.MetaRecord


        MetaDataAdmin.createTableIfNotExists(TABLE_NAME);
        table = new HTable(HBaseUtils.getConfiguration(), TABLE_NAME);
    }

    public void loadMetaRecords(List<MetaRecord> records) throws Exception {
        MetaRecord rec;
        for (Result r : table.getScanner(new Scan())) {
            if (r.isEmpty())
                continue;
            rec = getMetaRecord(r);
            records.add(rec);
View Full Code Here


        }
    }

    public void removeRecord(int id) {
        try {
            MetaRecord rec = getMetaRecord(id);
            if (rec != null) {
                table.delete(new Delete(Bytes.toBytes(id)));
            }
        } catch (Exception e) {
            throw new RuntimeException(e);
View Full Code Here

        //data[1] = null;
        //type
        data[2] = ValueInt.get(Bytes.toInt(r.getValue(MetaDataAdmin.DEFAULT_COLUMN_FAMILY, OBJECT_TYPE)));
        //sql
        data[3] = ValueString.get(Bytes.toString(r.getValue(MetaDataAdmin.DEFAULT_COLUMN_FAMILY, SQL)));
        return new MetaRecord(new SimpleRow(data));

    }
View Full Code Here

        int id = obj.getId();
        if (id > 0 && !obj.isTemporary()) {
            objectIds.set(id);

            if (!starting && isMaster && metaDataTable != null) {
                metaDataTable.addRecord(new MetaRecord(obj));
            }
        }
    }
View Full Code Here

        lockMeta(session);
        int id = obj.getId();
        //removeMeta(session, id); //并不删除记录
        if (id > 0 && !starting) {
            if (isMaster && metaDataTable != null) {
                metaDataTable.updateRecord(new MetaRecord(obj));
            }
        }
    }
View Full Code Here

TOP

Related Classes of org.lealone.engine.MetaRecord

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.