Package org.apache.jena.atlas.lib

Examples of org.apache.jena.atlas.lib.ColumnMap.unmap()


    @Test public void remap4()
    {
        ColumnMap x = new ColumnMap("POS", 2,0,1) ;
        Tuple<String> tuple = createTuple("S", "P", "O") ;
        Tuple<String> tuple2 = x.map(tuple) ;
        tuple2 = x.unmap(tuple2) ;
        assertEquals(tuple, tuple2) ;
    }
   
    @Test public void compile1()
    {
View Full Code Here


        ColumnMap cmap = new ColumnMap("GSPO", "OSPG") ;
        Tuple<String> tuple = createTuple("G", "S", "P", "O") ;
        Tuple<String> mapped = cmap.map(tuple) ;
        Tuple<String> expected = createTuple("O", "S", "P", "G") ;
        assertEquals(expected, mapped) ;
        Tuple<String> unmapped = cmap.unmap(mapped) ;
        assertEquals(createTuple("G", "S", "P", "O"), unmapped) ;
    }

    @Test public void map2()
    {
View Full Code Here

        Tuple<String> tuple = Tuple.create(x) ;
        Tuple<String> mapped = cmap.map(tuple) ;
       
        Tuple<String> expected = Tuple.create(y) ;
        assertEquals(expected, mapped) ;
        Tuple<String> unmapped = cmap.unmap(mapped) ;
        assertEquals(Tuple.create(x), unmapped) ;
    }
   
}
View Full Code Here

    @Test public void remap4()
    {
        ColumnMap x = new ColumnMap("POS", 2,0,1) ;
        Tuple<String> tuple = Tuple.create("S", "P", "O") ;
        Tuple<String> tuple2 = x.map(tuple) ;
        tuple2 = x.unmap(tuple2) ;
        assertEquals(tuple, tuple2) ;
    }
   
    @Test public void compile1()
    {
View Full Code Here

        ColumnMap cmap = new ColumnMap("GSPO", "OSPG") ;
        Tuple<String> tuple = Tuple.create("G", "S", "P", "O") ;
        Tuple<String> mapped = cmap.map(tuple) ;
        Tuple<String> expected = Tuple.create("O", "S", "P", "G") ;
        assertEquals(expected, mapped) ;
        Tuple<String> unmapped = cmap.unmap(mapped) ;
        assertEquals(Tuple.create("G", "S", "P", "O"), unmapped) ;
    }

    @Test public void map2()
    {
View Full Code Here

        Tuple<String> tuple = Tuple.create(x) ;
        Tuple<String> mapped = cmap.map(tuple) ;
       
        Tuple<String> expected = Tuple.create(y) ;
        assertEquals(expected, mapped) ;
        Tuple<String> unmapped = cmap.unmap(mapped) ;
        assertEquals(Tuple.create(x), unmapped) ;
    }
   
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.