model_server/obj/src/objRelation.h.cxx
// Remove one relation - internal function (doesn't care about inversed one)
Remove one relation - internal function (doesn't care about inversed one)
Remove one relation - internal function ( doesn ' t care about inversed one )
void  Relational::priv_rem_one_rel(Relational * m, RelType *rt)
  {
  Initialize(Relational::priv_rem_one_rel);
  Assert(rt);
  Assert(m);
  if(rt->offset)                                     
    {
    priv_rem_one_ptr( m, rt);
    return;
    }
  Relation * curr_rel = rel_list[rel_list.index(rt)];
  if (!curr_rel)
    return;
  Obj * m1 = curr_rel->get_members();
  if (!m1 || ! m1->includes(m))                     
     return;
  if(m1->collectionp())
    {
    ((objSet *)m1)->remove(m);
    if(m1->size() == 0)
      {
      delete ((objSet *)m1);
      rel_list.remove(curr_rel);
      }
    }
  else
    {
    rel_list.remove(curr_rel);
    }  
  return;
  }
void Relational :: priv_rem_one_rel ( Relational * m , RelType * rt ) { Initialize ( Relational :: priv_rem_one_rel ) ; Assert ( rt ) ; Assert ( m ) ; if ( rt -> offset ) { priv_rem_one_ptr ( m , rt ) ; return ; } Relation * curr_rel = rel_list [ rel_list . index ( rt ) ] ; if ( ! curr_rel ) return ; Obj * m1 = curr_rel -> get_members ( ) ; if ( ! m1 || ! m1 -> includes ( m ) ) return ; if ( m1 -> collectionp ( ) ) { ( ( objSet * ) m1 ) -> remove ( m ) ; if ( m1 -> size ( ) == 0 ) { delete ( ( objSet * ) m1 ) ; rel_list . remove ( curr_rel ) ; } } else { rel_list . remove ( curr_rel ) ; } return ; }
Remove one relation - internal function (doesn't care about inversed one)
Remove one relation - internal function ( doesn ' t care about inversed one )
// fixed type relation // dynamic relation // Find "Relation" object // already removed or never existed