Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 626995
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T19:28:48+00:00 2026-05-13T19:28:48+00:00

I know that the Socket class can be instantiated in this way (as an

  • 0

I know that the Socket class can be instantiated in this way (as an example):

new Socket("taranis", 7);

where “taranis” is the name of the server in a local network. In this respect I have two questions:

1. If my computers do not form a local network but are connected to the Internet, can I use the IP addresses of computers to instantiate a socket?

2. How my computers get names in the local network? Do I give names to the computers when I create the network.

P.S. I herd that computers can establish a network by themself (using zeroconf). Who then gives names to the computers and how can I know these names in advance (I need them to write my code).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T19:28:48+00:00Added an answer on May 13, 2026 at 7:28 pm
    1. Yes, you can create a socket using the ip address, you can do so like this: new Socket("192.168.1.00",8888)

    2. When you install an OS on your computer, usually one of the steps that the OS makes you go through is giving your machine a name. Each OS also has a way of changing these names after installation. So, everyone of your computers probably does have a name. However, the tricky part is getting one machine to know the name of the other. This can be done in a few ways. One is by using a DNS server. This kind of like a middle man which will translate the name (i.e Computer1) to its IP address (192.1.168.1.100). You can also keep these mapping locally, you can put this in the hosts file. This is a mapping between names and ip addresses, and if you use this method, you need to make sure that these hosts files line up across the machines.

    3. Zeroconf is an interesting protocol. The way it works is one computer creates a named service and the second computer just looks up the service by name, and once it finds the service it can connect to it. When the service is discovered, the connecting client and can query for the ip and port to connect to.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

So I have a class that uses references (&) with functions like void request(tcp::socket&
I'm getting this error message trying to use PHP Mailer. Please let me know
Before voting to close, please read, I know that there are similar questions (:
I am trying to figure out what the best way to approach Async object
I wrote a server-client communication program and it worked well. Client module import java.io.*;
I am opening a socket on port 119 (using idHttpServer) and it opens ok
I have a large application written using .Net remoting for file transfer. This was
I have to write a C app that will act as both UDP sender
We've introduced a few .NET pages into a Classic ASP application. When a user
I have a need to send messages (requests from the User to the Engine,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.