001    package echopoint.layout;
002    
003    import nextapp.echo.app.LayoutData;
004    
005    /**
006     * A layout data implementation for child components that are added to the
007     * {@link echopoint.HtmlLayout} layout container.
008     *
009     * @author Simon Lei 2009-03-16
010     * @version $Id: HtmlLayoutData.java 152 2009-04-19 21:53:22Z sptrakesh $
011     * @since 3.0.0a11
012     */
013    public class HtmlLayoutData implements LayoutData
014    {
015      private static final long serialVersionUID = 1l;
016    
017      /** The DOM id for the container to which the child component is being added. */
018      private String containerId;
019    
020      /**
021       * Create a new layout data instance using the specified DOM id.
022       *
023       * @param containerId The DOM node id for the container.  Note that an
024       *   element with the specified id must exist in the layout HTML code.
025       */
026      public HtmlLayoutData( String containerId )
027      {
028        this.setContainerId( containerId );
029      }
030    
031      /**
032       * Return the DOM node id for the parent element of the component to which
033       * this layout applies.
034       *
035       * @return The parent node id.
036       */
037      public String getContainerId()
038      {
039        return containerId;
040      }
041    
042      /**
043       * Set the DOM node id for the parent element of the component to which
044       * this layout applies.
045       *
046       * @param containerId The parent node id to use.
047       */
048      public void setContainerId( String containerId )
049      {
050        this.containerId = containerId;
051      }
052    }