Package krati.io.serializer

Examples of krati.io.serializer.ShortSerializer


*/
public class TestShortSerializer2 extends TestShortSerializer {
   
    @Override
    protected ShortSerializer createSerializer() {
        return new ShortSerializer(ByteOrder.LITTLE_ENDIAN);
    }
View Full Code Here


*/
public class TestShortSerializer extends AbstractTestNumberSerializer<Short> {

    @Override
    protected ShortSerializer createSerializer() {
        return new ShortSerializer();
    }
View Full Code Here

    protected Short maxValue() {
        return Short.MAX_VALUE;
    }

    public void testCustomApi() {
        ShortSerializer serializer = createSerializer();
       
        short val = 0;
        assertEquals(val, serializer.shortValue(serializer.shortBytes(val)));
        val = minValue();
        assertEquals(val, serializer.shortValue(serializer.shortBytes(val)));
        val = maxValue();
        assertEquals(val, serializer.shortValue(serializer.shortBytes(val)));
        val = anyValue();
        assertEquals(val, serializer.shortValue(serializer.shortBytes(val)));
    }
View Full Code Here

TOP

Related Classes of krati.io.serializer.ShortSerializer

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.