aboutsummaryrefslogtreecommitdiff
path: root/odb/context.cxx
AgeCommit message (Collapse)AuthorFilesLines
2012-09-04NULL handling improvementsBoris Kolpackov1-18/+59
Add support for specifying NULL-ness for types with built-in mapping. Handle Oracle [N]VARCHAR2 and SQLite FLOAT oddities using this mechanism instead of overriding it at the schema generation level. Also use the is_null argument that is passed to value_traits::init_image() to indicate whether the value can be NULL.
2012-08-16Add support for automatically discovering accessor/modifier functionsBoris Kolpackov1-2/+27
New options: --{accessor,modifier}-regex, --{accessor,modifier}-regex-trace.
2012-08-15Add support for member accessors/modifiersBoris Kolpackov1-0/+386
New pragmas: get, set, access. New test: common/access.
2012-08-01Add support for empty column names in composite value typesBoris Kolpackov1-1/+29
2012-07-31Add support for changing location that ODB views as class definitionBoris Kolpackov1-3/+12
This is useful for making third-party/system types into ODB composite value types. New pragma: definition. New test: common/definition.
2012-04-27Add support for NULL pointers to objects with composite object idsBoris Kolpackov1-0/+15
2012-04-23Polymorphic inheritance supportBoris Kolpackov1-7/+68
2012-03-05Add support for generating schema creation code into separate C++ fileBoris Kolpackov1-0/+3
2012-02-27Add support for specifying table prefix on namespaceBoris Kolpackov1-18/+78
2012-02-22Add support for composite object idsBoris Kolpackov1-3/+67
New pragma id_type (member). New test: common/composite-id. The composite example has also been updated.
2012-01-29Update copyright yearBoris Kolpackov1-1/+1
2012-01-29Remove author field from file headerBoris Kolpackov1-1/+0
Too much effort to maintain.
2012-01-27Rename --default-schema to --schemaBoris Kolpackov1-2/+2
2012-01-27Make container schema override object schemaBoris Kolpackov1-39/+63
2012-01-26Implement support for database schemaBoris Kolpackov1-18/+99
New pragma qualifier: namespace. New pragma specifier: schema. The table specifier was extended to accept a schema prefix. New option: --default- schema. The common/schema test was extended to cover the new functionality.
2012-01-20ODB compiler implementation, traits, and types test for SQL ServerBoris Kolpackov1-0/+6
2012-01-08Add support for defining composite value type as class template instantiationsBoris Kolpackov1-29/+59
2011-11-09Make sure we can use same type as both container and simple valueBoris Kolpackov1-6/+4
2011-11-08Get rid of special tracer databaseBoris Kolpackov1-5/+0
The include, types, and pragma tests have been moved to the common/ directory while the object test has been merged into common/lifecycle. The transaction test will be re-implemented as common/ test as soon as SQL statement tracing support is merged.
2011-11-01Implement support for optimistic concurrencyBoris Kolpackov1-0/+2
New pragmas: optimistic, version. New test: optimistic. New database function: reload().
2011-10-24Generate database schema from database model instead of C++ modelBoris Kolpackov1-5/+8
We now first create the so-called database model from C++ model and then use that to generate the database schema. The new approach also adds more general support for primary/foreign keys, including multi- column keys. Finally, for MySQL we now generate out-of-line foreign key definitions. Because MySQL does not support deferred constraints checking, deferred foreign keys are written commented out, for documentation.
2011-10-21Add support for const data membersBoris Kolpackov1-34/+87
Const data members are automatically treated as readonly. New test: const-member.
2011-10-21Add support for readonly membersBoris Kolpackov1-49/+90
New pragma: readonly. New test: readonly.
2011-10-21Split 'in' binding into insert/update pair; rename 'out' to selectBoris Kolpackov1-30/+30
Also add the initial infrastructure for the readonly members support. Right now the split insert/update bindings allows us to avoid sending object id in UPDATE statements. It will also allows us to support readonly members.
2011-10-21Implement SQL type parsing and C++ type mappings for OracleConstantin Michael1-6/+2
2011-10-21Make ODB Oracle awareConstantin Michael1-0/+10
2011-09-19Make processing top-level action, like validation and generationBoris Kolpackov1-0/+36
2011-09-16Support for views; integrated partBoris Kolpackov1-8/+55
2011-09-09Add support for ignoring bases in has_a() testBoris Kolpackov1-0/+9
2011-09-05Support for views; native partBoris Kolpackov1-2/+15
2011-08-31Rename comp_value() predicate to composite()Boris Kolpackov1-1/+1
2011-08-31Cosmetic changes and cleanupsBoris Kolpackov1-5/+5
Rename some functions to have consistent names. Add object() predicate.
2011-08-28Add wrapper support for containersBoris Kolpackov1-6/+13
2011-08-24Don't append table prefix to names that already have it (container tables)Boris Kolpackov1-3/+11
2011-08-22Add --table-prefix optionBoris Kolpackov1-5/+18
Assign unique table prefixes to most examples. This makes sure that we don't end up with broken schemas where half of the tables were changed by the next test and the other half has foreign keys that now point to nowhere.
2011-08-04Add support for value wrappersBoris Kolpackov1-17/+110
Wrapper is a class that wraps another type. Examples of wrappers are various smart pointers, holders, etc. A wrapper can be transparent or it can handle the NULL semantics. The new odb::nullable class template is a NULL wrapper that helps to add the NULL semantics to a value type. New test: common/wrapper.
2011-07-24Add support for resetting options accumulated with options pragmaBoris Kolpackov1-14/+85
2011-07-22Add pragma for setting type's or member's default valueBoris Kolpackov1-4/+5
New pragma: default. New test: default.
2011-07-22Add support for specifying extra column optionsBoris Kolpackov1-0/+54
New pragmas: options, id_options, index_options, key_options, and value_options.
2011-07-19New design for NULL semanticsBoris Kolpackov1-15/+49
Now, instead of being specified as part of the SQL type with the type pragma, there are separate null and not_null pragmas. The not_null pragma was used to control NULL-ness of object pointers. Now the two pragmas are used consistently for object pointers and simple values (and in the future will work for composite values and containers).
2011-06-29Add --include-regex and --include-regex-trace optionsBoris Kolpackov1-0/+58
This requires libcutl update.
2011-04-25Add support for mapping to database types based on type aliasesBoris Kolpackov1-9/+15
This allows us to, for example, always map size_t to 64-bit type. The current implementation does not work for containers. It is not clear whether it will be possible to make it work using the GCC AST.
2011-04-25Add support for abstract object typesBoris Kolpackov1-0/+2
2011-04-24Implement id_type value type pragmaBoris Kolpackov1-0/+1
2011-04-22Initial support for non-polymorphic inheritanceBoris Kolpackov1-49/+0
Every class gets a separate table. New test: common/inheritance.
2011-04-20Cosmetic changesBoris Kolpackov1-1/+1
2011-03-24Generalization work for MySQL and SQLite supportBoris Kolpackov1-0/+2
2011-03-21Add support for SQLite type system, adjust code generatorsBoris Kolpackov1-14/+14
2011-03-21Move tracer to new ctor-less contextBoris Kolpackov1-12/+0
2011-03-21Move to new "virtual functions in context" modelBoris Kolpackov1-7/+10