ICU-5407 Remove unused code

X-SVN-Rev: 20479
This commit is contained in:
George Rhoten 2006-10-03 21:16:54 +00:00
parent 31120cdfc4
commit 49e1ad7f8f
2 changed files with 0 additions and 70 deletions

View file

@ -1,68 +0,0 @@
/*
* *****************************************************************************
* Copyright (C) 2006, International Business Machines Corporation and others.
* All Rights Reserved.
* *****************************************************************************
*/
// dlf13 internal 1.3 compatibility only
package com.ibm.icu.impl;
/**
* @internal
*/
public final class ByteBuffer {
private byte[] data;
private int pos;
private int limit;
private ByteBuffer() {
}
public byte[] array() {
byte[] result = new byte[limit];
for (int i = 0; i < limit; ++i) {
result[i] = data[i];
}
return result;
}
public static ByteBuffer wrap(byte[] data) {
if (data == null)
throw new NullPointerException();
ByteBuffer result = new ByteBuffer();
result.data = data;
result.pos = 0;
result.limit = data.length;
return result;
}
public int limit() {
return limit;
}
public int remaining() {
return limit - pos;
}
public byte get() {
if (pos < limit)
return data[pos++];
throw new IndexOutOfBoundsException();
}
public void get(byte[] dst, int offset, int length) {
if (offset < 0 || offset + length > dst.length || pos + length > limit) {
throw new IndexOutOfBoundsException();
}
for (int i = 0; i < length; ++i) {
dst[offset++] = data[pos++];
}
}
public static final ByteBuffer allocate(int size){
ByteBuffer ret = new ByteBuffer();
ret.data = new byte[size];
return ret;
}
}

View file

@ -8,14 +8,12 @@ package com.ibm.icu.text;
import java.io.IOException;
import java.io.InputStream;
import java.io.ByteArrayInputStream;
import java.util.Locale;
import java.util.MissingResourceException;
import java.util.ResourceBundle;
import com.ibm.icu.impl.ICUData;
import com.ibm.icu.impl.ICULocaleData;
import com.ibm.icu.impl.ICULocaleService;
import com.ibm.icu.impl.ICUResourceBundle;
import com.ibm.icu.impl.ICUService;