Java 类org.hibernate.mapping.MetaAttribute 实例源码

项目:sit-ad-archetype-javaee7-web    文件:CustomReverseEngineeringStrategy.java   
@SuppressWarnings({ "rawtypes", "unchecked" })
private void addMeta(Map map, String name, String... values) {
    MetaAttribute attr = new MetaAttribute(name);
    for (String value : values) {
        attr.addValue(value);
    }
    map.put(name, attr);
}
项目:cacheonix-core    文件:MasterDetailTest.java   
public void testMeta() throws Exception {
    PersistentClass clazz = getCfg().getClassMapping( Master.class.getName() );
    MetaAttribute meta = clazz.getMetaAttribute("foo");
    assertTrue( "foo".equals( meta.getValue() ) );
    meta = clazz.getProperty("name").getMetaAttribute("bar");
    assertTrue( meta.isMultiValued() );
}