Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9023307
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T05:43:47+00:00 2026-06-16T05:43:47+00:00

in this period I am studying the Spring MVC showcase example dowlodable from STS

  • 0

in this period I am studying the Spring MVC showcase example dowlodable from STS dashboard

In my home.jsp view I have the following link:

<a id="request" class="textLink" href="<c:url value="/data/standard/request" />">Request arguments</a>

This link generate an HTTP Request towards the URL: “/data/standard/request”

This is the method of my controller class that handles this HTTP Request:

@RequestMapping(value="/data/standard/request", method=RequestMethod.GET)
public @ResponseBody String standardRequestArgs(HttpServletRequest request, Principal user, Locale locale) {
    StringBuilder buffer = new StringBuilder();     // Rappresenta un buffer (sequenza mutabile di caratteri) API compatibile con StreamBuffer
    buffer.append("request = ").append(request).append(", ");
    buffer.append("userPrincipal = ").append(user).append(", ");
    buffer.append("requestLocale = ").append(locale);
    return buffer.toString();
}

This method take 3 parameter and I have not clear some of these:

  • HttpServletRequest request: Reading the javadoc I can read that this object: Extends the ServletRequest interface to provide request information for HTTP servlets but: what kind of information?

The buffer content related to this object is: request = org.apache.catalina.connector.RequestFacade@62c77dc3 what exactly means?

  • Principal user: Reading the javadoc I can read that this object: *This interface represents the abstract notion of a principal, which can be used to represent any entity, such as an individual, a corporation, and a login id. *

I have not clear what exactly can I put in this object and why the related content in the buffers is null

Someone can help me?

thanks

Andrea

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T05:43:49+00:00Added an answer on June 16, 2026 at 5:43 am

    HttpServletRequest : Object that is filled by Container. The object is filled by the servlet container i.e. your server which may be tomcat , weblogic . The object contains the information of request parameters, session information. You have little control over this object.

    Principal user : User which has logged into your container for accessing the application. If you have added security in the container then the object will give you details for the user who has logged into: User Name, Roles (reals informations.)

    Locale locale : The locale of the user accessing your web application.

    As far as the response for StringBuffer is concerned, the reference to an object of HttpServletRequest is printed. The object is filled by the servlet container.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In this period I am studying the Sping MVC showcase example dowlodable form STS
In this period I am studing the Spring MVC Showcase example dowlodable from the
In this period I am studing the Spring MVC showcase example (downloadable from STS
in this period I am studying the Spring MVC showcase example. Now I am
My IQueryable line is: // find all timesheets for this period - from db
in this period I am learning Haskell but I have problems solving a simple
I succeeded to make simple and small example which integrates between Spring MVC and
i have developed ads website but i have problem, i want make period from
I am trying to have information displayed for this query: SELECT o.sub_number,o.unique_id,o.period_from,o.period_to,o.total_amt, i.paid_amt,i.dated,i.payment,i.paid_by,i.entered_date,i.paid_for_unique, j.cheque_num,j.drawn_on,j.dated
Also is it possible to combine this with removing periods from within the string?

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.