Package mondrian.util

Interface SpatialValueTree2.SpatialRegion

  • Enclosing interface:
    SpatialValueTree2

    public static interface SpatialValueTree2.SpatialRegion
    • Method Detail

      • getCellValue

        Object getCellValue​(Map<SpatialValueTree2.SpatialDimension,​Object> coordinates)
        Returns the value of a cell.

        Assumes that this region body is valid for the request. (That is, SpatialValueTree2.SpatialRegionRequest.mightContainCell(java.util.Map) would return true.) For example, suppose that the region request was

        (gender=M, year=any, measure=sales)
        this region body is
        (gender=M, year={2009, 2010}, measure=sales)
        and the cell coordinates are
        (gender=F, year=2009, measure=sales)

        Because the coordinate 'gender=F' falls outside the region request, behavior is unspecified. The implementation might return null, throw an error, or return a value for the cell (gender=M, year=2009, measure=sales); any of these behaviors would be valid.

        Parameters:
        coordinates - Value for each dimension
        Returns:
        cell value
      • getCellValueInt

        int getCellValueInt​(Map<SpatialValueTree2.SpatialDimension,​Object> coordinates,
                            boolean[] wasNull)
        Version of getCellValue(java.util.Map) optimized for int values.

        If value is null, writes 'true' into wasNull[0] and returns 0. Otherwise, does not modify wasNull.

        Parameters:
        coordinates - Value of each dimension
        wasNull - 1-element array to be informed if value was null
        Returns:
        Value, or 0 if value is null
      • getCellValueDouble

        double getCellValueDouble​(Map<SpatialValueTree2.SpatialDimension,​Object> coordinates,
                                  boolean[] wasNull)
        Version of getCellValue(java.util.Map) optimized for double values.

        If value is null, writes 'true' into wasNull[0] and returns 0. Otherwise, does not modify wasNull.

        Parameters:
        coordinates - Value of each dimension
        wasNull - 1-element array to be informed if value was null
        Returns:
        Value, or 0 if value is null