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

We should not allow adding instance as descendant #563

Closed
kecso opened this issue Sep 14, 2015 · 0 comments
Closed

We should not allow adding instance as descendant #563

kecso opened this issue Sep 14, 2015 · 0 comments

Comments

@kecso
Copy link
Member

kecso commented Sep 14, 2015

Currently we only forbid to add an instance to the node as a direct child (which means that parent !== base should stand for all nodes), but we not check for more distant relations.
The containment hierarchy and the inheritance chain of a node should never cross each other.

@kecso kecso self-assigned this Sep 14, 2015
@kecso kecso added this to the v1.0.0 milestone Sep 14, 2015
kecso added a commit that referenced this issue Sep 15, 2015
now the gme concepts checks for every level of containment to avoid crossings in the containment hierarchy and the inheritance chain
it is still possible to create loops / crossings in the inheritance chain and containment hierarchy as not all elements can be checked at the time of modification
kecso added a commit that referenced this issue Sep 17, 2015
… collision

if they found such node, they remove it on-demand
kecso added a commit that referenced this issue Sep 18, 2015
As some generic UI pieces depend on the fact, that there is only the FCO (and the ROOT) which doesn't have a base, we prohibit its copy.
This restriction however exsits only on the UI as in theory the core layer can handle multiple objects without base.

We also checks for situations which cause unloadable nodes. More precisely when a node contains its base.
As not all situation can be avoided beforehand we remove such nodes during their load.
This issue is the opposite of #563
A possible scenario:
1. create typeA and typeB
2. create an instance of typeA (instA)
3. move typeB inside instA
4. move typeA inside typeB (at this point we are unable to prohibit the move as we not necessarily know about instA being a descendant of typeA)
-> instA become unloadable
kecso added a commit that referenced this issue Sep 18, 2015
As some generic UI pieces depend on the fact, that there is only the FCO (and the ROOT) which doesn't have a base, we prohibit its copy.
This restriction however exsits only on the UI as in theory the core layer can handle multiple objects without base.

We also checks for situations which cause unloadable nodes. More precisely when a node contains its base.
As not all situation can be avoided beforehand we remove such nodes during their load.
This issue is the opposite of #563
A possible scenario:
1. create typeA and typeB
2. create an instance of typeA (instA)
3. move typeA inside typeB
4. move typeB inside instA (at this point we are unable to prohibit the move as we not necessarily know about typeA and that it is the base of instA)
-> instA become unloadable
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant