import { Iter } from './iterators'; /** * Represents a collection of blocks that can be iterated and modified. * * Block collections may be backed by a region, a filtered view, an outline, * a floor, or any other lazily-generated set of blocks. */ export declare class BlockIterator extends Iter { /** * Iterates over the blocks in this collection. */ blocks(): IterableIterator; /** * Checks whether a block belongs to this collection. */ contains(block: org.bukkit.block.Block | org.bukkit.Location): boolean; /** * Sets every block in this collection to the given material. */ fill(material: org.bukkit.Material): this; /** * Replaces blocks matching the given predicate. */ replace(matcher: (block: org.bukkit.block.Block) => boolean, replacement: org.bukkit.Material): this; /** * Returns the number of blocks in this collection. * * Note that this iterates the collection. */ count(): number; /** * Filters the blocks in this collection with the given predicate. * @param predicate - The predicate to filter the blocks with. * @returns A new BlockIterator containing the filtered blocks. */ filter(predicate: (block: org.bukkit.block.Block) => boolean): BlockIterator; } /** * Represents a cuboid region within a single world. */ export declare class Region extends BlockIterator { private readonly world; private readonly minX; private readonly minY; private readonly minZ; private readonly maxX; private readonly maxY; private readonly maxZ; private constructor(); static between(pos1: org.bukkit.Location, pos2: org.bukkit.Location): Region; /** * Width of the region along the X axis. */ width(): number; /** * Height of the region along the Y axis. */ height(): number; /** * Depth of the region along the Z axis. */ depth(): number; /** * Number of blocks contained by the region. */ volume(): number; /** * Gets the center of the region. */ center(): org.bukkit.Location; /** * Checks whether a location lies inside the region. */ containsLocation(location: org.bukkit.Location): boolean; /** * Checks whether a block lies inside the region. * * Region can do this in constant time rather than iterating. */ contains(block: org.bukkit.block.Block): boolean; /** * Returns the bottom layer of the region. */ floor(): Region; /** * Returns the top layer of the region. */ ceiling(): Region; /** * Returns the four vertical walls of the region. */ walls(): BlockIterator; /** * Returns only blocks along the edges of the cuboid. */ outline(): BlockIterator; } export declare class Shapes { static sphere(center: org.bukkit.Location, radius: number): BlockIterator; }