本文整理了Java中javax.persistence.JoinTable.schema()
方法的一些代码示例,展示了JoinTable.schema()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JoinTable.schema()
方法的具体详情如下:
包路径:javax.persistence.JoinTable
类名称:JoinTable
方法名:schema
暂无
代码示例来源:origin: ebean-orm/ebean
/**
* Return the full table name
*/
private String getFullTableName(JoinTable joinTable) {
StringBuilder sb = new StringBuilder();
if (!StringHelper.isNull(joinTable.catalog())) {
sb.append(joinTable.catalog()).append(".");
}
if (!StringHelper.isNull(joinTable.schema())) {
sb.append(joinTable.schema()).append(".");
}
sb.append(joinTable.name());
return sb.toString();
}
代码示例来源:origin: hibernate/hibernate-orm
schema = joinTable.schema();
catalog = joinTable.catalog();
logicalName = new QualifiedTableName(
代码示例来源:origin: hibernate/hibernate-orm
@Test
public void testJoinTableNoChildren() throws Exception {
reader = getReader( Entity2.class, "field1", "many-to-many.orm16.xml" );
assertAnnotationPresent( ManyToMany.class );
assertAnnotationPresent( JoinTable.class );
assertAnnotationNotPresent( JoinColumns.class );
assertAnnotationNotPresent( JoinColumn.class );
JoinTable joinTableAnno = reader.getAnnotation( JoinTable.class );
assertEquals( "", joinTableAnno.catalog() );
assertEquals( "", joinTableAnno.name() );
assertEquals( "", joinTableAnno.schema() );
assertEquals( 0, joinTableAnno.joinColumns().length );
assertEquals( 0, joinTableAnno.inverseJoinColumns().length );
assertEquals( 0, joinTableAnno.uniqueConstraints().length );
}
代码示例来源:origin: hibernate/hibernate-orm
@Test
public void testJoinTableNoChildren() throws Exception {
reader = getReader( Entity1.class, "field1", "many-to-one.orm4.xml" );
assertAnnotationPresent( ManyToOne.class );
assertAnnotationNotPresent( JoinColumn.class );
assertAnnotationNotPresent( JoinColumns.class );
assertAnnotationPresent( JoinTable.class );
JoinTable joinTableAnno = reader.getAnnotation( JoinTable.class );
assertEquals( "", joinTableAnno.catalog() );
assertEquals( "", joinTableAnno.name() );
assertEquals( "", joinTableAnno.schema() );
assertEquals( 0, joinTableAnno.joinColumns().length );
assertEquals( 0, joinTableAnno.inverseJoinColumns().length );
assertEquals( 0, joinTableAnno.uniqueConstraints().length );
}
代码示例来源:origin: hibernate/hibernate-orm
if ( table != null ) {
ad.setValue( "name", table.name() );
ad.setValue( "schema", table.schema() );
ad.setValue( "catalog", table.catalog() );
ad.setValue( "uniqueConstraints", table.uniqueConstraints() );
代码示例来源:origin: hibernate/hibernate-orm
schema = assocTable.schema();
tableName = assocTable.name();
uniqueConstraints = assocTable.uniqueConstraints();
代码示例来源:origin: Impetus/Kundera
/**
* Instantiates a new join table metadata.
*
* @param relationField
* the relation field
*/
public JoinTableMetadata(Field relationField)
{
JoinTable jtAnn = relationField.getAnnotation(JoinTable.class);
setJoinTableName(jtAnn.name());
setJoinTableSchema(jtAnn.schema());
for (JoinColumn joinColumn : jtAnn.joinColumns())
{
addJoinColumns(joinColumn.name());
}
for (JoinColumn inverseJoinColumn : jtAnn.inverseJoinColumns())
{
addInverseJoinColumns(inverseJoinColumn.name());
}
}
代码示例来源:origin: hibernate/hibernate-orm
assertEquals( "cat1", joinTableAnno.catalog() );
assertEquals( "table1", joinTableAnno.name() );
assertEquals( "schema1", joinTableAnno.schema() );
代码示例来源:origin: org.hibernate/hibernate-annotations
schema = joinTable.schema();
catalog = joinTable.catalog();
secondaryTableNameContext = new SecondaryTableNameSource( joinTable.name() );
代码示例来源:origin: hibernate/hibernate-orm
assertEquals( "cat1", joinTableAnno.catalog() );
assertEquals( "table1", joinTableAnno.name() );
assertEquals( "schema1", joinTableAnno.schema() );
代码示例来源:origin: org.avaje.ebean/ebean
/**
* Return the full table name
*/
private String getFullTableName(JoinTable joinTable) {
StringBuilder sb = new StringBuilder();
if (!StringHelper.isNull(joinTable.catalog())) {
sb.append(joinTable.catalog()).append(".");
}
if (!StringHelper.isNull(joinTable.schema())) {
sb.append(joinTable.schema()).append(".");
}
sb.append(joinTable.name());
return sb.toString();
}
代码示例来源:origin: io.ebean/ebean
/**
* Return the full table name
*/
private String getFullTableName(JoinTable joinTable) {
StringBuilder sb = new StringBuilder();
if (!StringHelper.isNull(joinTable.catalog())) {
sb.append(joinTable.catalog()).append(".");
}
if (!StringHelper.isNull(joinTable.schema())) {
sb.append(joinTable.schema()).append(".");
}
sb.append(joinTable.name());
return sb.toString();
}
代码示例来源:origin: hibernate/hibernate-orm
assertEquals( "catalog1", joinTableAnno.catalog() );
assertEquals( "table1", joinTableAnno.name() );
assertEquals( "schema1", joinTableAnno.schema() );
代码示例来源:origin: org.hibernate/hibernate-annotations
if ( table != null ) {
ad.setValue( "name", table.name() );
ad.setValue( "schema", table.schema() );
ad.setValue( "catalog", table.catalog() );
ad.setValue( "uniqueConstraints", table.uniqueConstraints() );
代码示例来源:origin: SAP/olingo-jpa-processor-v4
IntermediateJoinTable(final IntermediateNavigationProperty intermediateProperty, final JoinTable jpaJoinTable,
final IntermediateSchema schema) {
super();
this.intermediateProperty = intermediateProperty;
this.jpaJoinTable = jpaJoinTable;
this.sourceType = intermediateProperty.getSourceType();
this.jpaEntityType = schema.getEntityType(jpaJoinTable.catalog(), jpaJoinTable.schema(), jpaJoinTable.name());
}
代码示例来源:origin: org.hibernate/hibernate-annotations
schema = assocTable.schema();
tableName = assocTable.name();
uniqueConstraints = assocTable.uniqueConstraints();
代码示例来源:origin: org.apache.openjpa/com.springsource.org.apache.openjpa
/**
* Parse @JoinTable.
*/
private void parseJoinTable(FieldMapping fm, JoinTable join) {
fm.getMappingInfo().setTableName(toTableName(join.schema(),
join.name()));
parseJoinColumns(fm, fm.getMappingInfo(), false, join.joinColumns());
parseJoinColumns(fm, fm.getElementMapping().getValueInfo(), false,
join.inverseJoinColumns());
}
代码示例来源:origin: org.apache.openjpa/openjpa-all
/**
* Parse @JoinTable.
*/
private void parseJoinTable(FieldMapping fm, JoinTable join) {
FieldMappingInfo info = fm.getMappingInfo();
DBIdentifier joinTbl = toTableIdentifier(join.schema(), join.name());
info.setTableIdentifier(joinTbl);
parseJoinColumns(fm, info, false, join.joinColumns());
parseJoinColumns(fm, fm.getElementMapping().getValueInfo(), false,
join.inverseJoinColumns());
addUniqueConstraints(info.getTableIdentifier().getName(), fm, info,
join.uniqueConstraints());
}
代码示例来源:origin: org.apache.openjpa/openjpa-persistence-jdbc
/**
* Parse @JoinTable.
*/
private void parseJoinTable(FieldMapping fm, JoinTable join) {
FieldMappingInfo info = fm.getMappingInfo();
DBIdentifier joinTbl = toTableIdentifier(join.schema(), join.name());
info.setTableIdentifier(joinTbl);
parseJoinColumns(fm, info, false, join.joinColumns());
parseJoinColumns(fm, fm.getElementMapping().getValueInfo(), false,
join.inverseJoinColumns());
addUniqueConstraints(info.getTableIdentifier().getName(), fm, info,
join.uniqueConstraints());
}
代码示例来源:origin: org.apache.openejb.patch/openjpa
/**
* Parse @JoinTable.
*/
private void parseJoinTable(FieldMapping fm, JoinTable join) {
FieldMappingInfo info = fm.getMappingInfo();
DBIdentifier joinTbl = toTableIdentifier(join.schema(), join.name());
info.setTableIdentifier(joinTbl);
parseJoinColumns(fm, info, false, join.joinColumns());
parseJoinColumns(fm, fm.getElementMapping().getValueInfo(), false,
join.inverseJoinColumns());
addUniqueConstraints(info.getTableIdentifier().getName(), fm, info,
join.uniqueConstraints());
}
内容来源于网络,如有侵权,请联系作者删除!