public String getCreateMethod() {
   StringBuilder builder = new StringBuilder();
   builder.append(viewGenerator.getCallInitViewMethod(false));
   builder.append(viewGenerator.getCallSetFontsMethod(false));
   builder.append(viewGenerator.getCallSetListenersMethod(false));
   return String.format(ONCREATE_PATTERN, activityResource.getReference(), builder.toString());
 }
  public String generate() {
    StringBuilder stringBuilder = new StringBuilder();
    if (packageName != null && !packageName.isEmpty()) {
      stringBuilder.append(getPackage());
      stringBuilder.append("\n");
    }
    stringBuilder.append(getImports());
    stringBuilder.append(viewGenerator.getImports());
    stringBuilder.append("\n");

    StringBuilder innerBuilder = new StringBuilder();
    innerBuilder.append(getTag());
    innerBuilder.append("\n");
    innerBuilder.append(viewGenerator.getFields(false));
    innerBuilder.append("\n");
    innerBuilder.append(getCreateMethod());
    innerBuilder.append("\n");
    innerBuilder.append(getInitActionBarMethod());
    innerBuilder.append("\n");
    innerBuilder.append(viewGenerator.getInitViewsMethod(false));
    innerBuilder.append("\n");
    innerBuilder.append(viewGenerator.getSetFontsMethod(false));
    innerBuilder.append("\n");
    innerBuilder.append(viewGenerator.getSetListenersMethod(false));
    stringBuilder.append(
        String.format(HEADER_PATTERN, activityResource.getVariableName(), innerBuilder.toString()));
    return stringBuilder.toString();
  }
 public void addWidget(WidgetResource widgetResource, String typeName) {
   viewGenerator.addWidget(widgetResource, typeName);
 }