mantis-remote-observable/src/main/java/io/reactivex/netty/codec/Codecs.java [29:42]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public static Codec<Integer> integer() {

        return new Codec<Integer>() {
            @Override
            public Integer decode(byte[] bytes) {
                return ByteBuffer.wrap(bytes).getInt();
            }

            @Override
            public byte[] encode(final Integer value) {
                return ByteBuffer.allocate(4).putInt(value).array();
            }
        };
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



mantis-common/src/main/java/io/mantisrx/common/codec/Codecs.java [33:46]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public static Codec<Integer> integer() {

        return new Codec<Integer>() {
            @Override
            public Integer decode(byte[] bytes) {
                return ByteBuffer.wrap(bytes).getInt();
            }

            @Override
            public byte[] encode(final Integer value) {
                return ByteBuffer.allocate(4).putInt(value).array();
            }
        };
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



