[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Ruby Swig passing Argument

zdk

8/27/2007 7:11:00 AM

Hi Folks,
If I have swig module

%module example
on2sc Flix2_CreateEx (FLIX2HANDLE *pFlix, const char *rpchost,
int32_t timeout)

How can I pass argument as a pointer in Ruby? ( I mean the
"FLIX2HANDLE" type)

require 'example'
h = Example.Flix2_CreateEx(....<how?>...,"localhost",0)


Any help or suggestion would be greatly appreciated.

Thank you very much.

Warachet S.

7 Answers

Alex Fenton

8/29/2007 11:37:00 AM

0

zdk wrote:
> If I have swig module
>
> %module example
> on2sc Flix2_CreateEx (FLIX2HANDLE *pFlix, const char *rpchost,
> int32_t timeout)
>
> How can I pass argument as a pointer in Ruby? ( I mean the
> "FLIX2HANDLE" type)
>
> require 'example'
> h = Example.Flix2_CreateEx(....<how?>...,"localhost",0)

SWIG is able to handle pointers without any particular help. But if you
need to be able to pass a FLIX2HANDLE (whatever that is) as an argument,
then you need to wrap that in Ruby as well, using SWIG, so a Ruby object
can be linked to a FLIX2HANDLE.

You might have a look at the SQLite3 SWIG wrapper. The SQLite3 C API
makes extensive use of a db handle as a first argument, but the Ruby API
makes a nice job of hiding this from the user.

Alex

Sunny

2/19/2011 7:51:00 AM

0


"Petzl" <petzlx@gmail.com> wrote in message
news:7cqul6lue7g0svvkemjhbcmbdo9hco9bva@4ax.com...
> On Sat, 19 Feb 2011 15:02:37 +1000, "Sunny"
> <wombathouse.@yahoo.com.au> wrote:
>
>>
>>"Petzl" <petzlx@gmail.com> wrote in message
>>news:r1cul69p6l4jun5rtqsd3s13tr1nkpfdg9@4ax.com...
>>> On Sat, 19 Feb 2011 12:03:40 +1000, "Sunny"
>>> <wombathouse.@yahoo.com.au> wrote:
>>>
>>>>> Don't forget Moslem (get the Christian spelling right!
>>>>
>>> Rep[lacing the censorship
>>> Don't forget Moslem (get the Christian spelling right! Means "evil &
>>> unjust") their Hatred of Christians, Australians, Americans, Israelis
>>> and themselves (I forgot Europeans)
>>>
>>>>Still up to your lying habits Petzl ?
>>>>
>>>>Muslim :
>>>>
>>>> noun: a believer or follower of Islam
>>>
>>> That's a bullshit name Moslems invented
>>> Moslem is Aramaic/Arabic for "Evil and unjust"
>>> Jesus (God in the flesh) used Moslem in his "Sermon on the Mount"
>>>
>>> The media only started using the word Muslim after Moslems en-mass
>>> (around 1985) had their normal violent temper tantrum demanding the
>>> change. .
>>> http://hnn.us/article... .
>>> or .
>>> http://isupporttheresistance.blogspot.com/2007/04/you-say-potato-i-say-po...
>>
>>You just can't help yourself, can you Petzl?
>>
>>http://www.etymonline.com/index.php?t...
>>Muslim
>>1610s (n.), 1777 (adj.), from Arabic muslim "one who submits" (to the
>>faith), from root of alsama "he resigned." Related to Islam (q.v.).
>>
>>Report to your favourite Church, or get Fred Nile to flagellate you, for
>>lying (again)
>>
> I'm about what Christians called Mohammedans after they objected to
> being called that! Christains then called them Moslem meaning what
> they are *evil and unjust*. Don't really care what Moslems want to be
> called.

You care enough to lie about their name.


Gillard = Rudd in a frock

2/19/2011 11:07:00 AM

0

On Friday 18 February 2011 21:31, bringyagrogalong babbled:

> "Dug" <andxor...@gggmail.com> wrote:
>>
>> Islamic schools in UK teaching hatred & extremist shariah
>
> And here an extremist like you is teaching hatred of Muslims on
> Usenet.
>
> Funny old world, ain't it!

The penny drops.

Not only are you a wog who hates Israel, but perhaps you are a scum Muslim
wog as well?

Do tell.

Dug

2/19/2011 4:28:00 PM

0

"bringyagrogalong" <sofala@aapt.net.au> wrote in message
news:7f5f789c-81d0-42d4-b523-1498993ad724@u24g2000prn.googlegroups.com...
> "Dug" <andxor...@gggmail.com> wrote:
>>
>> Islamic schools in UK teaching hatred & extremist shariah
>
> And here an extremist like you is teaching hatred of Muslims on
> Usenet.
>

Duh, and the holey koran is full of antisemitic hate and
anti-Christian hate so it's fully justifiable Ahmed Abdul
Grabass.

> Funny old world, ain't it!

The mentally challenged are easily amused.



Dug

2/19/2011 4:29:00 PM

0

<last_permutation@yahoo.com> wrote in message
news:d2f8e4fc-2341-42fb-86a7-4d0e2ccdc989@a21g2000prj.googlegroups.com...
On Feb 18, 3:06 pm, "Seon" <seo...@gmail.com> wrote:
> "bringyagrogalong" <sof...@aapt.net.au> wrote in message
>
> news:7f5f789c-81d0-42d4-b523-1498993ad724@u24g2000prn.googlegroups.com...
>
> > "Dug" <andxor...@gggmail.com> wrote:
>
> >> Islamic schools in UK teaching hatred & extremist shariah
>
> > And here an extremist like you is teaching hatred of Muslims on
> > Usenet.
>
> > Funny old world, ain't it!
>
> I'll be more terrified of a Muslim extremist than Doug.

The point is not what you're terrified of prick, but that Dung
in a hater, like a racist little Peon. The door swings both
ways Peon.

*******************
But muslime fucks like you DESERVE all the hatred you
get, because your f'ed up religion is nothing BUT hatred
Ali Al Fuckwit.


Dug

2/19/2011 4:30:00 PM

0

"Sunny" <wombathouse.@yahoo.com.au> wrote in message
news:jiI7p.10652$MF5.8869@viwinnwfe02.internal.bigpond.com...
>
> "Petzl" <petzlx@gmail.com> wrote in message
> news:r1cul69p6l4jun5rtqsd3s13tr1nkpfdg9@4ax.com...
>> On Sat, 19 Feb 2011 12:03:40 +1000, "Sunny"
>> <wombathouse.@yahoo.com.au> wrote:
>>
>>>> Don't forget Moslem (get the Christian spelling right!
>>>
>> Rep[lacing the censorship
>> Don't forget Moslem (get the Christian spelling right! Means "evil &
>> unjust") their Hatred of Christians, Australians, Americans, Israelis
>> and themselves (I forgot Europeans)
>>
>>>Still up to your lying habits Petzl ?
>>>
>>>Muslim :
>>>
>>> noun: a believer or follower of Islam
>>
>> That's a bullshit name Moslems invented
>> Moslem is Aramaic/Arabic for "Evil and unjust"
>> Jesus (God in the flesh) used Moslem in his "Sermon on the Mount"
>>
>> The media only started using the word Muslim after Moslems en-mass
>> (around 1985) had their normal violent temper tantrum demanding the
>> change. .
>> http://hnn.us/article... .
>> or .
>> http://isupporttheresistance.blogspot.com/2007/04/you-say-potato-i-say-po...
>
> You just can't help yourself, can you Petzl?
>
> http://www.etymonline.com/index.php?t...
> Muslim
> 1610s (n.), 1777 (adj.), from Arabic muslim "one who submits" (to the
> faith), from root of alsama "he resigned." Related to Islam (q.v.).
>
> Report to your favourite Church, or get Fred Nile to flagellate you, for
> lying (again)

Petzl would be a imprisoned or more probably dead for the comments
he makes about pislam in ANY muslime fuck country, so why don't
you pack up your camel and goat girlfriend and make the move Ahmed?


The Peeler

2/19/2011 7:31:00 PM

0

On Sat, 19 Feb 2011 08:27:43 -0800, "Dug" <andxornot@gggmail.com>
wrote:

>"bringyagrogalong" <sofala@aapt.net.au> wrote in message
>news:7f5f789c-81d0-42d4-b523-1498993ad724@u24g2000prn.googlegroups.com...
>> "Dug" <andxor...@gggmail.com> wrote:
>>>
>>> Islamic schools in UK teaching hatred & extremist shariah
>>
>> And here an extremist like you is teaching hatred of Muslims on
>> Usenet.
>>
>
>Duh, and the holey koran is full of antisemitic hate and
>anti-Christian hate so it's fully justifiable Ahmed Abdul
>Grabass.

Two blacks don't make a white, Duhg.

>> Funny old world, ain't it!
>
>The mentally challenged are easily amused.

Those who suck jew rectums are easily satisfied.