Added Region.shift

- Provided a default implementation using expand+contract in AbstractRegion
- Overrid the implementation in the subtypes
This commit is contained in:
TomyLobo
2012-01-03 16:13:50 +01:00
parent 4d708a5003
commit 3a828c9759
6 changed files with 51 additions and 5 deletions

View File

@ -88,6 +88,14 @@ public interface Region extends Iterable<BlockVector> {
*/
public void contract(Vector change) throws RegionOperationException;
/**
* Shift the region.
*
* @param change
* @throws RegionOperationException
*/
public void shift(Vector multiply) throws RegionOperationException;
/**
* Returns true based on whether the region contains the point,
*