org.test4j.hamcrest.matcher.property.reflection
类 InnerDifferenceFinder.InnerDifferenceVisitor

java.lang.Object
  继承者 org.test4j.hamcrest.matcher.property.reflection.InnerDifferenceFinder.InnerDifferenceVisitor
所有已实现的接口:
DifferenceVisitor<Difference,String>
包容类:
InnerDifferenceFinder

protected static class InnerDifferenceFinder.InnerDifferenceVisitor
extends Object
implements DifferenceVisitor<Difference,String>

The visitor for visiting the difference tree.


字段摘要
protected  ObjectFormatter objectFormatter
          Formatter for object values.
 
构造方法摘要
protected InnerDifferenceFinder.InnerDifferenceVisitor()
           
 
方法摘要
 Difference visit(ClassDifference classDifference, String argument)
          Visits a class difference.
 Difference visit(CollectionDifference collectionDifference, String indexString)
          Returns the difference at the field with the given index.
 Difference visit(Difference difference, String key)
          Returns null, there are no inner differences for a simple difference.
 Difference visit(MapDifference mapDifference, String keyString)
          Returns the difference at the given key.
 Difference visit(ObjectDifference objectDifference, String fieldName)
          Returns the difference at the field with the given name.
 Difference visit(UnorderedCollectionDifference unorderedCollectionDifference, String indexString)
          Returns the best matching difference at the field with the given index.
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

字段详细信息

objectFormatter

protected ObjectFormatter objectFormatter
Formatter for object values.

构造方法详细信息

InnerDifferenceFinder.InnerDifferenceVisitor

protected InnerDifferenceFinder.InnerDifferenceVisitor()
方法详细信息

visit

public Difference visit(Difference difference,
                        String key)
Returns null, there are no inner differences for a simple difference.

指定者:
接口 DifferenceVisitor<Difference,String> 中的 visit
参数:
difference - The difference, not null
key - The key
返回:
null

visit

public Difference visit(ObjectDifference objectDifference,
                        String fieldName)
Returns the difference at the field with the given name.

指定者:
接口 DifferenceVisitor<Difference,String> 中的 visit
参数:
objectDifference - The difference, not null
fieldName - The field name, not null
返回:
The difference, null if there is no difference

visit

public Difference visit(ClassDifference classDifference,
                        String argument)
从接口 DifferenceVisitor 复制的描述
Visits a class difference.

指定者:
接口 DifferenceVisitor<Difference,String> 中的 visit
参数:
classDifference - The difference
argument - An optional argument, null if NA
返回:
The result

visit

public Difference visit(MapDifference mapDifference,
                        String keyString)
Returns the difference at the given key. The string represenation (using the object formatter) of the keys in the map are compared with the given key string.

指定者:
接口 DifferenceVisitor<Difference,String> 中的 visit
参数:
mapDifference - The difference, not null
keyString - The key as a string, not null
返回:
The difference, null if there is no difference

visit

public Difference visit(CollectionDifference collectionDifference,
                        String indexString)
Returns the difference at the field with the given index.

指定者:
接口 DifferenceVisitor<Difference,String> 中的 visit
参数:
collectionDifference - The difference, not null
indexString - The index number as a string, not null
返回:
The difference, null if there is no difference

visit

public Difference visit(UnorderedCollectionDifference unorderedCollectionDifference,
                        String indexString)
Returns the best matching difference at the field with the given index.

指定者:
接口 DifferenceVisitor<Difference,String> 中的 visit
参数:
unorderedCollectionDifference - The difference, not null
indexString - The index number as a string, not null
返回:
The difference, null if there is no difference


Copyright © 2013. All rights reserved.