Examples of tableToMetaAttributes()


Examples of org.hibernate.cfg.reveng.ReverseEngineeringStrategy.tableToMetaAttributes()

  public void testMetaAttributes() {
   
    ReverseEngineeringStrategy res = buildOverrideRepository().addResource(OVERRIDETEST_REVENG_XML).getReverseEngineeringStrategy(new DefaultReverseEngineeringStrategy());
   
    TableIdentifier tableIdentifier = new TableIdentifier(null, null, "TblTest");
    Map attributes = res.tableToMetaAttributes(tableIdentifier);
    assertNotNull(attributes);
    assertEquals(attributes.size(),1);
    MetaAttribute ma = (MetaAttribute) attributes.get("use-in-test");
    assertEquals(ma.getName(), "use-in-test");
    assertEquals(ma.getValue(), "true");
View Full Code Here

Examples of org.hibernate.cfg.reveng.ReverseEngineeringStrategy.tableToMetaAttributes()

    MetaAttribute ma = (MetaAttribute) attributes.get("use-in-test");
    assertEquals(ma.getName(), "use-in-test");
    assertEquals(ma.getValue(), "true");
       
    tableIdentifier = new TableIdentifier(settings.getDefaultCatalogName(), "Werd", "Testy");
    attributes = res.tableToMetaAttributes( tableIdentifier );
    assertNotNull(attributes);
    ma = (MetaAttribute) attributes.get( "werd-meta" );
    assertEquals(ma.getName(), "werd-meta");
    assertEquals(ma.getValues().size(), 2);       
 
View Full Code Here

Examples of org.hibernate.cfg.reveng.ReverseEngineeringStrategy.tableToMetaAttributes()

    ma = (MetaAttribute) attributes.get( "werd-meta" );
    assertEquals(ma.getName(), "werd-meta");
    assertEquals(ma.getValues().size(), 2);       
 
    tableIdentifier = new TableIdentifier(null, "Werd", "MetaTable");
    attributes = res.tableToMetaAttributes( tableIdentifier );
    assertNotNull(attributes);
    assertEquals(2, attributes.size());
    ma = (MetaAttribute) attributes.get("specific-werd");
    assertEquals(ma.getName(), "specific-werd");
    assertEquals(ma.getValue(), "a one");
View Full Code Here

Examples of org.hibernate.cfg.reveng.ReverseEngineeringStrategy.tableToMetaAttributes()

    assertEquals(ma.getName(), "werd-meta");
    assertEquals(1, ma.getValues().size()); // as long as no inherit this should be one
    assertEquals("value three", ma.getValue());
 
    tableIdentifier = new TableIdentifier(null, null, "Nothing");
    assertEquals(null, res.tableToMetaAttributes(tableIdentifier));
   
    assertNull(res.columnToMetaAttributes(new TableIdentifier("Nothing"), "bogus"));
    assertNull(res.columnToMetaAttributes( new TableIdentifier(null, "Werd", "MetaTable"), "bogusColumn" ));
    attributes = res.columnToMetaAttributes( new TableIdentifier(null, "Werd", "MetaTable"), "MetaColumn" );
    assertEquals(1, attributes.size());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.