[]
        
(Showing Draft Content)

IAreas

Interface IAreas

All Superinterfaces:
Iterable<IRange>

public interface IAreas extends Iterable<IRange>
Represents a collection of range areas. Each area represents a single contiguous range of one or more cells.

 IRange range = worksheet.getRange("A1:B2,D1:E2");
 IAreas areas = range.getAreas();
 int areaCount = areas.getAreaCount();
 
  • Method Summary

    Modifier and Type
    Method
    Description
    getArea(int index)
    Returns the zero based instance of IRange specified by index.
    int
    Returns the number of instances of IRange represented by this area.

    Methods inherited from interface java.lang.Iterable

    forEach, iterator, spliterator
  • Method Details

    • getAreaCount

      int getAreaCount()
      Returns the number of instances of IRange represented by this area.
      
       IRange range = worksheet.getRange("A1:B2,D1:E2");
       IAreas areas = range.getAreas();
       int areaCount = areas.getAreaCount();
       
      Returns:
      The number of instances of IRange represented by this area.
    • getArea

      IRange getArea(int index)
      Returns the zero based instance of IRange specified by index.
      
       IRange range = worksheet.getRange("A1:B2,D1:E2");
       IAreas areas = range.getAreas();
       IRange secondArea = areas.getArea(1);
       secondArea.setValue("Reviewed");
       
      Parameters:
      index - The zero-based index of the area to return.
      Returns:
      The zero-based IRange instance specified by index.