public class BMBand extends Band implements GenericDefinition, Serializable
| Constructor and Description |
|---|
BMBand(BMWorld world,
String name,
int numberOfLicenses,
int licenseCounter,
RNGSupplier rngSupplier)
Creates a new Band
Bands are automatically created when a new
BMWorld instance is created,
hence, the use of this constructor is not recommended. |
| Modifier and Type | Method and Description |
|---|---|
Set<Good> |
allLicenses() |
boolean |
equals(Object obj) |
Collection<BMLicense> |
getLicenses() |
int |
getNumberOfLicenses() |
BMWorld |
getWorld() |
long |
getWorldId() |
int |
hashCode() |
boolean |
isPartOf(Good license) |
int |
numberOfLicenses() |
void |
refreshFieldBackReferences(BMWorld world)
Method is called after deserialization, there is not need to call it on any other occasion.
See World.refreshFieldBackReferences() for explanations. |
com.google.gson.JsonElement |
shortJson() |
public BMBand(BMWorld world, String name, int numberOfLicenses, int licenseCounter, RNGSupplier rngSupplier)
BMWorld instance is created,
hence, the use of this constructor is not recommended.public BMWorld getWorld()
public Collection<BMLicense> getLicenses()
public int getNumberOfLicenses()
getNumberOfLicenses in class Bandpublic long getWorldId()
public void refreshFieldBackReferences(BMWorld world)
World.refreshFieldBackReferences() for explanations.world - the world this band belongs topublic boolean isPartOf(Good license)
isPartOf in interface GenericDefinitionGenericDefinition.isPartOf(Good)public int numberOfLicenses()
numberOfLicenses in interface GenericDefinitionGenericDefinition.numberOfLicenses()public Set<Good> allLicenses()
allLicenses in interface GenericDefinitionGenericDefinition.allLicenses()public com.google.gson.JsonElement shortJson()
shortJson in interface GenericDefinitionGenericDefinition.shortJson()Copyright © 2017. All rights reserved.