Examples of WODynamicGroup


Examples of com.webobjects.appserver._private.WODynamicGroup

    }
    WOElement obj = null;
    if (nsmutablearray != null && nsmutablearray.count() == 1) {
      Object obj2 = nsmutablearray.objectAtIndex(0);
      if (obj2 instanceof WOComponentReference) {
        obj = new WODynamicGroup(_name, null, (WOElement) obj2);
      }
      else {
        obj = (WOElement) obj2;
      }
    }
    else {
      obj = new WODynamicGroup(_name, null, nsmutablearray);
    }
    return obj;
  }
View Full Code Here

Examples of com.webobjects.appserver._private.WODynamicGroup

    private WOElement template(WOComponent component) {
      WOElement content =  component._childTemplate();
      WOElement result = null;
      String templateName = (_templateName == null) ? null : (String) _templateName.valueInComponent(component);
      if (content instanceof WODynamicGroup) {
      WODynamicGroup group = (WODynamicGroup) content;
      if (templateName == null) {
        // MS: If you don't set a template name, then let's construct all the children of
        // this element that are NOT ERXWOTemplate's, so we don't double-display.  This lets
        // you use an ERXWOComponentContent and have it just act like a "default" template
        // that skips all the children that are explicitly wrapped in an ERXWOTemplate.
        NSMutableArray<WOElement> originalChildrenElements = group.childrenElements();
        if (originalChildrenElements != null && originalChildrenElements.count() > 0) {
          NSMutableArray<WOElement> nonTemplateChildrenElements = new NSMutableArray<WOElement>();
          for (WOElement originalChild : originalChildrenElements) {
            if (!(originalChild instanceof ERXWOTemplate)) {
              nonTemplateChildrenElements.addObject(originalChild);
            }
          }
          result = new WODynamicGroup(null, null, nonTemplateChildrenElements);
        }
      }
      else {
            for(Enumeration e = group.childrenElements().objectEnumerator(); e.hasMoreElements() && result == null ; ) {
              WOElement current = (WOElement) e.nextElement();
              if(current instanceof ERXWOTemplate) {
                ERXWOTemplate template = (ERXWOTemplate)current;
                String name = template.templateName(component);
                if(name.equals(templateName)) {
View Full Code Here

Examples of com.webobjects.appserver._private.WODynamicGroup

  public boolean hastTemplateInComponent() {
    boolean result = false;

    WOElement content =  _childTemplate();
    if (content instanceof WODynamicGroup) {
      WODynamicGroup group = (WODynamicGroup) content;
      for(Enumeration<WOElement> e = group.childrenElements().objectEnumerator(); e.hasMoreElements() && !result ; ) {
        WOElement current = e.nextElement();
        if(current instanceof ERXWOTemplate) {
          result = true;
        }
      }
View Full Code Here

Examples of com.webobjects.appserver._private.WODynamicGroup

    boolean result = false;

    WOElement content = _childTemplate();
    if (content instanceof WODynamicGroup)
    {
      WODynamicGroup group = (WODynamicGroup) content;
      for (Enumeration<WOElement> e = group.childrenElements().objectEnumerator(); e.hasMoreElements() && !result;)
      {
        WOElement current = e.nextElement();
        if (current instanceof ERXWOTemplate)
        {
          result = true;
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.