Skip to content
Advertisement

How to check if only one ‘@’ symbol in email address using regex in java?

I am trying to create a regex in java to validate the email address. It should contain one uppercase one lowercase one digit only one @ symbol followed by ‘.’.So far i could only create this, scenarios like these abC.8@gmailcom this address should return false abC8@@gmail.com this also should return false But the above regex returns true for all these

OpenGTS Integration in Eclipse

OpenGTS Integration in Eclipse *Imported whole opengts code in to the eclispse workspace. *Created the four environment variables like GTS_HOME,CATALINA_HOME,ANT_HOME,JAVA_HOME as system variables. *In the next step am trying to configure the database for the opengts as they mentioned in the document. *Refer the link below “http://opengts.sourceforge.net/OpenGTS_Config.pdf”. Taking reference of above link Am trying to run the commands given in

multiple constructors for final fields in java

I have some final fields in the class like But this gives an error that final field ‘b’ might not have been initialized. So any help would be appreciated on how to handle final attributes initialization in case of multiple constructors. It works fine if I have only the second constructor. Answer You can initialize b to default false. All

Eclipse Shortcut for switching the class-windows

since 6 weeks i´m studying WI. Thats somewhere between business management and IT. We´re using eclipse and i´m looking for a shortcut that allows to switch between the class-windows like alt + tab for Windows…. windows^^. Thanks for help. Answer in tool bar go to Window>Preferences>General>key : change shortcut key as per your use and us can also fine another

Netty writeAndFlush() incomplete

My tcp client request netty server, and netty server use writeAndFlush() return 393718 bytes. But the client only receive 262142 bytes. I use “tcpdump -A” to apturing packets, less than 393718 too. So I think the properble is in netty writeAndFlush() function? Here is the code tcp server: server handler: tcp client: Answer You close the connection directly after writing,

Maven doesn’t run my testng.xml

When i’m running through testng.xml (right click on testng.xml, then run as TestNG) it works fine – 2 of the tests i have there are running, but when i’m running it from Maven (mvn test) it just perform build and doesn’t run the tests. BTW – i noticed that if i have classes with the word Test in them they

Advertisement