Package org.structr.web.common.RenderContext

Examples of org.structr.web.common.RenderContext.EditMode


        final RenderContext renderContext = RenderContext.getInstance(request, response, getEffectiveLocale(request));

        renderContext.setResourceProvider(config.getResourceProvider());

        final EditMode edit = renderContext.getEditMode(user);

        DOMNode rootElement = null;
        AbstractNode dataNode = null;

        String[] uriParts = PathHelper.getParts(path);
View Full Code Here


        final RenderContext renderContext = RenderContext.getInstance(request, response, getEffectiveLocale(request));

        renderContext.setResourceProvider(config.getResourceProvider());

        final EditMode edit = renderContext.getEditMode(user);

        DOMNode rootElement = null;
        AbstractNode dataNode = null;

        String[] uriParts = PathHelper.getParts(path);
View Full Code Here

    if (!detailMode && getProperty(hideOnIndex)) {
      return;
    }

    final EditMode editMode  = renderContext.getEditMode(securityContext.getUser(false));

    if (EditMode.RAW.equals(editMode) || EditMode.WIDGET.equals(editMode)) {

      renderContent(securityContext, renderContext, depth);
View Full Code Here

   * @return true if node should be displayed
   */
  protected boolean displayForConditions(final SecurityContext securityContext, final RenderContext renderContext) {

    // In raw or widget mode, render everything
    EditMode editMode = renderContext.getEditMode(securityContext.getUser(false));
    if (EditMode.RAW.equals(editMode) || EditMode.WIDGET.equals(editMode)) {
      return true;
    }

    String _showConditions = getProperty(DOMNode.showConditions);
View Full Code Here

   * @return true if node should be displayed
   */
  protected boolean displayForLocale(final RenderContext renderContext) {

    // In raw or widget mode, render everything
    EditMode editMode = renderContext.getEditMode(securityContext.getUser(false));
    if (EditMode.RAW.equals(editMode) || EditMode.WIDGET.equals(editMode)) {
      return true;
    }

    String localeString = renderContext.getLocale().toString();
View Full Code Here

    if (isDeleted() || isHidden() || !displayForLocale(renderContext) || !displayForConditions(securityContext, renderContext)) {
      return;
    }

    String id            = getUuid();
    EditMode edit        = renderContext.getEditMode(securityContext.getUser(false));
    boolean inBody       = renderContext.inBody();
    AsyncBuffer out       = renderContext.getBuffer();

    String _contentType = getProperty(contentType);
View Full Code Here

      return;
    }

    // final variables
    final AsyncBuffer out    = renderContext.getBuffer();
    final EditMode editMode  = renderContext.getEditMode(securityContext.getUser(false));
    final boolean isVoid     = isVoidElement();
    final String _tag        = getProperty(DOMElement.tag);

    // non-final variables
    Result localResult                 = renderContext.getResult();
View Full Code Here

   * @param renderContext
   */
  private void renderCustomAttributes(final AsyncBuffer out, final SecurityContext securityContext, final RenderContext renderContext) throws FrameworkException {

    dbNode = this.getNode();
    EditMode editMode = renderContext.getEditMode(securityContext.getUser(false));

    Iterable<String> props = dbNode.getPropertyKeys();
    for (String key : props) {

      if (key.startsWith("data-")) {
View Full Code Here

   *
   * @param out
   */
  private void renderStructrAppLib(final AsyncBuffer out, final SecurityContext securityContext, final RenderContext renderContext, final int depth) throws FrameworkException {

    EditMode editMode = renderContext.getEditMode(securityContext.getUser(false));

    if (!(EditMode.RAW.equals(editMode) || EditMode.WIDGET.equals(editMode)) && !renderContext.appLibRendered() && getProperty(new StringProperty(STRUCTR_ACTION_PROPERTY)) != null) {

      out
        .append(indent(depth))
View Full Code Here

TOP

Related Classes of org.structr.web.common.RenderContext.EditMode

Copyright © 2018 www.massapicom. 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.