/* [<][>][^][v][top][bottom][index][help] */
1 #ifndef _NEURON_HPP_
2 #define _NEURON_HPP_
3
4 #include "utility/libraries.hpp"
5 #include "utility/constants.hpp"
6 #include "core/Compartment.hpp"
7
8 class Network; // forward declaration to avoid cyclic dependency issues
9
10 class Neuron
11 {
12 public:
13 string id;
14 Network * network;
15 osg::ref_ptr<osg::Switch> node;
16 osg::ref_ptr<osg::Group> compartment_group_node;
17 std::vector<Compartment *> compartment_seq;
18 std::unordered_map<string, Compartment *> compartment_map;
19
20 Neuron(const char * id);
21
22 ~Neuron();
23
24 const char *
25 get_id();
26
27 void
28 set_network(Network * network);
29
30 Network *
31 get_network();
32
33 Compartment *
34 get_compartment(const char * id);
35
36 void
37 hide();
38
39 void
40 show();
41
42 bool
43 is_visible();
44
45 unsigned int
46 size();
47
48 unsigned int
49 add_geometry( PyObject * distal
50 , PyObject * proximal = Py_None
51 , PyObject * parent = Py_None
52 );
53
54 unsigned int
55 add_compartment(Compartment * compartment);
56
57 unsigned int
58 remove_compartment(Compartment * compartment);
59
60 void
61 show_geometry(unsigned int geometry_index, bool hide_others);
62
63 void
64 hide_geometry(unsigned int geometry_index);
65
66 void
67 show_all_geometries();
68
69 void
70 hide_all_geometries();
71
72 void
73 set_color(PyObject * color);
74
75 bool
76 set_colors(PyObject * colors);
77 };
78
79 #endif /* _NEURON_HPP_ */