[omniORB] sequuence of Object in omniPy

Duncan Grisby duncan at grisby.org
Sat Aug 9 15:36:34 BST 2003


On Monday 4 August, Jerome Kerdreux wrote:

> As you can see cltrlPoint.getDevices() should return
> a sequence of Device Object. so I write something like
> this on the servant side :

[...]
>    def getDevices(self):
>        result = []
>        for dev in self._ctrlPoint.getDevices():
>            result.append( Device_i( dev ) )
>        return result

You are returning a list of servants, not of CORBA objects. You must
activate the servants in a POA, then return object references for
them. The easiest way is to just call _this() on each servant, which
activates it in the Root POA, and returns an object reference.

Cheers,

Duncan.

-- 
 -- Duncan Grisby         --
  -- duncan at grisby.org     --
   -- http://www.grisby.org --



More information about the omniORB-list mailing list