Example usage for com.google.common.collect ForwardingSortedSet ForwardingSortedSet

List of usage examples for com.google.common.collect ForwardingSortedSet ForwardingSortedSet

Introduction

In this page you can find the example usage for com.google.common.collect ForwardingSortedSet ForwardingSortedSet.

Prototype

protected ForwardingSortedSet() 

Source Link

Document

Constructor for use by subclasses.

Usage

From source file:org.joda.collect.grid.SparseGrid.java

@Override
public SortedSet<Cell<V>> cells() {
    return new ForwardingSortedSet<Cell<V>>() {
        @Override//w w  w.  j av a2  s  .  co m
        protected SortedSet<Cell<V>> delegate() {
            return cells;
        }

        @Override
        public boolean add(Cell<V> element) {
            return super.add(ImmutableCell.copyOf(element));
        }

        @Override
        public boolean addAll(Collection<? extends Cell<V>> collection) {
            return super.standardAddAll(collection);
        }
    };
}