gomd-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gomd-devel] Re: Perl class/library for gomd


From: Mirko Caserta
Subject: Re: [gomd-devel] Re: Perl class/library for gomd
Date: Sun, 8 Jun 2003 14:34:27 +0200

On Sat, 7 Jun 2003 18:45:05 -0700
Moshe Bar <address@hidden> wrote:

> Marco,
> 
> I'll give you commit to the CVS, I just need your sourceforge ID.

Moshe, I think Marco was referring to the gomd CVS repository :)
 
> Creating a gomd Perl class is a good idea, although I want my otop.pl 
> to be independent of any module, so that it is guaranteed to work on 
> any Perl distribution.  That's why I programmed the sockets 
> infrastructur raw accessing the headers for the system directly.

Well, the idea is not to have a regular "Perl Module" but rather a file with a
class which exposes basic functions for sending and receiving data from a gomd.
The perl class should use no external perl module but raw sockets (just like
you have outlined in otop.pl). This way, any perl app should be able to use the
perl class by simply including the "library" file.

The exposed API should be as simple as 

$conn = $gomd->connect('myhost', 9889);
$result= $conn->request('get speed');

Maybe the API can be extended a bit to make things a bit more object oriented
and simpler to use from the client app programming's point of view...

$conn = $gomd->connect('myhost', 9889);
$conn->setRequestType('get');
$conn->setRequestData('load');
$conn->setRequestNodes( {1, 5, 6, 9} );
$result = $conn->sendRequest();

I don't know. It's just an idea. But we would love to have a sort of simple
perl class with a standard API for any perl -> gomd application.

Mirko




reply via email to

[Prev in Thread] Current Thread [Next in Thread]