Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Universal group operator #151

Open
yumin opened this issue Apr 21, 2015 · 1 comment
Open

Universal group operator #151

yumin opened this issue Apr 21, 2015 · 1 comment

Comments

@yumin
Copy link
Contributor

yumin commented Apr 21, 2015

We need a universal group operator across all types of sessions. This op will handle various grouping operations, such as create/delete group, modify group (add/remove entities). The group may have different constraints on its membership and its relationship with the entities. We have something in discrete (PR #149), but it is limited to the discrete modeling kernel. This new op should match closely with the smtk group capability. Here is some comment for that PR from @vibraphone

There are bits set aside in smtk/model/EntityTypeBits.h to mark groups as partitions or covers but there are no tests to enforce these rules — in part because there are no operators to construct the initial set of groups that form the partition or cover or manipulate the groups after their creation. Note that using groups this way requires 2 levels of groups: a toplevel group with the PARTITION or COVER bit set and child groups that collectively define the membership.

The 2-level groups are required so that partitions/covers do not have to encompass all entities in a model manager or session. Instead, operators should just verify that the membership of the toplevel group before and after a group operation is unchanged.

@vibraphone
Copy link
Member

The preferred way to implement this is

  • a set of utilities for managing group membership in smtkCore
  • a per-session group operator that establishes a convention for mapping this functionality to the modeling kernel's abilities. Different kernels have different rules for what can be in a group and how groups relate to each other. Some of these kernels may need to use tricks in order to serialize/deserialize information about groups that are partitions or members of partitions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants