title: @RequestParam, name vs value attributes
body: <p>I am reading the <a href="http://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/web/bind/annotation/RequestParam.html#name--" rel="noreferrer">documentation</a> of the <code>@RequestParam</code> annotation in Spring MVC.</p>
  
  <p>What is the difference between <strong>name</strong> and <strong>value</strong> attributes?</p>
  
  <p>The documentation says:</p>
  
  <blockquote>
    <p>value : Alias for name().</p>
    
    <p>name: The name of the request parameter to bind to.</p>
  </blockquote>
  
  <p>What does it mean <em>Alias for name()</em> ?</p>
  
  <p>Suppose you have:</p>
  
  <p><code>http://localhost:8080/springmvc/hello/101?param1=10&amp;param2=20</code></p>
  
  <pre><code>public String getDetails(
      @RequestParam(value="param1", required=true) String param1,
      @RequestParam(value="param2", required=false) String param2){
          ...
  }
  </code></pre>
  
  <p>for example, <code>value="param1"</code> is the name of request-parameter to bind, while <code>String param1</code> is the object to bind to.</p>
  
  <p>How could I use <code>name</code> attribute here?</p>