File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

B&S connection to the server

 
Lucas cotta
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all!

I'm thinking, in the client mode, let the user fill just the IP address of the server (and port), instead of IP or host name...
But searching the forum, I saw that most people use both options...
Do you guys think I would loose points for this?

Thanks!!
 
Roberto Perillo
Bartender
Posts: 2271
3
Eclipse IDE Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Howdy, Lucas!

Well champ, that's what I did. In my config dialog, the user enters the IP address and port number in which the server is running in the given IP address.

I'm not sure, but I think that there should be a mapping host name X IP address somewhere in your OS (i.e. hosts.sam) so the application is able to resolve correctly the host name, right? I never tried that, so I don't know if even that would work...
 
Lucas cotta
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Roberto Perillo wrote:Howdy, Lucas!
Well champ, that's what I did. In my config dialog, the user enters the IP address and port number in which the server is running in the given IP address.
I'm not sure, but I think that there should be a mapping host name X IP address somewhere in your OS (i.e. hosts.sam) so the application is able to resolve correctly the host name, right? I never tried that, so I don't know if even that would work...


Yes but I just want to keep the GUI simple and let the user just enter numbers, in a field that will have a mask for IP address (___.___.___.___)

Thanks for the answer!!
 
Roberto Perillo
Bartender
Posts: 2271
3
Eclipse IDE Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lucas cotta wrote:Yes but I just want to keep the GUI simple and let the user just enter numbers, in a field that will have a mask for IP address (___.___.___.___)


Alright champ, that's an approach. What I did is, I created a subclass of PlainDocument, where the user can only insert numbers or a dot. To validate the IP address, I created a custom validator (I had an interface called Validator with a few custom validators).
 
Roel De Nijs
Sheriff
Posts: 9091
73
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lucas cotta wrote:in a field that will have a mask for IP address (___.___.___.___)


And what about 192.1.1.252, also a valid IP but it won't fit your input mask
 
Lucas cotta
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Roel De Nijs wrote:
And what about 192.1.1.252, also a valid IP but it won't fit your input mask


I was thinking a field similar to the Windows TCP/IPV4 properties window... do you think is a bad idea?

And another question... an interpretation one..
the instructions say that "The new application, using the existing data file format, must allow the CSRs to generate a list of constractors that match a customer's criteria."
But in the database there are SUBcontractors...

so, what my application will search in the database, contractors or subcontractors?

Thanks!!
 
Roel De Nijs
Sheriff
Posts: 9091
73
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lucas cotta wrote:I was thinking a field similar to the Windows TCP/IPV4 properties window... do you think is a bad idea?

No, that's just fine

Lucas cotta wrote:so, what my application will search in the database, contractors or subcontractors?

I guess you are asking this question because in your instructions both "contractors" and "subcontractors" are used in the text to explain the specification (and/or data file content). I would stick to "contractors"
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic