Home > Blockchain >  Any advantage of using just string instead of URI uri = new URI(String) while doing resttemplate cal
Any advantage of using just string instead of URI uri = new URI(String) while doing resttemplate cal

Time:07-23

please let me know is there any advantage of using just string instead of URI uri = new URI(String) while doing resttemplate call

CodePudding user response:

Sure, it validates the string supplied and it throws IllegalArugumentException If the given string violates RFC 2396. So prevalidations would happen beforehand!

  • Related