api_get_owner
List of: Functions
Subjects: Model Topology
Contents: Kernel

Action: Gets the top level owner of an entity.

Prototype: outcome api_get_owner (


ENTITY* ent, // entity to determine




// owner


ENTITY*& owner, // top level owner of




// entity returned


AcisOptions* ao = NULL // acis options


);

Includes: #include "kernel/acis.hxx"

#include "kernel/kernapi/api/api.hxx"

#include "kernel/kernapi/api/kernapi.hxx"

#include "kernel/kerndata/data/entity.hxx"

#include "kernel/kernapi/api/acis_options.hxx"

Description: This API finds the top level entity that ''owns'' the given entity (ent). For the purpose of this API, an entity owns another entity if the second entity is part of the definition of the first.


For example, if an edge is created with one of the curve-creation API functions, that edge is not owned by any other entity. If a solid is created, the edges of that solid are owned by the solid. For an EDGE, FACE, VERTEX, etc., that is a part of a solid, this API returns the BODY pointer of the solid. If the entity is not owned by another entity, then the pointer returns itself.


An ENTITY is top level when making a call to api_get_owner returns itself. Also, every ENTITY contains an owner method. This method would return the next higher ENTITY. If that object is the top level ENTITY, then this pointer is returned. This means that if a FACE does not point to an owning SHELL, this FACE is top level for that model. A BODY is normally top level, but in some cases, there are others that are the top level ENTITY.

Library: kernel

Filename: kern/kernel/kernapi/api/kernapi.hxx

Effect: Read-only
PDF/KERN/16FNA.PDF
HTM/DATA/KERN/KERN/16FNA/0065.HTM