本文整理汇总了Java中javax.jdo.annotations.Join类的典型用法代码示例。如果您正苦于以下问题:Java Join类的具体用法?Java Join怎么用?Java Join使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Join类属于javax.jdo.annotations包,在下文中一共展示了Join类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: addManyToManyMetadata
import javax.jdo.annotations.Join; //导入依赖的package包/类
private void addManyToManyMetadata(FieldMetadata fmd, RelationshipHolder holder, EntityDto entity, FieldDto field,
Class<?> definition) {
// If tables and column names have been specified in annotations, do not set their metadata
// Join metadata must be present at exactly one side of the M:N relation when using Sets
// When using Lists join metadata must be present at two sides of M:N relation
if (!holder.isOwningSide() || holder.isListManyToMany()) {
java.lang.reflect.Field fieldDefinition = FieldUtils.getDeclaredField(definition, field.getBasic().getName(),
true);
Join join = fieldDefinition.getAnnotation(Join.class);
Persistent persistent = fieldDefinition.getAnnotation(Persistent.class);
Element element = fieldDefinition.getAnnotation(Element.class);
JoinMetadata jmd = null;
if (join == null) {
jmd = fmd.newJoinMetadata();
}
setTableNameMetadata(fmd, persistent, entity, field, holder, EntityType.STANDARD);
setElementMetadata(fmd, element, holder, entity);
if (join == null || StringUtils.isEmpty(join.column())) {
setJoinMetadata(jmd, fmd, ClassName.getSimpleName(entity.getClassName()).toUpperCase() + ID_SUFFIX);
ForeignKeyMetadata fkmd = getOrCreateFkMetadata(jmd);
fkmd.setName(KeyNames.foreignKeyName(entity.getName(), entity.getId(), field.getBasic().getName(),
EntityType.STANDARD));
}
}
}
示例2: getItems
import javax.jdo.annotations.Join; //导入依赖的package包/类
/**
* Obtiene una lista de los items de la factura
*
* @return items List<Itemfactura>
*/
@Join
@Named("Detalle")
@Render(Type.EAGERLY)
@MemberOrder(sequence = "1")
public List<ItemFactura> getItems() {
return items;
}
示例3: getProductos
import javax.jdo.annotations.Join; //导入依赖的package包/类
/**
* Obtiene una lista de Productos Elaborados
* @return productos List<ValueProductosElaborados>
*/
@Persistent(dependentElement = "true")
@Join(deleteAction = ForeignKeyAction.CASCADE)
@Render(Type.EAGERLY)
@MemberOrder(sequence = "1")
public List<ValueProductoElaborado> getProductos() {
return productos;
}
示例4: getMenues
import javax.jdo.annotations.Join; //导入依赖的package包/类
/**
* Obtiene una lista de menues
* @return menues List<ValueMenu>
*/
@Persistent(dependentElement = "true")
@Join(deleteAction = ForeignKeyAction.CASCADE)
@Render(Type.EAGERLY)
@MemberOrder(sequence = "2")
public List<ValueMenu> getMenues() {
return menues;
}
示例5: getOfertas
import javax.jdo.annotations.Join; //导入依赖的package包/类
/**
* Permite obtener Ofertas para la comanda
* @return list<Oferta>
*/
@Persistent(dependentElement = "true")
@Join(deleteAction = ForeignKeyAction.CASCADE)
@Render(Type.EAGERLY)
@MemberOrder(sequence = "3")
public List<ValueOferta> getOfertas() {
return ofertas;
}
示例6: getFarmacia
import javax.jdo.annotations.Join; //导入依赖的package包/类
@Join
public Farmacia getFarmacia() {
return farmacia;
}
示例7: getMovimientos
import javax.jdo.annotations.Join; //导入依赖的package包/类
@Join
public List<Movimiento> getMovimientos() {
return movimientos;
}
示例8: getDroguerias
import javax.jdo.annotations.Join; //导入依赖的package包/类
@Join
public List<Drogueria> getDroguerias() {
return droguerias;
}