DISPLACE  1.0
A spatial model of fisheries to help sustainable fishing and maritime spatial planning
firmentity.h
Go to the documentation of this file.
1 /* --------------------------------------------------------------------------
2  * DISPLACE: DYNAMIC INDIVIDUAL VESSEL-BASED SPATIAL PLANNING
3  * AND EFFORT DISPLACEMENT
4  * Copyright (c) 2012-2019 Francois Bastardie <fba@aqua.dtu.dk>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License along
17  * with this program; if not, write to the Free Software Foundation, Inc.,
18  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
19  * --------------------------------------------------------------------------
20  */
21 #ifndef FIRMENTITY_H
22 #define FIRMENTITY_H
23 
24 
26 
27 namespace objecttree {
28 
30 {
31  int mFirmId;
32 
33 public:
34  FirmEntity(ObjectTreeModel *_model, int id = -1);
35 
38  }
39 
40  virtual QModelIndex parent (const QModelIndex &parent) const;
41  virtual QModelIndex index (int row, int column, const QModelIndex &parent) const;
42  virtual int rowCount() const;
43  virtual int columnCount() const;
44  virtual QVariant data(const QModelIndex &index, int role) const;
45 
46  // Specific access functions
47  int getFirmId() const { return mFirmId; }
48 };
49 
50 }
51 
52 
53 
54 #endif // FIRMENTITY_H
Definition: benthosentity.cpp:27
Definition: objecttreemodel.h:51
virtual QModelIndex parent(const QModelIndex &parent) const
Definition: firmentity.cpp:34
Definition: firmentity.h:29
Definition: objecttreeentity.h:32
virtual QVariant data(const QModelIndex &index, int role) const
Definition: firmentity.cpp:62
Definition: objecttreemodel.h:39
virtual ObjectTreeModel::Category getCategory() const
Definition: firmentity.h:36
Category
Definition: objecttreemodel.h:44
virtual QModelIndex index(int row, int column, const QModelIndex &parent) const
Definition: firmentity.cpp:40
virtual int columnCount() const
Definition: firmentity.cpp:57
FirmEntity(ObjectTreeModel *_model, int id=-1)
Definition: firmentity.cpp:28
int getFirmId() const
Definition: firmentity.h:47
virtual int rowCount() const
Definition: firmentity.cpp:49