Examples of GxpContext


Examples of com.google.gxp.base.GxpContext

  @Inject @Flag(FlagName.ANALYTICS_ACCOUNT) String analyticsAccount;

  @Override
  public void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException {
    resp.setContentType("text/html");
    Admin.write(resp.getWriter(), new GxpContext(getLocale(req)),
        analyticsAccount, BuildinfoFragment.getGxpClosure(buildinfo));
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

    if (!userService.isUserAdmin()) {
      log.severe("Admin page requested by non-admin user!");
      throw new BadRequestException();
    }
    resp.setContentType("text/html");
    Admin.write(resp.getWriter(), new GxpContext(getLocale(req)),
        analyticsAccount, EMPTY_CONTENT);
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

            return a.getName().compareTo(b.getName());
          }
        });

    resp.setContentType("text/html");
    Admin.write(resp.getWriter(), new GxpContext(getLocale(req)),
        analyticsAccount, FlagsFragment.getGxpClosure(records, rawFlags));
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

    HtmlClosure content = StoreViewFragment.getGxpClosure(
        storeType, id, objectVersion == null ? "" : ("" + objectVersion),
        historyStart, historyEnd, items, snapshotVersion, snapshot);
    resp.setContentType("text/html");
    Admin.write(resp.getWriter(), new GxpContext(getLocale(req)),
        analyticsAccount, content);
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

     * Tells the GXP to write itself to the output stream.
     */
    public void execute(ActionInvocation actionInvocation) {
        GxpResourceProvider provider = getProvider();
        try {
            getGxpClosure().write(provider.getWriter(), new GxpContext(provider.getLocale(), outputXml));
        } catch (Exception e) {
            throw new RuntimeException("Exception while rendering "
                    + getGxpName()
                    + " coming from "
                    + actionInvocation.getAction().getClass().getName() + ".",
View Full Code Here

Examples of com.google.gxp.base.GxpContext

   
    String currentUrl = req.getRequestURI();
    // Display the page according to when the user last visited the story
    LivingStoryHtml.write(
        resp.getWriter(),
        new GxpContext(req.getLocale()),
        currentUrl,
        livingStory,
        userLoginService.getUserDisplayName(),
        userLoginService.createLoginUrl(currentUrl),
        userLoginService.createLogoutUrl(currentUrl),
View Full Code Here

Examples of com.google.gxp.base.GxpContext

public class ContentManagerServlet extends HttpServlet {
  @Override
  public void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException {
    ContentManagerHtml.write(
        resp.getWriter(),
        new GxpContext(req.getLocale()),
        new ExternalServiceKeyChain(getServletContext()).getMapsKey());
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

   */
  private void doAuthorizeTokenGet(
      HttpServletRequest req, HttpServletResponse resp, ParticipantId user) throws IOException {
    Preconditions.checkNotNull(user, "User must be supplied");
    // Ask the user for permission.
    OAuthAuthorizeTokenPage.write(resp.getWriter(), new GxpContext(req.getLocale()),
        DataApiTokenContainer.ACCESS_TOKEN_EXPIRATION, getOrGenerateXsrfToken(user));
    resp.setContentType(HTML_CONTENT_TYPE);
    resp.setStatus(HttpServletResponse.SC_OK);
    return;
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

  private void writeRegistrationPage(String message, String responseType, Locale locale,
      HttpServletResponse dest) throws IOException {
    dest.setCharacterEncoding("UTF-8");
    dest.setContentType("text/html;charset=utf-8");
    UserRegistrationPage.write(dest.getWriter(), new GxpContext(locale), domain, message,
        responseType, registrationDisabled, analyticsAccount);
  }
View Full Code Here

Examples of com.google.gxp.base.GxpContext

    }
  }

  private void render(HttpServletRequest req, HttpServletResponse resp,
      String query, List<Object> results) throws IOException {
    GqlServletHtml.write(resp.getWriter(), new GxpContext(req.getLocale()), query, results);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.