ViewResultMatchers (Spring Framework 3.2.1.RELEASE API)
Date: 2013-01-24

org.springframework.test.web.servlet.result

## Class ViewResultMatchers

- java.lang.Object
- - org.springframework.test.web.servlet.result.ViewResultMatchers

-     public class ViewResultMatchers
      extends Object

  Factory for assertions on the selected view. An instance of this class is typically accessed via `MockMvcResultMatchers.view()`.
  Since:
    3.2

- - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `ViewResultMatchers()` Protected constructor.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `ResultMatcher` | `name(org.hamcrest.Matcher<? super String> matcher)` Assert the selected view name with the given Hamcrest `Matcher`.
    `ResultMatcher` | `name(String expectedViewName)` Assert the selected view name.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ViewResultMatchers

          protected ViewResultMatchers()

      Protected constructor. Use `MockMvcResultMatchers.view()`.

  - ### Method Detail

    - #### name

          public ResultMatcher name(org.hamcrest.Matcher<? super String> matcher)

      Assert the selected view name with the given Hamcrest `Matcher`.

    - #### name

          public ResultMatcher name(String expectedViewName)

      Assert the selected view name.