我完全難倒..好像有會成爲一個簡單的解決方案無法分配的getBytes()以字節數組
private Byte[] arrayOfBytes = null;
public Data(String input) {
arrayOfBytes = new Byte[input.getBytes().length];
arrayOfBytes = input.getBytes();
}
拋出follwing錯誤:從字符串
incompatible types
required: java.lang.Byte[]
found: byte[]
自動裝箱只是處理值的轉換不是類型轉換 – Kennet 2012-02-16 19:24:31