code: public void export(Object obj, String prefix) {
          checkTypeCompatibility(obj.getClass());
          final boolean isNamespaceClassSet = namespaceClass != null;
          final Class c = isNamespaceClassSet ? namespaceClass : obj.getClass();
          for (final Field field : (declaredFieldsOnly ? c.getDeclaredFields() : c.getFields())) {
              Export export = field.getAnnotation(Export.class);
              if (Modifier.isStatic(field.getModifiers())) {
                  loadMemberVariable(field, export, c, true, prefix, null);
              } else {
                  loadMemberVariable(field, export, obj, true, prefix, null);
              }
          }
          Set<Class<?>> classAndInterfaces = Sets.newHashSet();
          getAllInterfaces(c, classAndInterfaces);
          classAndInterfaces.add(c);
          for (Class<?> cls : classAndInterfaces) {
              for (final Method method : (declaredFieldsOnly ? cls.getDeclaredMethods() : cls.getMethods())) {
                  Export export = method.getAnnotation(Export.class);
                  if (Modifier.isStatic(method.getModifiers())) {
                      loadMemberVariable(method, export, c, true, prefix, null);
                  } else {
                      loadMemberVariable(method, export, obj, true, prefix, null);
                  }
              }
          }
      }
docs: Export all public fields and methods of a given object instance, including static fields, that are annotated
  with {@link com.indeed.util.varexport.Export}. Also finds annotation on interfaces.
  @param obj object instance to export
  @param prefix prefix for variable names (e.g. "mywidget-")