Re: Referencing an "Addon" before use

Duke Normandin <[email protected]> Sat, 18 Feb 2012 08:57:08 -0700
Newsgroups gmane.comp.lang.io
Message-ID <20120218085708.57483f5f@select-man>
On Sat, 18 Feb 2012 00:06:58 -0500
gatesphere <[email protected]> wrote:


> On 2/17/2012 11:56 PM, Duke Normandin wrote:
> >
> > In
> > http://www.iolanguage.com/scm/io/docs/IoGuide.html#Primitives-Networking
> >
> > it says:
> >
> > [quote]
> > Note that you'll need to first reference the associated addon in
> > order to cause it to load before using its objects. In these
> > examples, you'll have to reference "Socket" to get the Socket
> > addon to load first.[/quote]
> >
> > how do you perform this "referencing"? I'm trying to work
> > through the examples, and so far, No Joy!
> >
> > 
> 
> Easy.
> 
> Just put "Socket" somewhere in your script, either as it's own
> line, or as part of a command.  When the interpreter finds
> something that it can't identify, it looks to see if it can
> autoload it, which in Socket's case, it can.  Simple as cake.
> 
> -->Jake
> 


Here's the snippet that I was trying to get working:

[quote]
whois := method(host,
    socket := Socket clone \
		setHostName("rs.internic.net") setPort(43) 
    socket connect streamWrite(host, "\n")
    while(socket streamReadNextChunk, nil)
    return socket readBuffer
)[/quote]

So, "Socket" seems to be referenced, but ....

I just discovered that these "Addons" are not automatically
installed. As well, the various docs on the 'net and in my Io Git
directory are not helpful, i.e., "Not working!!" :)

Sooo, how do I install these "Addons" from my Git directory?