org.umber.crucible.old.templates.generic
Class GroupOp

java.lang.Object
  extended byorg.umber.crucible.old.templates.generic.GenericOp
      extended byorg.umber.crucible.old.templates.generic.ContentOp
          extended byorg.umber.crucible.old.templates.generic.GroupOp

public class GroupOp
extends ContentOp

A vertical or horizontal container of other ops, depending on whether the op was a <row> or <column> element. Can have a border and insets.

Author:
jsheets

Constructor Summary
GroupOp(Datum op, StyleMap styleMap)
          Creates a new instance of a vertically oriented GroupOp.
GroupOp(Datum op, StyleMap styleMap, int orientation)
          Creates a new instance of a GroupOp.
GroupOp(Datum op, StyleMap styleMap, StyleChain chain)
          Creates a new instance of a vertically oriented GroupOp with an optional StyleChain fallback.
GroupOp(Datum op, StyleMap styleMap, StyleChain chain, int orientation)
          Creates a new instance of a GroupOp with an optional StyleChain fallback.
 
Method Summary
 boolean isHorizontal()
          Determines if this group op should be oriented horizontally.
 boolean isVertical()
          Determines if this group op should be oriented vertically.
 java.util.List resolve(Datum xmlNode)
          Runs a Datum XML node through the op and returns a List of LayoutArea objects.
 
Methods inherited from class org.umber.crucible.old.templates.generic.GenericOp
createOp, createOp, getChain, getDatum, getDatumProperty, getOp, getOpType, getParameter, getStyleMap, resolveParameter, resolvePath, runQuery
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroupOp

public GroupOp(Datum op,
               StyleMap styleMap)
Creates a new instance of a vertically oriented GroupOp.

Parameters:
op - the XML template op to wrap
styleMap - the StyleMap to lookup named styles in

GroupOp

public GroupOp(Datum op,
               StyleMap styleMap,
               StyleChain chain)
Creates a new instance of a vertically oriented GroupOp with an optional StyleChain fallback. The StyleChain can be null.

Parameters:
op - the XML template op to wrap
styleMap - the StyleMap to lookup named styles in
chain - optional fallback StyleChain

GroupOp

public GroupOp(Datum op,
               StyleMap styleMap,
               int orientation)
Creates a new instance of a GroupOp.

Parameters:
op - the XML template op to wrap
styleMap - the StyleMap to lookup named styles in
orientation - the axis to arrange child objects along; can be LayoutGroup.VERTICAL or LayoutGroup.HORIZONTAL

GroupOp

public GroupOp(Datum op,
               StyleMap styleMap,
               StyleChain chain,
               int orientation)
Creates a new instance of a GroupOp with an optional StyleChain fallback. The StyleChain can be null.

Parameters:
op - the XML template op to wrap
styleMap - the StyleMap to lookup named styles in
chain - optional fallback StyleChain
orientation - the axis to arrange child objects along; can be LayoutGroup.VERTICAL or LayoutGroup.HORIZONTAL
Method Detail

isVertical

public boolean isVertical()
Determines if this group op should be oriented vertically.

Returns:
true if vertical, or false if horizontal

isHorizontal

public boolean isHorizontal()
Determines if this group op should be oriented horizontally.

Returns:
true if horizontal, or false if vertical

resolve

public java.util.List resolve(Datum xmlNode)
Runs a Datum XML node through the op and returns a List of LayoutArea objects.

Specified by:
resolve in class GenericOp
Parameters:
xmlNode - the input data node to run through the op
Returns:
a List of LayoutArea objects.