public abstract class AbstractDescriptionWriter extends java.lang.Object implements DescriptionWriter
Base class to help implementing DescriptionWriter
s.
Constructor and Description |
---|
AbstractDescriptionWriter() |
Modifier and Type | Method and Description |
---|---|
DescriptionWriter |
putField(java.lang.String name,
java.lang.Object value)
Put an object field into the description.
|
DescriptionWriter |
putList(java.lang.String name,
java.lang.Iterable<?> objects)
Put a field with a list of values, using the default describer.
|
public DescriptionWriter putField(java.lang.String name, java.lang.Object value)
DescriptionWriter
Put an object field into the description.
putField
in interface DescriptionWriter
name
- The field name. It cannot begin with an underscore.value
- The field value. It is described with Descriptions.defaultDescriber()
}.public DescriptionWriter putList(java.lang.String name, java.lang.Iterable<?> objects)
DescriptionWriter
Put a field with a list of values, using the default describer.
putList
in interface DescriptionWriter
name
- The field name.objects
- The list of objects.