Package com.draagon.meta.manager.db

Examples of com.draagon.meta.manager.db.ObjectMappingDB


    if (!( mapping instanceof ObjectMappingDB )) {
      throw new MetaException( "Expected an ObjectMappingDB instance, not a [" + mapping.getClass().getSimpleName() + "]" );
    }
       
    ObjectMappingDB omdb = (ObjectMappingDB) mapping;
   
    try {
        if ( validateDefinition( c, dd, omdb.getDBDef() )) {
          createdDefs.add( omdb.getDBDef() );
        }
    }
    catch( Exception e ) {
      throw new MetaException( "Error validating mapping [" + mapping + "] for MetaClass [" + mc + "]: " + e.getMessage(), e );
    }
View Full Code Here


    if ( base instanceof TableDef ) {
      TableDef table = (TableDef) base;
     
      InheritenceDef inheritence = table.getInheritence();
      if ( inheritence != null ) {
        ObjectMappingDB smom = (ObjectMappingDB) omdb.getSuperMapping();
       
        // Set the discriminator values
        if ( inheritence.getDiscriminatorName() != null ) {
          MetaField df = omdb.getField( inheritence.getDiscriminatorName() );
          df.setString( o, inheritence.getDiscriminatorValue() );
View Full Code Here

      TableDef table = (TableDef) base;
     
      InheritenceDef inheritence = table.getInheritence();
      if ( inheritence != null ) {

        ObjectMappingDB smom = (ObjectMappingDB) omdb.getSuperMapping();

        // Setup the key
        MetaField rf = omdb.getField( inheritence.getRefColumn() );
        Collection<MetaField> pkeys = new ArrayList<MetaField>();
        pkeys.add( rf );
View Full Code Here

    if ( base instanceof TableDef ) {
      TableDef table = (TableDef) base;
     
      InheritenceDef inheritence = table.getInheritence();
      if ( inheritence != null ) {
        ObjectMappingDB smom = (ObjectMappingDB) omdb.getSuperMapping();

        MetaField rf = omdb.getField( inheritence.getRefColumn() );
        Collection<MetaField> pkeys = new ArrayList<MetaField>();
        pkeys.add( rf );
View Full Code Here

TOP

Related Classes of com.draagon.meta.manager.db.ObjectMappingDB

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.