Package com.asakusafw.compiler.bulkloader.BulkLoaderScript

Examples of com.asakusafw.compiler.bulkloader.BulkLoaderScript.ImportTable


        BulkLoaderScript script = loadScript(info);
        assertThat(script.getImportTargetTables().size(), is(1));
        assertThat(script.getExportTargetTables().size(), is(1));

        ImportTable itable = script.getImportTargetTables().get(0);
        ExportTable etable = script.getExportTargetTables().get(0);
        assertThat(etable.getSources().size(), is(1));

        ModelOutput<Ex1> source = tester.openOutput(Ex1.class, itable.getDestination());
        Ex1 ex1 = new Ex1();
        ex1.setSid(200);
        ex1.setValue(1);
        source.write(ex1);
        ex1.setSid(300);
View Full Code Here


        BulkLoaderScript script = loadScript(info);
        assertThat(script.getImportTargetTables().size(), is(1));
        assertThat(script.getExportTargetTables().size(), is(1));

        ImportTable itable = script.getImportTargetTables().get(0);
        ExportTable etable = script.getExportTargetTables().get(0);
        assertThat(etable.getSources().size(), is(1));

        ModelOutput<Ex1> source = tester.openOutput(Ex1.class, itable.getDestination());
        Ex1 ex1 = new Ex1();
        ex1.setSid(200);
        ex1.setValue(1);
        source.write(ex1);
        ex1.setSid(300);
View Full Code Here

     */
    @Test
    public void importers() {
        List<ImportTable> importers = Lists.create();
        List<ExportTable> exporters = Lists.create();
        importers.add(new ImportTable(
                Ex1.class,
                "EX1",
                Arrays.asList("SID", "VALUE", "STRING", "LAST_UPDATE_TIME", "JOBFLOW_SID", "CACHE_FILE_SID"),
                "VALUE > 0",
                "cache-id",
                LockType.ROW,
                LockedOperation.ERROR,
                Location.fromPath("ex1", '/')));
        importers.add(new ImportTable(
                Ex2.class,
                "EX2",
                Arrays.asList("SID", "VALUE", "STRING", "LAST_UPDATE_TIME", "JOBFLOW_SID", "CACHE_FILE_SID"),
                "VALUE < 0",
                null,
View Full Code Here

            lockedOperation = LockedOperation.FORCE;
            break;
        default:
            throw new AssertionError(desc.getLockType());
        }
        return new ImportTable(
                desc.getModelType(),
                desc.getTableName(),
                desc.getColumnNames(),
                desc.getWhere(),
                desc.isCacheEnabled() ? desc.calculateCacheId() : null,
View Full Code Here

TOP

Related Classes of com.asakusafw.compiler.bulkloader.BulkLoaderScript.ImportTable

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.