private void processNamedEntityGraphs() { processNamedEntityGraph( annotatedClass.getAnnotation( NamedEntityGraph.class ) ); final NamedEntityGraphs graphs = annotatedClass.getAnnotation( NamedEntityGraphs.class ); if ( graphs != null ) { for ( NamedEntityGraph graph : graphs.value() ) { processNamedEntityGraph( graph ); } } }
@NamedQuery(name = "SyntheticMarket.findBySymbol", query = "select s from SyntheticMarket s where symbol=?1", hints = {@QueryHint( name = "org.hibernate.cacheable", value = "true")}) @NamedEntityGraphs({@NamedEntityGraph(name = "syntheticMarketWithMarkets", attributeNodes = {@NamedAttributeNode(value = "markets")}),}) @Table(indexes = {@Index(columnList = "symbol"), @Index(columnList = "active"), @Index(columnList = "version"), @Index(columnList = "revision")}) public class SyntheticMarket extends Tradeable {
@NamedQuery(name = "orderUpdate.findOrdersByState", query = "select ou from OrderUpdate ou where ou.state = (select max(ouu.state) from OrderUpdate ouu where ouu.order = ou.order) and state in (?1) and ou.order.portfolio =?2"), @NamedQuery(name = "orderUpdate.findStateByOrder", query = "select ou from OrderUpdate ou where ou.state = (select max(ouu.state) from OrderUpdate ouu where ouu.order = ou.order) and order in (?1)") }) @NamedEntityGraphs({
private NamedEntityGraphs getNamedEntityGraphs(Element tree, XMLContext.Default defaults) { List<NamedEntityGraph> queries = buildNamedEntityGraph( tree, defaults, classLoaderAccess ); if ( defaults.canUseJavaAnnotations() ) { NamedEntityGraph annotation = getPhysicalAnnotation( NamedEntityGraph.class ); addNamedEntityGraphIfNeeded( annotation, queries ); NamedEntityGraphs annotations = getPhysicalAnnotation( NamedEntityGraphs.class ); if ( annotations != null ) { for ( NamedEntityGraph current : annotations.value() ) { addNamedEntityGraphIfNeeded( current, queries ); } } } if ( queries.size() > 0 ) { AnnotationDescriptor ad = new AnnotationDescriptor( NamedEntityGraphs.class ); ad.setValue( "value", queries.toArray( new NamedEntityGraph[queries.size()] ) ); return AnnotationFactory.create( ad ); } else { return null; } }
@Index(name = "sp_idx_action_02", columnList = "tenant,target,active"), @Index(name = "sp_idx_action_prim", columnList = "tenant,id") }) @NamedEntityGraphs({ @NamedEntityGraph(name = "Action.ds", attributeNodes = { @NamedAttributeNode("distributionSet") }), @NamedEntityGraph(name = "Action.all", attributeNodes = { @NamedAttributeNode("distributionSet"), @NamedAttributeNode(value = "target", subgraph = "target.ds") }, subgraphs = @NamedSubgraph(name = "target.ds", attributeNodes = @NamedAttributeNode("assignedDistributionSet"))) })
private void processNamedEntityGraphs() { processNamedEntityGraph( annotatedClass.getAnnotation( NamedEntityGraph.class ) ); final NamedEntityGraphs graphs = annotatedClass.getAnnotation( NamedEntityGraphs.class ); if ( graphs != null ) { for ( NamedEntityGraph graph : graphs.value() ) { processNamedEntityGraph( graph ); } } }
@Index(name = "sp_idx_action_02", columnList = "tenant,target,active"), @Index(name = "sp_idx_action_prim", columnList = "tenant,id") }) @NamedEntityGraphs({ @NamedEntityGraph(name = "Action.ds", attributeNodes = { @NamedAttributeNode("distributionSet") }), @NamedEntityGraph(name = "Action.all", attributeNodes = { @NamedAttributeNode("distributionSet"), @NamedAttributeNode(value = "target", subgraph = "target.ds") }, subgraphs = @NamedSubgraph(name = "target.ds", attributeNodes = @NamedAttributeNode("assignedDistributionSet"))) })
private NamedEntityGraphs getNamedEntityGraphs(Element tree, XMLContext.Default defaults) { List<NamedEntityGraph> queries = buildNamedEntityGraph( tree, defaults, bootstrapContext.getClassLoaderAccess() ); if ( defaults.canUseJavaAnnotations() ) { NamedEntityGraph annotation = getPhysicalAnnotation( NamedEntityGraph.class ); addNamedEntityGraphIfNeeded( annotation, queries ); NamedEntityGraphs annotations = getPhysicalAnnotation( NamedEntityGraphs.class ); if ( annotations != null ) { for ( NamedEntityGraph current : annotations.value() ) { addNamedEntityGraphIfNeeded( current, queries ); } } } if ( queries.size() > 0 ) { AnnotationDescriptor ad = new AnnotationDescriptor( NamedEntityGraphs.class ); ad.setValue( "value", queries.toArray( new NamedEntityGraph[queries.size()] ) ); return AnnotationFactory.create( ad ); } else { return null; } }
@NamedEntityGraphs({ @NamedEntityGraph(name = "graph.Position.fills", attributeNodes = @NamedAttributeNode(value = "fills", subgraph = "fills"), subgraphs = { @NamedSubgraph(name = "fills", attributeNodes = @NamedAttributeNode("order")) }),
@NamedQueries({ @NamedQuery(name = "Fill.findFill", query = "select f from Fill f where id=?1") }) @NamedEntityGraphs({
@NamedQueries({ @NamedQuery(name = "Order.findOrder", query = "select o from Order o where id =?1") }) @NamedEntityGraphs({