/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }
/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }
public Collection makeCollection() { return UnmodifiableBuffer.decorate(new UnboundedFifoBuffer()); }
public Collection makeFullCollection() { Buffer buffer = new UnboundedFifoBuffer(); buffer.addAll(Arrays.asList(getFullElements())); return UnmodifiableBuffer.decorate(buffer); }
/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }
/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }
/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }
/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }
/** * Returns an unmodifiable buffer backed by the given buffer. * * @param buffer the buffer to make unmodifiable, must not be null * @return an unmodifiable buffer backed by that buffer * @throws IllegalArgumentException if the Buffer is null */ public static Buffer unmodifiableBuffer(Buffer buffer) { return UnmodifiableBuffer.decorate(buffer); }