@Override
    public long readLong(@Nonnull String fieldName) throws IOException {
        FieldDefinition fd = cd.getField(fieldName);
        if (fd == null) {
            return 0L;
        }
        switch (fd.getType()) {
            case LONG:
                return super.readLong(fieldName);
            case INT:
                return super.readInt(fieldName);
            case BYTE:
                return super.readByte(fieldName);
            case CHAR:
                return super.readChar(fieldName);
            case SHORT:
                return super.readShort(fieldName);
            default:
                throw createIncompatibleClassChangeError(fd, LONG);
        }
    }
@Test
    public void testReadLong() throws Exception {
        long aByte = reader.readLong("byte");
        long aShort = reader.readLong("short");
        long aChar = reader.readLong("char");
        long aInt = reader.readLong("int");
        long aLong = reader.readLong("long");

        assertEquals(1, aByte);
        assertEquals(3, aShort);
        assertEquals(2, aChar);
        assertEquals(4, aInt);
        assertEquals(5, aLong);
        assertEquals(0, reader.readLong("NO SUCH FIELD"));

    }