title: Why does p:resetInput require properties of a managed bean to be set to null first after the form is submitted?
body: <p>In a view scoped managed bean, I'm using <a href="http://www.primefaces.org/showcase/ui/misc/resetInput.xhtml" rel="nofollow"><code>&lt;p:resetInput&gt;</code></a> to clear the values held by the properties in the corresponding manged bean like,</p>
  
  <pre><code>&lt;p:commandButton value="Reset" update="panel" process="@this"&gt;
      &lt;p:resetInput target="panel" /&gt;
  &lt;/p:commandButton&gt;
  </code></pre>
  
  <p>This works fine.</p>
  
  <hr>
  
  <p>I have a submit button <code>&lt;p:commandButton&gt;</code> which when pressed causes the submitted values to be inserted into the database, if validation succeeds.</p>
  
  <pre><code>&lt;p:remoteCommand name="updateTable" update="dataTable"/&gt;
  
  &lt;p:panel id="panel" header="New"&gt;
      &lt;p:outputLabel for="property1" value="property1"/&gt;
  
      &lt;p:inputText id="property1" value="#{bean.property1}" required="true"&gt;
          &lt;f:validateLength minimum="2" maximum="100"/&gt;
      &lt;/p:inputText&gt;
  
      &lt;p:message for="property1" showSummary="false"/&gt;
  
      &lt;p:commandButton id="btnSubmit"
                       update="panel messages"
                       oncomplete="if(!args.validationFailed) {updateTable();}"
                       actionListener="#{bean.insert}"
                       value="Save"/&gt;
  
      &lt;p:commandButton value="Reset" update="panel" process="@this"&gt;
          &lt;p:resetInput target="panel" /&gt;
      &lt;/p:commandButton&gt;
  &lt;/p:panel&gt;
  </code></pre>
  
  <p>The command button invokes the <code>insert()</code> method in the managed bean which is defined as follows.</p>
  
  <pre><code>public void insert() {
      if (service.insert(property1)) {
          //...Popup a success message.
          reset(); //Invoke the following private method.
      } else {
          //...Show the cause of the failure.
      }
  }
  
  private void reset() {
      property1 = null; //Set this property of type String to null.
  }
  </code></pre>
  
  <p>If this <code>reset()</code> method is omitted, then <code>&lt;p:inputText&gt;</code> will not be cleared as obvious but then if I press the reset button as shown in XHTML, <code>&lt;p:inputText&gt;</code> should be cleared but it doesn't.</p>
  
  <p>The <a href="http://www.primefaces.org/showcase/ui/misc/resetInput.xhtml" rel="nofollow">showcase example</a> demonstrates exactly the same thing. Therefore, this behaviour appears to be documented but I don't understand why doesn't <code>&lt;p:resetInut&gt;</code> clear the value of <code>property1</code>, if the <code>reset()</code> method is omitted, in this case?</p>