Package com.ryandw11.structure.io
Class NearbyStructuresRequest
java.lang.Object
com.ryandw11.structure.io.NearbyStructuresRequest
A request for retrieving structures near a location.
Submit this request to StructureDatabaseHandler.findNearby(NearbyStructuresRequest)
.
-
Constructor Summary
ConstructorDescriptionNearbyStructuresRequest(org.bukkit.Location location)
Request a single structure near the specified location.NearbyStructuresRequest(org.bukkit.Location location, int limit)
Request structures near a specified location.NearbyStructuresRequest(org.bukkit.Location location, Structure structure)
Request a single structure of a specific type near the specified location.NearbyStructuresRequest(org.bukkit.Location location, Structure structure, int limit)
Request structures of a certain type near a specified location.NearbyStructuresRequest(org.bukkit.Location location, String structureName)
Request a single structure of a specific type near the specified location.NearbyStructuresRequest(org.bukkit.Location location, String structureName, int limit)
Request structures of a certain type near a specified location. -
Method Summary
-
Constructor Details
-
NearbyStructuresRequest
public NearbyStructuresRequest(org.bukkit.Location location)Request a single structure near the specified location.- Parameters:
location
- The location.
-
NearbyStructuresRequest
Request a single structure of a specific type near the specified location.- Parameters:
location
- The location.structureName
- The name of the desired structure.
-
NearbyStructuresRequest
Request a single structure of a specific type near the specified location.- Parameters:
location
- The location.structure
- The desired structure.
-
NearbyStructuresRequest
public NearbyStructuresRequest(org.bukkit.Location location, int limit)Request structures near a specified location.- Parameters:
location
- The location.limit
- The number of structures to retrieve. (Not validated.)
-
NearbyStructuresRequest
Request structures of a certain type near a specified location.- Parameters:
location
- The location.structure
- The desired structure type.limit
- The number of structures to retrieve. (Not validated.)
-
NearbyStructuresRequest
Request structures of a certain type near a specified location.- Parameters:
location
- The location.structureName
- The desired structure type.limit
- The number of structures to retrieve. (Not validated.)
-
-
Method Details
-
getLocation
public org.bukkit.Location getLocation()Get the location of the request.- Returns:
- The location of the request.
-
getName
Get the name of the specified structure.- Returns:
- The name of the specified structure. (Null if not specified).
-
hasName
public boolean hasName()Check if a structure name is specified.- Returns:
- If a structure name is specified.
-
getLimit
public int getLimit()Get the limit of the request.- Returns:
- The limit of the request.
-