public static String dump(Object comp) throws Exception {
        StringBuilder b = new StringBuilder();
        b.append("//" + comp.toString() + ":\n");
        b.append("// In\n");
        ComponentAccess cp = new ComponentAccess(comp);
        for (Access in : cp.inputs()) {
            String name = in.getField().getName();
            Object val = in.getFieldValue();
            b.append("    " + name + ": " + Conversions.convert(val, String.class) + "\n");
        }
        b.append("// Out\n");
        for (Access in : cp.outputs()) {
            String name = in.getField().getName();
            Object val = in.getFieldValue();
            b.append("    " + name + ": " + Conversions.convert(val, String.class) + "\n");
        }
        b.append("\n");
        return b.toString();
    }