All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.wechat.sdk.aes.ByteGroup Maven / Gradle / Ivy

Go to download

WeChat Software Development Kit,Note:This artifact is abandoned,Please use com.github.okeyj:wechat-sdk:1.0.0

The newest version!
package com.github.wechat.sdk.aes;

import java.util.ArrayList;

/**
 * Created by liuchunlong on 17-1-24.
 */
public class ByteGroup {

    private ArrayList byteContainer = new ArrayList();//字节容器

    public byte[] toBytes() {
        byte[] bytes = new byte[byteContainer.size()];
        for (int i = 0; i < byteContainer.size(); i++) {
            bytes[i] = byteContainer.get(i);
        }
        return bytes;
    }

    public ByteGroup addBytes(byte[] bytes) {
        for (byte b : bytes) {
            byteContainer.add(b);
        }
        return this;
    }

    public int size() {
        return byteContainer.size();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy