Ignore:
Timestamp:
Mar 11, 2007, 2:22:39 PM (18 years ago)
Author:
cinc
Message:

Implemented some methods. Bug fixes and documentation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/nom/class_c/nomcls.c

    r242 r251  
    3232*
    3333* ***** END LICENSE BLOCK ***** */
     34/** \file noncls.c
     35   
     36    Implementation file for the NOMClass class.
     37*/
    3438#ifndef NOM_NOMClass_IMPLEMENTATION_FILE
    3539#define NOM_NOMClass_IMPLEMENTATION_FILE
     
    8387  ncp=(NOMClassPriv*)_ncpObject;
    8488
     89  /* Allocate memory big enough to hold an object. This means the size is that of the
     90     mtab pointer and all instance variables. */
    8591  if((nObj=_nomAllocate(nomSelf, ncp->mtab->ulInstanceSize, NULLHANDLE))==NULLHANDLE)
    8692    return NULLHANDLE;
     
    149155
    150156/**
    151    Function which implements the nomGetName() method of NOMClass.
     157   Function which implements the nomGetCreatedClassName() method of NOMClass.
    152158*/
    153 NOM_Scope CORBA_string NOMLINK impl_NOMClass_nomGetName(NOMClass* nomSelf, CORBA_Environment *ev)
    154 {
    155   return nomSelf->mtab->nomClassName;
     159NOM_Scope CORBA_string NOMLINK impl_NOMClass_nomGetCreatedClassName(NOMClass* nomSelf, CORBA_Environment *ev)
     160{
     161  NOMClassPriv* ncp;
     162
     163  /* The private struct characterizing the objects this meta class can create. */
     164  ncp=_nomGetObjectCreateInfo(nomSelf, NULLHANDLE);
     165
     166  if(!ncp)
     167    return ""; /* That can not happen but anyway... */
     168
     169  //  return nomSelf->mtab->nomClassName;
     170  return ncp->mtab->nomClassName;
    156171}
    157172
     
    212227
    213228      /* FIXME: no use of version information, yet. */
    214       //nomPrintf("I'm here (%s): ", _nomGetName(nomSelf, NULLHANDLE));
    215       if(!_nomFindClassFromName(NOMClassMgrObject, _nomGetName(nomSelf, NULLHANDLE),
     229     
     230      //The following was used before changing nomGetname()
     231      //if(!_nomFindClassFromName(NOMClassMgrObject, _nomGetName(nomSelf, NULLHANDLE),
     232      //                        0, 0, NULLHANDLE))
     233      if(!_nomFindClassFromName(NOMClassMgrObject, _nomGetClassName(nomSelf, NULLHANDLE),
    216234                              0, 0, NULLHANDLE))
     235
    217236        {
    218237          NOMClassPriv* ncPriv;
Note: See TracChangeset for help on using the changeset viewer.