@Test public void testExecute_IncludeExcludeAttrs() { SelectContext<Tr> context = new SelectContext<>(Tr.class); Include include1 = new Include("a"); Include include2 = new Include("b"); Include include3 = new Include("id"); Exclude exclude1 = new Exclude("a"); Exclude exclude2 = new Exclude("c"); context.setMergedRequest(requestBuilderFactory.builder() .addInclude(include1) .addInclude(include2) .addInclude(include3) .addExclude(exclude1) .addExclude(exclude2) .build()); stage.execute(context); ResourceEntity<Tr> resourceEntity = context.getEntity(); assertNotNull(resourceEntity); assertTrue(resourceEntity.isIdIncluded()); assertEquals(1, resourceEntity.getAttributes().size()); assertTrue(resourceEntity.getAttributes().containsKey("b")); assertTrue(resourceEntity.getChildren().isEmpty()); }
@Override public ProcessorOutcome execute(SelectContext<?> context) { doExecute(context); return ProcessorOutcome.CONTINUE; }
CreateResourceEntityStage implements Processor<SelectContext<?>> { @Override public ProcessorOutcome execute(SelectContext<?> context) { doExecute(context); return ProcessorOutcome.CONTINUE; } }
CreateResourceEntityStage implements Processor<SelectContext<?>> { @Override public ProcessorOutcome execute(SelectContext<?> context) { doExecute(context); return ProcessorOutcome.CONTINUE; } CreateResourceEntityStage(
            @Inject IMetadataService metadataService,
            @Inject ICayenneExpMerger expMerger,
            @Inject ISortMerger sortMerger,
            @Inject IMapByMerger mapByMerger,
            @Inject ISizeMerger sizeMerger,
            @Inject IIncludeMerger includeMerger,
            @Inject IExcludeMerger excludeMerger); }
CreateResourceEntityStage implements Processor<SelectContext<?>> { @Override public ProcessorOutcome execute(SelectContext<?> context) { doExecute(context); return ProcessorOutcome.CONTINUE; } CreateResourceEntityStage(
            @Inject IMetadataService metadataService,
            @Inject ICayenneExpMerger expMerger,
            @Inject ISortMerger sortMerger,
            @Inject IMapByMerger mapByMerger,
            @Inject ISizeMerger sizeMerger,
            @Inject IIncludeMerger includeMerger,
            @Inject IExcludeMerger excludeMerger); @Override ProcessorOutcome execute(SelectContext<?> context); }
CreateResourceEntityStage implements Processor<SelectContext<?>> { @Override public ProcessorOutcome execute(SelectContext<?> context) { doExecute(context); return ProcessorOutcome.CONTINUE; } CreateResourceEntityStage(
            @Inject IMetadataService metadataService,
            @Inject ICayenneExpMerger expMerger,
            @Inject ISortMerger sortMerger,
            @Inject IMapByMerger mapByMerger,
            @Inject ISizeMerger sizeMerger,
            @Inject IIncludeMerger includeMerger,
            @Inject IExcludeMerger excludeMerger); @Override ProcessorOutcome execute(SelectContext<?> context);  }