code: SyntheticField[] findField(List<SyntheticField> domainFields, String fieldName, String[] path,
              Class<?> type, boolean readOnlyField) throws JTransfoException {
          List<SyntheticField> fields = domainFields;
          SyntheticField[] result = new SyntheticField[path.length + 1];
          int index = 0;
          Class<?> currentType = type;
          for (; index < path.length; index++) {
              boolean found = false;
              for (SyntheticField field : fields) {
                  if (field.getName().equals(path[index])) {
                      found = true;
                      result[index] = field;
                      break;
                  }
              }
              if (!found) {
                  result[index] = new AccessorSyntheticField(reflectionHelper, currentType, path[index], readOnlyField);
              }
              currentType = result[index].getType();
              fields = reflectionHelper.getSyntheticFields(currentType);
          }
          for (SyntheticField field : fields) {
              if (field.getName().equals(fieldName)) {
                  result[index] = field;
                  return result;
              }
          }
          result[index] = new AccessorSyntheticField(reflectionHelper, currentType, fieldName, readOnlyField);
          return result;
      }
docs: Find one field in a list of fields.
  
  @param domainFields list of fields in domain object
  @param fieldName field to search
  @param path list of intermediate fields for transitive fields
  @param type type of object to find fields in
  @param readOnlyField is the requested field read only
  @return field with requested name or null when not found
  @throws JTransfoException cannot find fields