|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mars_sim.msp.core.structure.building.function.Function
org.mars_sim.msp.core.structure.building.function.Manufacture
public class Manufacture
A building function for manufacturing.
| Field Summary | |
|---|---|
static String |
NAME
|
| Constructor Summary | |
|---|---|
Manufacture(Building building)
Constructor |
|
| Method Summary | |
|---|---|
void |
addProcess(ManufactureProcess process)
Adds a new manufacturing process to the building. |
void |
addSalvageProcess(SalvageProcess process)
Adds a new salvage process to the building. |
void |
destroy()
Prepare object for garbage collection. |
void |
endManufacturingProcess(ManufactureProcess process,
boolean premature)
Ends a manufacturing process. |
void |
endSalvageProcess(SalvageProcess process,
boolean premature)
Ends a salvage process. |
int |
getConcurrentProcesses()
Gets the maximum concurrent manufacturing processes supported by the building. |
double |
getFullPowerRequired()
Gets the amount of power required when function is at full power. |
static double |
getFunctionValue(String buildingName,
boolean newBuilding,
Settlement settlement)
Gets the value of the function for a named building. |
double |
getPowerDownPowerRequired()
Gets the amount of power required when function is at power down level. |
List<ManufactureProcess> |
getProcesses()
Gets a list of the current manufacturing processes. |
List<SalvageProcess> |
getSalvageProcesses()
Gets a list of the current salvage processes. |
int |
getTechLevel()
Gets the manufacturing tech level of the building. |
int |
getTotalProcessNumber()
Gets the total manufacturing and salvage processes currently in this building. |
boolean |
requiresManufacturingWork(int skill)
Checks if manufacturing function currently requires manufacturing work. |
boolean |
requiresSalvagingWork(int skill)
Checks if manufacturing function currently requires salvaging work. |
void |
timePassing(double time)
Time passing for the building. |
| Methods inherited from class org.mars_sim.msp.core.structure.building.function.Function |
|---|
getBuilding, getMalfunctionScopeStrings, getName, removeFromSettlement |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String NAME
| Constructor Detail |
|---|
public Manufacture(Building building)
building - the building the function is for.
BuildingException - if error constructing function.| Method Detail |
|---|
public static double getFunctionValue(String buildingName,
boolean newBuilding,
Settlement settlement)
buildingName - the building name.newBuilding - true if adding a new building.settlement - the settlement.
Exception - if error getting function value.public int getTechLevel()
public int getConcurrentProcesses()
public int getTotalProcessNumber()
public List<ManufactureProcess> getProcesses()
public void addProcess(ManufactureProcess process)
process - the new manufacturing process.
BuildingException - if error adding process.public List<SalvageProcess> getSalvageProcesses()
public void addSalvageProcess(SalvageProcess process)
process - the new salvage process.
BuildingException - if error adding process.public double getFullPowerRequired()
Function
getFullPowerRequired in class Functionpublic double getPowerDownPowerRequired()
Function
getPowerDownPowerRequired in class Functionpublic void timePassing(double time)
Function
timePassing in class Functiontime - amount of time passing (in millisols)public boolean requiresManufacturingWork(int skill)
skill - the person's materials science skill level.
public boolean requiresSalvagingWork(int skill)
skill - the person's materials science skill level.
public void endManufacturingProcess(ManufactureProcess process,
boolean premature)
process - the process to end.premature - true if the process has ended prematurely.
BuildingException - if error ending process.
public void endSalvageProcess(SalvageProcess process,
boolean premature)
process - the process to end.premature - true if process is ended prematurely.
BuildingException - if error ending process.public void destroy()
Function
destroy in class Function
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||