File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes HttpServletRequest Class methods Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "HttpServletRequest Class methods" Watch "HttpServletRequest Class methods" New topic
Author

HttpServletRequest Class methods

Sumi Festus
Greenhorn

Joined: Feb 04, 2005
Posts: 14
Hi!! I was just reading through some servlet class and came across this code: Principal principal=req.getUserPrincipal();

Here req is an object of the HttpServletRequest class. principal is an object of the java.security.Principal.

Is the getUserPrincipal() method implemented in the HttpServletRequest class? I read the sun techdocs and couldnt find the method listed in the HttpServletRequest class.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

It is defined in the HttpSerlvetRequest interface :
http://java.sun.com/j2ee/1.4/docs/api/javax/servlet/http/HttpServletRequest.html


[My Blog]
All roads lead to JavaRanch
Sumi Festus
Greenhorn

Joined: Feb 04, 2005
Posts: 14
Thanks a lot.....
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: HttpServletRequest Class methods
 
Similar Threads
Get Request
difference between HttpServletRequest's getUserPrincipal and getRemoteUser
How do I get a UserDetails object from a Principal object?
Security Question about Handle class
LDAP authentication in a web application.