Javatpoint Logo
Javatpoint Logo

Java URL getUserInfo() Method

The getUserInfo() method of URL class returns the userInfo part of this URL in the form of the string. If the user information is not available, it returns null.

Syntax

Returns

The userInfo part of this URL, or null if one does not exist

Since

1.3

Example 1

Test it Now

Output:

user information is :null
https://mail.google.com/mail/u/0/?tab=wm#inbox

Example 2

Test it Now

Output:

The given url is : https://www.javatpoint.com/java-threadpoolexecutor
User information of given url is : null
Next TopicJava URL Class





Youtube For Videos Join Our Youtube Channel: Join Now

Feedback


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA