code: protected void appendFieldsIn(final Class<?> clazz) {
          if (clazz.isArray()) {
              this.reflectionAppendArray(this.getObject());
              return;
          }
          final Field[] fields = clazz.getDeclaredFields();
          AccessibleObject.setAccessible(fields, true);
          for (final Field field : fields) {
              final String fieldName = field.getName();
              if (this.accept(field)) {
                  try {
                      // Warning: Field.get(Object) creates wrappers objects
                      // for primitive types.
                      final Object fieldValue = this.getValue(field);
                      if (!excludeNullValues || fieldValue != null) {
                          this.append(fieldName, fieldValue);
                      }
                  } catch (final IllegalAccessException ex) {
                      //this can't happen. Would get a Security exception
                      // instead
                      //throw a runtime exception in case the impossible
                      // happens.
                      throw new InternalError("Unexpected IllegalAccessException: " + ex.getMessage());
                  }
              }
          }
      }
docs: <p>
  Appends the fields and values defined by the given object of the given Class.
  </p>
  
  <p>
  If a cycle is detected as an object is &quot;toString()'ed&quot;, such an object is rendered as if
  <code>Object.toString()</code> had been called and not implemented by the object.
  </p>
  
  @param clazz
  The class of object parameter