Added API to get the complete list of claims.

Returned list is read-only.
This commit is contained in:
ryanhamshire 2015-01-11 15:15:52 -08:00
parent 5e0d3f09de
commit bea31f340e

View File

@ -593,6 +593,14 @@ public abstract class DataStore
return null; return null;
} }
//returns a read-only access point for the list of all land claims
//if you need to make changes, use provided methods like .deleteClaim() and .createClaim().
//this will ensure primary memory (RAM) and secondary memory (disk, database) stay in sync
public Collection<Claim> getClaims()
{
return Collections.unmodifiableCollection(this.claims);
}
//gets a unique, persistent identifier string for a chunk //gets a unique, persistent identifier string for a chunk
private String getChunkString(Location location) private String getChunkString(Location location)
{ {