Hello Markus,
Your code in r53760 seems good. I would suggest to move it to some
library, still no idea where it should go. Probably Vlib? As it would
reduce code duplication and use of home-brew suboptimal code.
Thanks for good work,
Maris.
Hello Markus,
Your code in r53760 seems good. I would suggest to move it to some
library, still no idea where it should go. Probably Vlib? As it would
reduce code duplication and use of home-brew suboptimal code.
Thanks for good work,
Maris.
Hi,
2012/11/21 Maris Nartiss <maris.gis@gmail.com>:
Your code in r53760 seems good. I would suggest to move it to some
library, still no idea where it should go. Probably Vlib? As it would
reduce code duplication and use of home-brew suboptimal code.
Vlib seems to be a good place, see also similar (more options
included) stuff in v.edit [1].
Martin
[1] http://trac.osgeo.org/grass/browser/grass/trunk/vector/v.edit/select.c#L38
--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa
On Wed, Nov 21, 2012 at 3:59 PM, Martin Landa <landa.martin@gmail.com> wrote:
Hi,
2012/11/21 Maris Nartiss <maris.gis@gmail.com>:
Your code in r53760 seems good. I would suggest to move it to some
library, still no idea where it should go. Probably Vlib? As it would
reduce code duplication and use of home-brew suboptimal code.Vlib seems to be a good place, see also similar (more options
included) stuff in v.edit [1].
I agree, particularly if more modules will get cats/where options,
maybe also to work with virtual vector maps. I would suggest two new
functions, one to parse cats/where/field options, essentially the
parse_filter_options() fn, another one to check categories against
these filters.
Markus M
On Wed, Nov 21, 2012 at 4:18 PM, Markus Metz
<markus.metz.giswork@gmail.com> wrote:
On Wed, Nov 21, 2012 at 3:59 PM, Martin Landa <landa.martin@gmail.com> wrote:
Hi,
2012/11/21 Maris Nartiss <maris.gis@gmail.com>:
Your code in r53760 seems good. I would suggest to move it to some
library, still no idea where it should go. Probably Vlib? As it would
reduce code duplication and use of home-brew suboptimal code.Vlib seems to be a good place, see also similar (more options
included) stuff in v.edit [1].I agree, particularly if more modules will get cats/where options,
maybe also to work with virtual vector maps. I would suggest two new
functions, one to parse cats/where/field options, essentially the
parse_filter_options() fn, another one to check categories against
these filters.
Done in r53997. The new functions are called
Vect_cats_set_constraint() and Vect_cats_in_constraint(). I would
prefer the term 'filter' but used the term 'constraint' for
consistency because it is already used elsewhere in the vector lib for
region and line type constraints.
Markus M