DISPLACE
1.0
A spatial model of fisheries to help sustainable fishing and maritime spatial planning
|
#include <displacemodel.h>
Public Types | |
enum | ModelType { LiveModelType, EditorModelType, OfflineModelType, EmptyModelType } |
enum | SpecialGroups { Total, Average, Min, Max, LastSpecialGroup } |
typedef HistoricalDataCollector< BenthosStats > | BenthosStatsContainer |
typedef HistoricalDataCollector< FishfarmsStats > | FishfarmsStatsContainer |
typedef HistoricalDataCollector< ShipsStats > | ShipsStatsContainer |
Signals | |
void | parseOutput (QString, int) |
void | outputParsed () |
void | errorParsingStatsFile (QString) |
Public Member Functions | |
DisplaceModel () | |
~DisplaceModel () | |
ModelType | modelType () const |
MapsDataProvider & | getMapDataProvider () |
bool | edit (QString modelname) |
void | setIndex (int idx) |
int | index () const |
bool | load (QString path, ModelType type) |
bool | loadDatabase (QString path) |
bool | clearStats () |
bool | saveScenarioAs (const QString &path) |
bool | saveScenario () |
bool | saveConfig () |
std::shared_ptr< Calendar > | calendar () const |
void Q_DECL_DEPRECATED | simulationEnded () |
Signals the simulation has ended. Flush all buffers. More... | |
QString | fullpath () const |
QString | outDir () const |
QString | inputName () const |
QString | basepath () const |
QString | outputName () const |
void | setOutDir (const QString &name) |
void | setOutputName (const QString &name) |
QString | simulationName () const |
void | setSimulationName (const QString &name) |
void | setSimulationSqlStorage (const QString &path) |
QString | linkedDatabase () const |
bool | isModelLoaded () const |
int | getNBPops () const |
int | getNBBenthosPops () const |
int | getSzGrupsCount () const |
int | getBenthosIdx (int benthosId) const |
QString | getOutDir () const |
int | getSimulationSteps () const |
void | setSimulationSteps (int value) |
int | getUseStaticPaths () const |
void | setUseStaticPaths (int value) |
const QList< std::shared_ptr< HarbourData > > & | getHarboursList () const |
int | getHarboursCount () const |
QString | getHarbourId (int idx) const |
const QList< std::shared_ptr< NodeData > > & | getNodesList () const |
int | getNodesCount () const |
QString | getNodeId (int idx) const |
QList< std::shared_ptr< NodeData > > | getAllNodesWithin (const QPointF ¢erpoint, double dist_km) const |
void | updateNodesStatFromSimu (QString) |
receive a Stats update for nodes from the Simulator More... | |
const QList< std::shared_ptr< VesselData > > & | getVesselList () const |
int | getVesselCount () const |
QString | getVesselId (int idx) const |
void | updateVessel (int tstep, int idx, float x, float y, float course, float fuel, int state) |
const QList< std::shared_ptr< FishfarmData > > & | getFishfarmList () const |
int | getFishfarmsCount () const |
QString | getFishfarmId (int idx) const |
void | updateFishfarm (int idx, float x, float y) |
const QList< std::shared_ptr< FirmData > > & | getFirmList () const |
int | getFirmCount () const |
QString | getFirmId (int idx) const |
void | updateFirm (int idx, float x, float y) |
const QList< std::shared_ptr< WindmillData > > & | getWindmillList () const |
int | getWindmillCount () const |
QString | getWindmillId (int idx) const |
void | updateWindmill (int idx, float x, float y) |
const QList< std::shared_ptr< ShipData > > & | getShipList () const |
int | getShipsCount () const |
QString | getShipId (int idx) const |
void | updateShip (int tstep, int idx, float x, float y, float course) |
const QList< std::shared_ptr< Benthos > > & | getBenthosList () const |
int | getBenthosCount () const |
const QList< std::shared_ptr< objecttree::MetiersInterest > > & | getMetiersList () const |
int | getMetiersCount () const |
void | addMetier (int id) |
int | getPopulationsCount () const |
int | getBenthosPopulationsCount () const |
const QList< std::shared_ptr< PopulationData > > & | getPopulationsList () const |
const PopulationData & | getPop (int idx) const |
const QList< std::shared_ptr< NationData > > & | getNationsList () const |
const NationData & | getNation (int idx) const |
const QList< std::shared_ptr< VesselData > > & | getVesselsList () const |
const VesselData & | getVessel (int idx) const |
const QList< std::shared_ptr< HarbourData > > & | getHarbourList () const |
const HarbourData & | getHarbourData (int idx) const |
HarbourStats | retrieveHarbourIdxStatAtStep (int idx, int step) |
const BenthosStatsContainer & | getBenthosStatistics () |
const FishfarmsStatsContainer & | getFishfarmsStatistics () |
const ShipsStatsContainer & | getShipsStatistics () |
Scenario | scenario () const |
void | setScenario (const Scenario &scenario) |
Config | config () const |
void | setConfig (const Config &config) |
const QMap< QString, int > | getStockNames () const |
void | setStockNames (const QMap< QString, int > &names) |
void | setCurrentStep (int step) |
int | getCurrentStep () const |
int | getLastStep () const |
const QList< int > & | getInterestingPops () const |
const QList< int > & | getInterestingPops2 () const |
void | setInterestingPop (int n) |
insert the pop into the list of interest for pops More... | |
void | setInterestingPop2 (int n) |
void | remInterestingPop (int n) |
remove the pop from the list of interest for pops More... | |
void | remInterestingPop2 (int n) |
bool | isInterestingPop (int n) |
bool | isInterestingPop2 (int n) |
void | clearInterestingPop () |
void | clearInterestingPop2 () |
QList< int > | getInterestingBenthos () const |
void | setInterestingBenthos (int n) |
void | remInterestingBenthos (int n) |
bool | isInterestingBenthos (int n) const |
void | clrInterestingBenthos () |
QList< int > | getInterestingFishfarms () const |
void | setInterestingFishfarms (int n) |
void | remInterestingFishfarms (int n) |
bool | isInterestingFishfarms (int n) const |
void | clrInterestingFishfarms () |
QList< int > | getInterestingWindfarms () const |
void | setInterestingWindfarms (int n) |
void | remInterestingWindfarms (int n) |
bool | isInterestingWindfarms (int n) const |
void | clrInterestingWindfarms () |
QList< int > | getInterestingShips () const |
void | setInterestingShips (int n) |
void | remInterestingShips (int n) |
bool | isInterestingShips (int n) const |
void | clrInterestingShips () |
bool | isInterestingSizeTotal () const |
void | setInterestingSizeTotal (bool b) |
bool | isInterestingSizeAvg () const |
void | setInterestingSizeAvg (bool b) |
bool | isInterestingSizeMin () const |
void | setInterestingSizeMin (bool b) |
bool | isInterestingSizeMax () const |
void | setInterestingSizeMax (bool b) |
const QList< int > & | getInterestingSizes () const |
int | getNumFuncGroups () const |
std::shared_ptr< InterestingListWithSpecialValues< int > > | getFunctionalGroupsList () const |
int | getNumFishfarmsTypes () const |
std::shared_ptr< InterestingListWithSpecialValues< int > > | getFishfarmsTypesList () const |
int | getNumWindfarmsTypes () const |
std::shared_ptr< InterestingListWithSpecialValues< int > > | getWindfarmsTypesList () const |
int | getNumShipsTypes () const |
std::shared_ptr< InterestingListWithSpecialValues< int > > | getShipsTypesList () const |
void | setInterestingSize (int n) |
insert the pop into the list of interest for pops More... | |
void | remInterestingSize (int n) |
remove the pop from the list of interest for pops More... | |
bool | isInterestingSize (int n) |
const QList< types::NodeId > & | getInterestingHarbours () const |
void | setInterestingHarb (types::NodeId n) |
insert the pop into the list of interest for pops More... | |
void | remInterestingHarb (types::NodeId n) |
remove the pop from the list of interest for pops More... | |
bool | isInterestingHarb (types::NodeId n) |
const QList< int > & | getInterestingNations () const |
void | setInterestingNations (int n) |
insert the pop into the list of interest for pops More... | |
void | remInterestingNations (int n) |
remove the pop from the list of interest for pops More... | |
bool | isInterestingNations (int n) |
const QList< int > & | getInterestingVessels () const |
void | setInterestingVessels (int n) |
void | remInterestingVessels (int n) |
remove the pop from the list of interest for pops More... | |
bool | isInterestingVessels (int n) |
QString | getLastError () const |
void | parseOutputStatsFile (QString file, int tstep) |
void | commitNodesStatsFromSimu (int tstep, bool force=false) |
void | startCollectingStats () |
void | endCollectingStats () |
void | collectNodePopStats (int tstep, int node_idx, const QList< double > &stats, const QList< double > &stats_w, double tot, double wtot) |
void | collectPopCumftime (int step, int node_idx, double cumftime) |
void | collectPopCumsweptarea (int step, int node_idx, double cumsweptarea) |
void | collectPopCumsubsurfacesweptarea (int step, int node_idx, double cumsubsurfacesweptarea) |
void | collectPopCumcatches (int step, int node_idx, double cumcatches) |
void | collectPopCumcatchesWithThreshold (int step, int node_idx, double cumcatches_with_threshold) |
void | collectPopCumdiscards (int step, int node_idx, double cumdiscards) |
void | collectPopCumdiscardsratio (int step, int node_idx, double cumdiscardsratio) |
void | collectPopNbchoked (int step, int node_idx, double nbchoked) |
void | collectPopTariffs (int step, int node_idx, vector< double > tariffs) |
void | collectPopImpact (int step, int node_idx, int popid, double impact) |
void | collectPopCumcatchesPerPop (int step, int node_idx, int popid, double cumcatchesperpop) |
void | collectSalinity (int step, int node_idx, double salinity) |
void | collectWind (int step, int node_idx, double wind) |
void | collectSST (int step, int node_idx, double sst) |
void | collectNitrogen (int step, int node_idx, double nitrogen) |
void | collectPhosphorus (int step, int node_idx, double phosphorus) |
void | collectOxygen (int step, int node_idx, double oxygen) |
void | collectDissolvedCarbon (int step, int node_idx, double dissolvedcarbon) |
void | collectBathymetry (int step, int node_idx, double bathymetry) |
void | collectShippingdensity (int step, int node_idx, double shippingdensity) |
void | collectSiltfraction (int step, int node_idx, double siltfraction) |
void | collectPopBenthosBiomass (int step, int node_idx, int funcid, double benthosbiomass) |
void | collectPopBenthosNumber (int step, int node_idx, int funcid, double benthosnumber) |
void | collectPopBenthosMeanWeight (int step, int node_idx, int funcid, double meanweight) |
void | collectPopBenthosBiomassOverK (int step, int node_idx, int funcid, double benthosbiomassoverK) |
void | collectPopBenthosNumberOverK (int step, int node_idx, int funcid, double benthosnumberoverK) |
void | commitPopBenthosStats (int tstep) |
void | collectFishfarmFishMeanWeight (int step, int node_idx, int farmid, int farmtype, double meanw_kg) |
void | collectFishfarmFishHarvestedKg (int step, int node_idx, int farmid, int farmtype, double fish_harvested_kg) |
void | collectFishfarmEggsHarvestedKg (int step, int node_idx, int farmid, int farmtype, double eggs_harvested_kg) |
void | collectFishfarmAnnualProfit (int step, int node_idx, int farmid, int farmtype, double fishfarm_annualprofit) |
void | collectFishfarmNetDischargeN (int step, int node_idx, int farmid, int farmtype, double fishfarm_netdischargeN) |
void | collectFishfarmNetDischargeP (int step, int node_idx, int farmid, int farmtype, double fishfarm_netdischargeP) |
void | collectFishfarmCumulNetDischargeN (int step, int node_idx, int farmid, int farmtype, double fishfarm_cumulnetdischargeN) |
void | collectFishfarmCumulNetDischargeP (int step, int node_idx, int farmid, int farmtype, double fishfarm_cumulnetdischargeP) |
void | commitFishfarmsStats (int tstep) |
void | collectShipNbTransportedUnits (int step, int node_idx, int shipid, int shiptype, double nb_transported_units) |
void | collectShipFuelUseHour (int step, int node_idx, int shipid, int shiptype, double fuel_use_h) |
void | collectShipNOxEmissiongPerkW (int step, int node_idx, int shipid, int shiptype, double NOx_emission_gperkW) |
void | collectShipSOxEmissionPercentPerTotalFuelmass (int step, int node_idx, int shipid, int shiptype, double SOx_emission_percentpertotalfuelmass) |
void | collectShipGHGemissiongPerkW (int step, int node_idx, int shipid, int shiptype, double GHG_emission_gperkW) |
void | collectShipPMEemissiongPerkW (int step, int node_idx, int shipid, int shiptype, double PME_emission_gperkW) |
void | collectShipfuelUseLitre (int step, int node_idx, int shipid, int shiptype, double fuel_use_litre) |
void | collectShipNOxEmission (int step, int node_idx, int shipid, int shiptype, double NOx_emission) |
void | collectShipSOxEmission (int step, int node_idx, int shipid, int shiptype, double SOx_emission) |
void | collectShipGHGemission (int step, int node_idx, int shipid, int shiptype, double GHG_emission) |
void | collectShipPMEemission (int step, int node_idx, int shipid, int shiptype, double PME_emission) |
void | commitShipsStats (int tstep) |
void | collectVesselStats (int step, const VesselStats &stats) |
void | commitVesselsStats (int tstep) |
void | clearAllNodes () |
bool | addGraph (const QList< GraphBuilder::Node > &points, MapObjectsController *controller) |
bool | removeNode (std::shared_ptr< NodeData > node) |
int | addEdge (std::shared_ptr< NodeData > nodedata, types::NodeId targetidx, double weight) |
DisplaceModel::addEdge. More... | |
int | addEdge (types::NodeId srcidx, types::NodeId targetidx, double weight) |
DisplaceModel::addEdge. More... | |
bool | exportGraph (const QString &path) |
bool | importHarbours (QList< std::shared_ptr< HarbourData > > &list) |
void | addPenaltyToNodesByAddWeight (const QList< QPointF > &poly, double weight, double nbOfDaysClosedPerMonth, bool onQ1, bool onQ2, bool onQ3, bool onQ4, vector< bool > checkedMonths, const vector< int > &checkedVesSizes, vector< int > bannedMetiers) |
void | addPenaltyToNodesByAddWeight (OGRGeometry *geometry, double weight, double nbOfDaysClosedPerMonth, bool onQ1, bool onQ2, bool onQ3, bool onQ4, vector< bool > checkedMonths, const vector< int > &checkedVesSizes, vector< int > bannedMetiers) |
const QList< displace::NodePenalty > | getPenaltyCollection () const |
bool | isShortestPathFolderLinked () const |
void | linkShortestPathFolder (QString path) |
QString | linkedShortestPathFolder () const |
bool | isGraphFolderLinked () const |
void | linkGraphFolder (QString path) |
QString | linkedGraphFolder () const |
void | setLandscapeCodesFromFeature (OGRGeometry *geometry, int code) |
void | setWindFromFeature (OGRGeometry *geometry, double wind) |
void | setSSTFromFeature (OGRGeometry *geometry, double sst) |
void | setSalinityFromFeature (OGRGeometry *geometry, double psu) |
void | setNitrogenFromFeature (OGRGeometry *geometry, double nit) |
void | setPhosphorusFromFeature (OGRGeometry *geometry, double phos) |
void | setOxygenFromFeature (OGRGeometry *geometry, double oxygen) |
void | setDissolvedCarbonFromFeature (OGRGeometry *geometry, double dissc) |
void | setBenthosBiomassFromFeature (OGRGeometry *geometry, double bio) |
void | setBenthosNumberFromFeature (OGRGeometry *geometry, double nb) |
void | setAreaCodesFromFeature (OGRGeometry *geometry, int code) |
std::shared_ptr< SQLiteOutputStorage > | getOutputStorage () const |
Protected Member Functions | |
bool | loadNodes () |
bool | loadVessels () |
bool | loadGraphs () |
bool | initShips () |
bool | initFirm () |
bool | initFishfarm () |
bool | initWindmill () |
bool | initBenthos () |
bool | initPopulations () |
bool | initNations () |
void | createFeaturesLayer () |
bool | loadNodesFromDb () |
bool | loadVesselsFromDb () |
bool | loadFishfarmsFromDb () |
void | checkStatsCollection (int tstep) |
bool | parse (const QString &path, QString *basepath, QString *inputname, QString *outputname) |
void | setCodeFromFeature (OGRGeometry *geometry, int code, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setWdFromFeature (OGRGeometry *geometry, double wd, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setTFromFeature (OGRGeometry *geometry, double t, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setSalFromFeature (OGRGeometry *geometry, double sal, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setNitroFromFeature (OGRGeometry *geometry, double sal, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setPhosFromFeature (OGRGeometry *geometry, double sal, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setOxyFromFeature (OGRGeometry *geometry, double sal, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setDissoFromFeature (OGRGeometry *geometry, double sal, std::function< void(std::shared_ptr< NodeData >, int)> func) |
void | setBenthosBioFromFeature (OGRGeometry *geometry, double bio, std::function< void(std::shared_ptr< NodeData >, double)> func) |
void | setBenthosNbFromFeature (OGRGeometry *geometry, double bio, std::function< void(std::shared_ptr< NodeData >, double)> func) |
DisplaceModel::DisplaceModel | ( | ) |
DisplaceModel::~DisplaceModel | ( | ) |
int DisplaceModel::addEdge | ( | std::shared_ptr< NodeData > | nodedata, |
types::NodeId | targetidx, | ||
double | weight | ||
) |
int DisplaceModel::addEdge | ( | types::NodeId | srcidx, |
types::NodeId | targetidx, | ||
double | weight | ||
) |
bool DisplaceModel::addGraph | ( | const QList< GraphBuilder::Node > & | points, |
MapObjectsController * | controller | ||
) |
void DisplaceModel::addMetier | ( | int | id | ) |
void DisplaceModel::addPenaltyToNodesByAddWeight | ( | const QList< QPointF > & | poly, |
double | weight, | ||
double | nbOfDaysClosedPerMonth, | ||
bool | onQ1, | ||
bool | onQ2, | ||
bool | onQ3, | ||
bool | onQ4, | ||
vector< bool > | checkedMonths, | ||
const vector< int > & | checkedVesSizes, | ||
vector< int > | bannedMetiers | ||
) |
void DisplaceModel::addPenaltyToNodesByAddWeight | ( | OGRGeometry * | geometry, |
double | weight, | ||
double | nbOfDaysClosedPerMonth, | ||
bool | onQ1, | ||
bool | onQ2, | ||
bool | onQ3, | ||
bool | onQ4, | ||
vector< bool > | checkedMonths, | ||
const vector< int > & | checkedVesSizes, | ||
vector< int > | bannedMetiers | ||
) |
|
inline |
|
inline |
|
protected |
void DisplaceModel::clearAllNodes | ( | ) |
void DisplaceModel::clearInterestingPop | ( | ) |
void DisplaceModel::clearInterestingPop2 | ( | ) |
bool DisplaceModel::clearStats | ( | ) |
|
inline |
|
inline |
|
inline |
|
inline |
void DisplaceModel::collectBathymetry | ( | int | step, |
int | node_idx, | ||
double | bathymetry | ||
) |
void DisplaceModel::collectDissolvedCarbon | ( | int | step, |
int | node_idx, | ||
double | dissolvedcarbon | ||
) |
void DisplaceModel::collectFishfarmAnnualProfit | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | fishfarm_annualprofit | ||
) |
void DisplaceModel::collectFishfarmCumulNetDischargeN | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | fishfarm_cumulnetdischargeN | ||
) |
void DisplaceModel::collectFishfarmCumulNetDischargeP | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | fishfarm_cumulnetdischargeP | ||
) |
void DisplaceModel::collectFishfarmEggsHarvestedKg | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | eggs_harvested_kg | ||
) |
void DisplaceModel::collectFishfarmFishHarvestedKg | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | fish_harvested_kg | ||
) |
void DisplaceModel::collectFishfarmFishMeanWeight | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | meanw_kg | ||
) |
void DisplaceModel::collectFishfarmNetDischargeN | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | fishfarm_netdischargeN | ||
) |
void DisplaceModel::collectFishfarmNetDischargeP | ( | int | step, |
int | node_idx, | ||
int | farmid, | ||
int | farmtype, | ||
double | fishfarm_netdischargeP | ||
) |
void DisplaceModel::collectNitrogen | ( | int | step, |
int | node_idx, | ||
double | nitrogen | ||
) |
void DisplaceModel::collectNodePopStats | ( | int | tstep, |
int | node_idx, | ||
const QList< double > & | stats, | ||
const QList< double > & | stats_w, | ||
double | tot, | ||
double | wtot | ||
) |
void DisplaceModel::collectOxygen | ( | int | step, |
int | node_idx, | ||
double | oxygen | ||
) |
void DisplaceModel::collectPhosphorus | ( | int | step, |
int | node_idx, | ||
double | phosphorus | ||
) |
void DisplaceModel::collectPopBenthosBiomass | ( | int | step, |
int | node_idx, | ||
int | funcid, | ||
double | benthosbiomass | ||
) |
void DisplaceModel::collectPopBenthosBiomassOverK | ( | int | step, |
int | node_idx, | ||
int | funcid, | ||
double | benthosbiomassoverK | ||
) |
void DisplaceModel::collectPopBenthosMeanWeight | ( | int | step, |
int | node_idx, | ||
int | funcid, | ||
double | meanweight | ||
) |
void DisplaceModel::collectPopBenthosNumber | ( | int | step, |
int | node_idx, | ||
int | funcid, | ||
double | benthosnumber | ||
) |
void DisplaceModel::collectPopBenthosNumberOverK | ( | int | step, |
int | node_idx, | ||
int | funcid, | ||
double | benthosnumberoverK | ||
) |
void DisplaceModel::collectPopCumcatches | ( | int | step, |
int | node_idx, | ||
double | cumcatches | ||
) |
void DisplaceModel::collectPopCumcatchesPerPop | ( | int | step, |
int | node_idx, | ||
int | popid, | ||
double | cumcatchesperpop | ||
) |
void DisplaceModel::collectPopCumcatchesWithThreshold | ( | int | step, |
int | node_idx, | ||
double | cumcatches_with_threshold | ||
) |
void DisplaceModel::collectPopCumdiscards | ( | int | step, |
int | node_idx, | ||
double | cumdiscards | ||
) |
void DisplaceModel::collectPopCumdiscardsratio | ( | int | step, |
int | node_idx, | ||
double | cumdiscardsratio | ||
) |
void DisplaceModel::collectPopCumftime | ( | int | step, |
int | node_idx, | ||
double | cumftime | ||
) |
void DisplaceModel::collectPopCumsubsurfacesweptarea | ( | int | step, |
int | node_idx, | ||
double | cumsubsurfacesweptarea | ||
) |
void DisplaceModel::collectPopCumsweptarea | ( | int | step, |
int | node_idx, | ||
double | cumsweptarea | ||
) |
void DisplaceModel::collectPopImpact | ( | int | step, |
int | node_idx, | ||
int | popid, | ||
double | impact | ||
) |
void DisplaceModel::collectPopNbchoked | ( | int | step, |
int | node_idx, | ||
double | nbchoked | ||
) |
void DisplaceModel::collectPopTariffs | ( | int | step, |
int | node_idx, | ||
vector< double > | tariffs | ||
) |
void DisplaceModel::collectSalinity | ( | int | step, |
int | node_idx, | ||
double | salinity | ||
) |
void DisplaceModel::collectShipFuelUseHour | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | fuel_use_h | ||
) |
void DisplaceModel::collectShipfuelUseLitre | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | fuel_use_litre | ||
) |
void DisplaceModel::collectShipGHGemission | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | GHG_emission | ||
) |
void DisplaceModel::collectShipGHGemissiongPerkW | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | GHG_emission_gperkW | ||
) |
void DisplaceModel::collectShipNbTransportedUnits | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | nb_transported_units | ||
) |
void DisplaceModel::collectShipNOxEmission | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | NOx_emission | ||
) |
void DisplaceModel::collectShipNOxEmissiongPerkW | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | NOx_emission_gperkW | ||
) |
void DisplaceModel::collectShippingdensity | ( | int | step, |
int | node_idx, | ||
double | shippingdensity | ||
) |
void DisplaceModel::collectShipPMEemission | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | PME_emission | ||
) |
void DisplaceModel::collectShipPMEemissiongPerkW | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | PME_emission_gperkW | ||
) |
void DisplaceModel::collectShipSOxEmission | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | SOx_emission | ||
) |
void DisplaceModel::collectShipSOxEmissionPercentPerTotalFuelmass | ( | int | step, |
int | node_idx, | ||
int | shipid, | ||
int | shiptype, | ||
double | SOx_emission_percentpertotalfuelmass | ||
) |
void DisplaceModel::collectSiltfraction | ( | int | step, |
int | node_idx, | ||
double | siltfraction | ||
) |
void DisplaceModel::collectSST | ( | int | step, |
int | node_idx, | ||
double | sst | ||
) |
void DisplaceModel::collectVesselStats | ( | int | step, |
const VesselStats & | stats | ||
) |
void DisplaceModel::collectWind | ( | int | step, |
int | node_idx, | ||
double | wind | ||
) |
void DisplaceModel::commitFishfarmsStats | ( | int | tstep | ) |
void DisplaceModel::commitNodesStatsFromSimu | ( | int | tstep, |
bool | force = false |
||
) |
void DisplaceModel::commitPopBenthosStats | ( | int | tstep | ) |
void DisplaceModel::commitShipsStats | ( | int | tstep | ) |
void DisplaceModel::commitVesselsStats | ( | int | tstep | ) |
Config DisplaceModel::config | ( | ) | const |
|
protected |
bool DisplaceModel::edit | ( | QString | modelname | ) |
void DisplaceModel::endCollectingStats | ( | ) |
|
signal |
bool DisplaceModel::exportGraph | ( | const QString & | path | ) |
|
inline |
QList< std::shared_ptr< NodeData > > DisplaceModel::getAllNodesWithin | ( | const QPointF & | centerpoint, |
double | dist_km | ||
) | const |
int DisplaceModel::getBenthosCount | ( | ) | const |
int DisplaceModel::getBenthosIdx | ( | int | benthosId | ) | const |
|
inline |
int DisplaceModel::getBenthosPopulationsCount | ( | ) | const |
|
inline |
|
inline |
int DisplaceModel::getFirmCount | ( | ) | const |
QString DisplaceModel::getFirmId | ( | int | idx | ) | const |
|
inline |
QString DisplaceModel::getFishfarmId | ( | int | idx | ) | const |
|
inline |
int DisplaceModel::getFishfarmsCount | ( | ) | const |
|
inline |
|
inline |
|
inline |
|
inline |
QString DisplaceModel::getHarbourId | ( | int | idx | ) | const |
|
inline |
int DisplaceModel::getHarboursCount | ( | ) | const |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
MapsDataProvider & DisplaceModel::getMapDataProvider | ( | ) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
QString DisplaceModel::getNodeId | ( | int | idx | ) | const |
int DisplaceModel::getNodesCount | ( | ) | const |
|
inline |
int DisplaceModel::getNumFishfarmsTypes | ( | ) | const |
int DisplaceModel::getNumFuncGroups | ( | ) | const |
int DisplaceModel::getNumShipsTypes | ( | ) | const |
int DisplaceModel::getNumWindfarmsTypes | ( | ) | const |
QString DisplaceModel::getOutDir | ( | ) | const |
|
inline |
|
inline |
|
inline |
int DisplaceModel::getPopulationsCount | ( | ) | const |
|
inline |
QString DisplaceModel::getShipId | ( | int | idx | ) | const |
|
inline |
int DisplaceModel::getShipsCount | ( | ) | const |
|
inline |
|
inline |
int DisplaceModel::getSimulationSteps | ( | ) | const |
|
inline |
|
inline |
int DisplaceModel::getUseStaticPaths | ( | ) | const |
|
inline |
int DisplaceModel::getVesselCount | ( | ) | const |
QString DisplaceModel::getVesselId | ( | int | idx | ) | const |
|
inline |
|
inline |
|
inline |
int DisplaceModel::getWindmillCount | ( | ) | const |
QString DisplaceModel::getWindmillId | ( | int | idx | ) | const |
|
inline |
bool DisplaceModel::importHarbours | ( | QList< std::shared_ptr< HarbourData > > & | list | ) |
|
inline |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
inline |
|
inline |
|
inline |
|
inline |
bool DisplaceModel::isInterestingHarb | ( | types::NodeId | n | ) |
|
inline |
bool DisplaceModel::isInterestingPop | ( | int | n | ) |
bool DisplaceModel::isInterestingPop2 | ( | int | n | ) |
|
inline |
bool DisplaceModel::isInterestingSize | ( | int | n | ) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
bool DisplaceModel::load | ( | QString | path, |
ModelType | type | ||
) |
bool DisplaceModel::loadDatabase | ( | QString | path | ) |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
inline |
|
inline |
|
inline |
|
signal |
|
protected |
|
signal |
void DisplaceModel::parseOutputStatsFile | ( | QString | file, |
int | tstep | ||
) |
|
inline |
|
inline |
void DisplaceModel::remInterestingHarb | ( | types::NodeId | n | ) |
remove the pop from the list of interest for pops
|
inline |
remove the pop from the list of interest for pops
void DisplaceModel::remInterestingPop | ( | int | n | ) |
remove the pop from the list of interest for pops
void DisplaceModel::remInterestingPop2 | ( | int | n | ) |
|
inline |
void DisplaceModel::remInterestingSize | ( | int | n | ) |
remove the pop from the list of interest for pops
|
inline |
remove the pop from the list of interest for pops
|
inline |
bool DisplaceModel::removeNode | ( | std::shared_ptr< NodeData > | node | ) |
HarbourStats DisplaceModel::retrieveHarbourIdxStatAtStep | ( | int | idx, |
int | step | ||
) |
Retrieve the statistics for a specific Harbour from the DB, or the latest available if it's a live simulation
bool DisplaceModel::saveConfig | ( | ) |
bool DisplaceModel::saveScenario | ( | ) |
bool DisplaceModel::saveScenarioAs | ( | const QString & | path | ) |
Scenario DisplaceModel::scenario | ( | ) | const |
void DisplaceModel::setAreaCodesFromFeature | ( | OGRGeometry * | geometry, |
int | code | ||
) |
|
protected |
void DisplaceModel::setBenthosBiomassFromFeature | ( | OGRGeometry * | geometry, |
double | bio | ||
) |
|
protected |
void DisplaceModel::setBenthosNumberFromFeature | ( | OGRGeometry * | geometry, |
double | nb | ||
) |
|
protected |
void DisplaceModel::setConfig | ( | const Config & | config | ) |
void DisplaceModel::setCurrentStep | ( | int | step | ) |
|
protected |
void DisplaceModel::setDissolvedCarbonFromFeature | ( | OGRGeometry * | geometry, |
double | dissc | ||
) |
|
inline |
|
inline |
|
inline |
void DisplaceModel::setInterestingHarb | ( | types::NodeId | n | ) |
insert the pop into the list of interest for pops
|
inline |
insert the pop into the list of interest for pops
void DisplaceModel::setInterestingPop | ( | int | n | ) |
insert the pop into the list of interest for pops
void DisplaceModel::setInterestingPop2 | ( | int | n | ) |
|
inline |
void DisplaceModel::setInterestingSize | ( | int | n | ) |
insert the pop into the list of interest for pops
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
void DisplaceModel::setLandscapeCodesFromFeature | ( | OGRGeometry * | geometry, |
int | code | ||
) |
|
protected |
void DisplaceModel::setNitrogenFromFeature | ( | OGRGeometry * | geometry, |
double | nit | ||
) |
|
inline |
|
inline |
|
protected |
void DisplaceModel::setOxygenFromFeature | ( | OGRGeometry * | geometry, |
double | oxygen | ||
) |
|
protected |
void DisplaceModel::setPhosphorusFromFeature | ( | OGRGeometry * | geometry, |
double | phos | ||
) |
|
protected |
void DisplaceModel::setSalinityFromFeature | ( | OGRGeometry * | geometry, |
double | psu | ||
) |
void DisplaceModel::setScenario | ( | const Scenario & | scenario | ) |
|
inline |
void DisplaceModel::setSimulationSqlStorage | ( | const QString & | path | ) |
void DisplaceModel::setSimulationSteps | ( | int | value | ) |
void DisplaceModel::setSSTFromFeature | ( | OGRGeometry * | geometry, |
double | sst | ||
) |
|
inline |
|
protected |
void DisplaceModel::setUseStaticPaths | ( | int | value | ) |
|
protected |
void DisplaceModel::setWindFromFeature | ( | OGRGeometry * | geometry, |
double | wind | ||
) |
void DisplaceModel::simulationEnded | ( | ) |
Signals the simulation has ended. Flush all buffers.
|
inline |
void DisplaceModel::startCollectingStats | ( | ) |
void DisplaceModel::updateFirm | ( | int | idx, |
float | x, | ||
float | y | ||
) |
void DisplaceModel::updateFishfarm | ( | int | idx, |
float | x, | ||
float | y | ||
) |
void DisplaceModel::updateNodesStatFromSimu | ( | QString | data | ) |
receive a Stats update for nodes from the Simulator
The string passed has the following format: stat,tstep,first,number,data
void DisplaceModel::updateShip | ( | int | tstep, |
int | idx, | ||
float | x, | ||
float | y, | ||
float | course | ||
) |
void DisplaceModel::updateVessel | ( | int | tstep, |
int | idx, | ||
float | x, | ||
float | y, | ||
float | course, | ||
float | fuel, | ||
int | state | ||
) |
void DisplaceModel::updateWindmill | ( | int | idx, |
float | x, | ||
float | y | ||
) |