endian11
2020-08-13 a927c72c0f06ef5bd771e5ae00bc35155c271762
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
package com.safeluck.aykj.decoder;
 
import com.safeluck.aykj.utils.BytesUtils;
 
/**
 * Created by zhouwei on 2016/12/1.
 */
public class BytesCoder extends BaseDecoder<Object> {
    @Override
    public Object decode(String str) {
        return BytesUtils.hexStringToBytes(str);
    }
 
    @Override
    public String encode(Object i) {
        byte[] bytes = (byte[])i;
        return BytesUtils.bytesToHexString(bytes);
    }
}