summaryrefslogtreecommitdiff
path: root/storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp
diff options
context:
space:
mode:
authorbrian@zim.(none) <>2005-04-26 18:19:54 -0700
committerbrian@zim.(none) <>2005-04-26 18:19:54 -0700
commit2a7c71e309337588b3815ea7ff1fe20d734d50d9 (patch)
treedf9016f3d70b4657f89dcddca2ec4e188fc7fbdf /storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp
parent8e0eb65f9aaa3dc5a4f713988e58190b82466cde (diff)
downloadmariadb-git-2a7c71e309337588b3815ea7ff1fe20d734d50d9.tar.gz
Changes to create storage directory for storage engines.
Diffstat (limited to 'storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp')
-rw-r--r--storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp132
1 files changed, 132 insertions, 0 deletions
diff --git a/storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp b/storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp
new file mode 100644
index 00000000000..2bd4eab6b70
--- /dev/null
+++ b/storage/ndb/test/ndbapi/old_dirs/acid2/TraceNdbApi.hpp
@@ -0,0 +1,132 @@
+/* Copyright (C) 2003 MySQL AB
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
+
+
+#ifndef TraceNdbApi_hpp
+#define TraceNdbApi_hpp
+
+
+class CTraceNdbSchemaOp : public NdbSchemaOp
+{
+public:
+ int createTable(const char* aTableName);
+ int createAttribute(const char* aAttrName, KeyType aTupleyKey);
+};
+
+
+
+class CTraceNdbSchemaCon : public NdbSchemaCon
+{
+public:
+ CTraceNdbSchemaOp* getNdbSchemaOp();
+ int execute();
+};
+
+
+
+class CTraceNdbRecAttr : public NdbRecAttr
+{
+public:
+ Uint32 u_32_value();
+};
+
+
+class CTraceNdbOperation : public NdbOperation
+{
+public:
+ int insertTuple();
+ int updateTuple();
+ int interpretedUpdateTuple();
+ int readTuple();
+ int readTupleExclusive();
+ int deleteTuple();
+ int equal(const char* anAttrName, Uint32 aValue);
+ int setValue(const char* anAttrName, Uint32 aValue);
+ int incValue(const char* anAttrName, Uint32 aValue);
+ CTraceNdbRecAttr* getValue(const char* anAttrName);
+
+};
+
+
+class CTraceNdbIndexOperation : public NdbIndexOperation
+{
+public:
+ int insertTuple();
+ int updateTuple();
+ int interpretedUpdateTuple();
+ int readTuple();
+ int readTupleExclusive();
+ int deleteTuple();
+ int equal(const char* anAttrName, Uint32 aValue);
+ int setValue(const char* anAttrName, Uint32 aValue);
+ int incValue(const char* anAttrName, Uint32 aValue);
+ CTraceNdbRecAttr* getValue(const char* anAttrName);
+};
+
+
+
+class CTraceNdbConnection : public NdbConnection
+{
+public:
+ CTraceNdbOperation* getNdbOperation(const char* aTableName);
+ CTraceNdbIndexOperation* getNdbIndexOperation(const char* anIndexName, const char* aTableName);
+
+ int execute(ExecType aTypeOfExec);
+
+ int execute_ok(ExecType aTypeOfExec)
+ {
+ return execute(aTypeOfExec);
+ };
+
+ const NdbError & getNdbError(void) const;
+};
+
+
+
+class CTraceNdbDictionary : public NdbDictionary
+{
+public:
+ class CTraceTable : public Table
+ {
+ };
+
+ class CTraceIndex : public Index
+ {
+ };
+
+ class CTraceColumn : public Column
+ {
+ };
+
+ int createTable(const CTraceTable &);
+ int createIndex(const CTraceIndex &);
+};
+
+
+
+class CTraceNdb : public Ndb
+{
+public:
+ CTraceNdb(const char* aDataBase);
+ CTraceNdbSchemaCon* startSchemaTransaction();
+ void closeSchemaTransaction(CTraceNdbSchemaCon* aSchemaCon);
+ CTraceNdbConnection* startTransaction();
+ void closeTransaction(CTraceNdbConnection* aConnection);
+};
+
+
+
+#endif // TraceNdbApi_hpp