00001
00011 #ifndef BS_BOS_CORE_PY_CALC_WELL_DETAIL_H_
00012 #define BS_BOS_CORE_PY_CALC_WELL_DETAIL_H_
00013
00014 namespace blue_sky {
00015 namespace python {
00016 namespace detail {
00017
00018 template <typename connection_t>
00019 static void
00020 set_connection_density (connection_t *c, double density)
00021 {
00022 c->density = density;
00023 }
00024
00025 template <typename well_t>
00026 static typename well_t::index_t
00027 get_well_i_coord (const well_t *well)
00028 {
00029 return well->i_coord_;
00030 }
00031 template <typename well_t>
00032 static typename well_t::index_t
00033 get_well_j_coord (const well_t *well)
00034 {
00035 return well->j_coord_;
00036 }
00037 template <typename well_t>
00038 static void
00039 set_well_i_coord (well_t *well, typename well_t::index_t i)
00040 {
00041 well->i_coord_ = i;
00042 }
00043 template <typename well_t>
00044 static void
00045 set_well_j_coord (well_t *well, typename well_t::index_t j)
00046 {
00047 well->j_coord_ = j;
00048 }
00049
00050 template <typename well_t>
00051 static typename well_t::item_t
00052 get_well_wefac (const well_t *well)
00053 {
00054 return well->exploitation_factor_;
00055 }
00056
00057 template <typename well_t>
00058 static typename well_t::index_t
00059 get_well_state (const well_t *well)
00060 {
00061 return well->well_state_.state;
00062 }
00063
00064 template <typename well_t>
00065 static bool
00066 get_well_is_work (const well_t *well)
00067 {
00068 return well->well_state_.is_work;
00069 }
00070 template <typename well_t>
00071 static void
00072 set_well_is_work (well_t *well, bool is_work)
00073 {
00074 well->well_state_.is_work = is_work;
00075 }
00076 template <typename well_t>
00077 static bool
00078 well_is_production (const well_t *well)
00079 {
00080 return well->get_controller ()->is_production ();
00081 }
00082
00083 }
00084 }
00085 }
00086
00087 #endif // #ifndef BS_BOS_CORE_PY_CALC_WELL_DETAIL_H_
00088
00089
00090