Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Net. procs/functions
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Sie_Kensou




PostPosted: Sat Jan 04, 2003 6:35 pm   Post subject: Net. procs/functions

Hi there. Does anyone have a list of the procs and/or functions that the Net "class" has (who knows how those set of procs are called in Turing.. haha)
Sponsor
Sponsor
Sponsor
sponsor
Sie_Kensou




PostPosted: Sat Jan 04, 2003 7:21 pm   Post subject: More details

I think I should explain a bit more..
for example, the line:

Net.LocalAddress

gets the ip address of the computer. What I am requesting is a list of this functions in the Net "set"... Does anyone know?
Tony




PostPosted: Sat Jan 04, 2003 7:29 pm   Post subject: (No subject)

they're listed in turing help file

WaitForConnection Waits until a client connects to a specified port.
OpenConnection Opens a connection to a specified machine.
OpenURLConnection Opens a connection to a file specified by a URL.
CloseConnection Closes a specified connection.
BytesAvailable Returns the number of bytes available to be read from a net stream.
CharAvailable Returns true if there is a character available to be read from a net stream.
LineAvailable Returns true if there is a line of text available to be read from a net stream.
TokenAvailable Returns true if there is a token available to be read from a net stream.
HostAddressFromName Returns a host's address given its host name.
HostNameFromAddress Returns a host's name given its address.
LocalAddress Returns the host name of the local machine.
LocalName Returns the TCP/IP address of the local machine.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
Sie_Kensou




PostPosted: Sat Jan 04, 2003 8:25 pm   Post subject: Send data

Ok, I thought I could find a function to send data to the other computer or something... anyways.

I tried the "netchat" program but seems that it doesn't work properly. It stablishes the conection but there is no text sent/recieved. Is this a problem on my computer? or there is something wrong with the program?

Is the command to send data to the other computer...

put: <var>, <data>

where var is the int used to open the net conection and data is whatever is being passed, right?
Tony




PostPosted: Sat Jan 04, 2003 9:09 pm   Post subject: (No subject)

yes, you are right about command use

it might not work if one of computers has a firewall

also not all versions of turing support Net.
v3.1 can't compile Net properly.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: