---  
` [ _dont_implement_Matcher___instead_extend_BaseMatcher_
](../../../org/hamcrest/BaseMatcher.html#_dont_implement_Matcher___instead_extend_BaseMatcher_\(\))
, [ toString ](../../../org/hamcrest/BaseMatcher.html#toString\(\)) `  
**Methods inherited from class java.lang.Object**  
---  
` clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait,
wait `  
  
**Constructor Detail**  
---  
  
###  IsInstanceOf

    
    
    public **IsInstanceOf**(java.lang.Class<?> expectedClass)

     Creates a new instance of IsInstanceOf 

**Parameters:**      ` expectedClass ` \- The predicate evaluates to true for
instances of this class or one of its subclasses.

**Method Detail**  
---  
  
###  matches

    
    
    protected boolean **matches**(java.lang.Object item,
                              [Description](../../../org/hamcrest/Description.html "interface in org.hamcrest") mismatch)

    

**Specified by:**      ` [ matches
](../../../org/hamcrest/DiagnosingMatcher.html#matches\(java.lang.Object,
org.hamcrest.Description\)) ` in class ` [ DiagnosingMatcher
](../../../org/hamcrest/DiagnosingMatcher.html "class in org.hamcrest")
<java.lang.Object> `

    

* * *

###  describeTo

    
    
    public void **describeTo**([Description](../../../org/hamcrest/Description.html "interface in org.hamcrest") description)

     **Description copied from interface:` [ SelfDescribing ](../../../org/hamcrest/SelfDescribing.html#describeTo\(org.hamcrest.Description\)) ` **
     Generates a description of the object. The description may be part of a a description of a larger object of which this is just a component, so it should be worded appropriately. 

    

**Parameters:**      ` description ` \- The description to be built or
appended to.

* * *

###  instanceOf

    
    
    public static <T> [Matcher](../../../org/hamcrest/Matcher.html "interface in org.hamcrest")<T> **instanceOf**(java.lang.Class<?> type)

     Creates a matcher that matches when the examined object is an instance of the specified ` type ` , as determined by calling the ` Class.isInstance(Object) ` method on that type, passing the the examined object. 

The created matcher assumes no relationship between specified type and the
examined object.

For example:

    
    
    assertThat(new Canoe(), instanceOf(Paddlable.class));

    

* * *

###  any

    
    
    public static <T> [Matcher](../../../org/hamcrest/Matcher.html "interface in org.hamcrest")<T> **any**(java.lang.Class<T> type)

     Creates a matcher that matches when the examined object is an instance of the specified ` type ` , as determined by calling the ` Class.isInstance(Object) ` method on that type, passing the the examined object. 

The created matcher forces a relationship between specified type and the
examined object, and should be used when it is necessary to make generics
conform, for example in the JMock clause ` with(any(Thing.class)) `

For example:

    
    
    assertThat(new Canoe(), instanceOf(Canoe.class));

    

* * *

|  [ **Overview** ](../../../overview-summary.html) |  [ **Package** ](package-summary.html) |  **Class** |  [ **Use** ](class-use/IsInstanceOf.html) |  [ **Tree** ](package-tree.html) |  [ **Deprecated** ](../../../deprecated-list.html) |  [ **Index** ](../../../index-all.html) |  [ **Help** ](../../../help-doc.html)  
---|---|---|---|---|---|---|---  
__  
[ **PREV CLASS** ](../../../org/hamcrest/core/IsEqual.html "class in org.hamcrest.core") [ **NEXT CLASS** ](../../../org/hamcrest/core/IsNot.html "class in org.hamcrest.core") |  [ **FRAMES** ](../../../index.html?org/hamcrest/core/IsInstanceOf.html) [ **NO FRAMES** ](IsInstanceOf.html) [ **All Classes** ](../../../allclasses-noframe.html)  
SUMMARY: NESTED | FIELD |  CONSTR  |  METHOD  |  DETAIL: FIELD |  CONSTR  |  METHOD   
  
* * *