Citypublic interface ICity
| Modifier and Type | Method | Description |
|---|---|---|
void |
addBuildingPermission(IPlayer player) |
Add the bulidng permission for that player in the city.
|
void |
build(IBuilding building) |
Remove a building from the list of buildings in the city
|
<T extends IBuilding> |
findBuilding(java.lang.Class<T> buildingClass,
java.util.Optional<IPlayer> owner) |
Find all matching buildings in a city.
|
java.util.List<IBuilding> |
getBuildings() |
Retrieve a list of all buildings in the city.
|
java.util.List<ICitizen> |
getCitizen() |
Retrieve the list of citizen in the city.
|
CityState |
getCityState() |
Retrieve the city state.
|
int |
getContribution(IPlayer player,
IWare ware) |
Check out what the player contributed to the ware
|
javafx.geometry.Point2D |
getCoordinates() |
Retrieve the coordinates of the city
|
IWare[] |
getEffectiveProduction() |
Retrieve the wares that are produced efficiently
|
java.util.List<IWare> |
getImported() |
Retrieve the subset list of wares that are produced but are actually imported.
|
IWare[] |
getIneffectiveProduction() |
Retrieve the wares that are produced inefficiently
|
EKontorType |
getKontorType() |
Retrieve the city type
|
java.util.Map<IWare,java.time.LocalDateTime> |
getMissingWares() |
Retrieve the missing wares along with their times
|
java.lang.String |
getName() |
Retrieve the city name
|
java.lang.String |
getNameTemplate() |
Retrieve the non locale sepecific name template.
|
double |
getPercentageRoad() |
Retrieve the amount of road in the city.
|
int |
getPopulation(EPopulationClass popclass) |
Retrieve the current population of the city by class
|
javafx.beans.binding.IntegerBinding |
getPopulationBinding() |
Retrieve the binding of the city's total population.
|
javafx.beans.property.IntegerProperty |
getPopulationProperty(EPopulationClass popclass) |
Retrieve the population count for a class
|
IReputation |
getReputation(IPlayer player) |
Retrieve the reputation of the player in the city
|
java.util.List<IPlayer> |
getResidentPlayers() |
Retrieve all the players that have a office in this city.
|
java.lang.String |
getUniqueID() |
Retrieve the unique ID of the city.
|
AmountablePrice<IWare> |
getWare(IWare ware) |
Retrieve the amount of ware in the city
|
boolean |
hasBuildingPermission(IPlayer player) |
The player has building permission in this city.
|
boolean |
isRiverCity() |
Check if the city is on a river instead of the open sea.
|
int |
move(IWare ware,
int amount,
ICitizen player) |
Add or remove ware from the city.
|
void |
moveIn(IPlayer player,
IReputation reputaion,
Contributions contributions) |
Add a player to the city
|
void |
setCityState(CityState state) |
Set the city state
|
void |
setPopulation(int population,
EPopulationClass popClass) |
Set the population by class
|
void |
tearDown(IBuilding building) |
Add a new building to the city
|
java.lang.String getUniqueID()
EKontorType getKontorType()
java.lang.String getName()
int getPopulation(EPopulationClass popclass)
popclass - for which to retrieve the populationpopclassvoid setPopulation(int population,
EPopulationClass popClass)
population - size of the population of the specified popclasspopClass - population class for which to set the population.int move(IWare ware, int amount, ICitizen player)
ware - to be movedamount - of the ware that is movedplayer - that moved the wareIWare[] getIneffectiveProduction()
IWare[] getEffectiveProduction()
java.util.List<IBuilding> getBuildings()
void tearDown(IBuilding building)
building - building to be removed.void build(IBuilding building)
building - to be added as completedIReputation getReputation(IPlayer player)
player - for whom to retrieve the reputationvoid moveIn(IPlayer player, IReputation reputaion, Contributions contributions)
player - that is added to the cityreputaion - of that player in the citycontributions - contibutions of that player in the city.int getContribution(IPlayer player, IWare ware)
player - whose contribution is to be checkedware - that is checked for contributionjava.util.Map<IWare,java.time.LocalDateTime> getMissingWares()
javafx.geometry.Point2D getCoordinates()
java.util.List<IPlayer> getResidentPlayers()
CityState getCityState()
void setCityState(CityState state)
state - state of the city.AmountablePrice<IWare> getWare(IWare ware)
ware - for which to retrieve amount and pricejavafx.beans.property.IntegerProperty getPopulationProperty(EPopulationClass popclass)
popclass - population classpopclassjavafx.beans.binding.IntegerBinding getPopulationBinding()
java.util.List<ICitizen> getCitizen()
<T extends IBuilding> java.util.List<T> findBuilding(java.lang.Class<T> buildingClass, java.util.Optional<IPlayer> owner)
buildingClass - class of the buildingowner - search can be restricted to a player.java.lang.String getNameTemplate()
boolean isRiverCity()
java.util.List<IWare> getImported()
boolean hasBuildingPermission(IPlayer player)
player - for whom to check building permissionplayer has building permission.void addBuildingPermission(IPlayer player)
player - for whom to add a building permissiondouble getPercentageRoad()
Copyright © 2011-2018 Sahits GmbH. All Rights Reserved.