org.jasig.portal.layout.alm
Class ALNode

java.lang.Object
  extended by org.jasig.portal.layout.alm.ALNode
All Implemented Interfaces:
IALNode, ILayoutNode
Direct Known Subclasses:
ALChannel, ALFolder

public abstract class ALNode
extends java.lang.Object
implements IALNode

IALNode summary sentence goes here.

Company: Instructional Media & Magic Prior to uPortal 2.5, this class existed in the package org.jasig.portal.layout. It was moved to its present package to reflect that it is part of Aggregated Layouts.

Version:
$Revision: 1.1.2.2 $
Author:
Michael Ivanov

Field Summary
private  java.lang.String nextNodeId
           
private  IALNodeDescription nodeDescription
           
private  java.lang.String parentNodeId
           
private  java.lang.String previousNodeId
           
private  int priority
           
 
Constructor Summary
ALNode()
           
ALNode(IALNodeDescription nd)
           
 
Method Summary
protected  void addNodeAttributes(org.w3c.dom.Element node)
          Add all of common node attributes to the Element.
static ALNode createALNode(IUserLayoutNodeDescription nodeDescription)
           
static IALNodeDescription createUserLayoutNodeDescription(org.w3c.dom.Element xmlNode)
          A factory method to create a IALNodeDescription instance, based on the information provided in the user layout Element.
 java.lang.String getFragmentId()
           
 java.lang.String getFragmentNodeId()
           
 java.lang.String getId()
           
 java.lang.String getNextNodeId()
           
 IUserLayoutNodeDescription getNodeDescription()
           
abstract  int getNodeType()
          Gets the node type
 java.lang.String getParentNodeId()
           
 java.lang.String getPreviousNodeId()
           
 int getPriority()
          Gets the priority value for this node.
 IUserLayoutRestriction getRestriction(java.lang.String restrictionName)
          Gets a restriction by the type.
 java.util.Collection getRestrictionsByPath(java.lang.String restrictionPath)
          Gets a restrictions list by a restriction path.
 void setNextNodeId(java.lang.String nextNodeId)
           
 void setNodeDescription(IALNodeDescription nd)
           
 void setParentNodeId(java.lang.String parentNodeId)
           
 void setPreviousNodeId(java.lang.String previousNodeId)
           
 void setPriority(int priority)
          Sets the priority for this node.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

parentNodeId

private java.lang.String parentNodeId

nextNodeId

private java.lang.String nextNodeId

previousNodeId

private java.lang.String previousNodeId

nodeDescription

private IALNodeDescription nodeDescription

priority

private int priority
Constructor Detail

ALNode

public ALNode()

ALNode

public ALNode(IALNodeDescription nd)
Method Detail

getId

public java.lang.String getId()
Specified by:
getId in interface ILayoutNode

getFragmentId

public java.lang.String getFragmentId()
Specified by:
getFragmentId in interface IALNode

getFragmentNodeId

public java.lang.String getFragmentNodeId()
Specified by:
getFragmentNodeId in interface IALNode

getNodeType

public abstract int getNodeType()
Gets the node type

Specified by:
getNodeType in interface ILayoutNode
Returns:
a node type

setNodeDescription

public void setNodeDescription(IALNodeDescription nd)

getNodeDescription

public IUserLayoutNodeDescription getNodeDescription()
Specified by:
getNodeDescription in interface ILayoutNode

setParentNodeId

public void setParentNodeId(java.lang.String parentNodeId)

getParentNodeId

public java.lang.String getParentNodeId()
Specified by:
getParentNodeId in interface ILayoutNode

setNextNodeId

public void setNextNodeId(java.lang.String nextNodeId)

getNextNodeId

public java.lang.String getNextNodeId()
Specified by:
getNextNodeId in interface ILayoutNode

setPreviousNodeId

public void setPreviousNodeId(java.lang.String previousNodeId)

getPreviousNodeId

public java.lang.String getPreviousNodeId()
Specified by:
getPreviousNodeId in interface ILayoutNode

setPriority

public void setPriority(int priority)
Sets the priority for this node.

Parameters:
priority - a int priority value

getPriority

public int getPriority()
Gets the priority value for this node.


getRestriction

public IUserLayoutRestriction getRestriction(java.lang.String restrictionName)
Gets a restriction by the type.

Parameters:
restrictionName - a String name of the restriction
Returns:
a IUserLayoutRestriction

getRestrictionsByPath

public java.util.Collection getRestrictionsByPath(java.lang.String restrictionPath)
Gets a restrictions list by a restriction path.

Parameters:
restrictionPath - a String restriction path
Returns:
a IUserLayoutRestriction

addNodeAttributes

protected void addNodeAttributes(org.w3c.dom.Element node)
Add all of common node attributes to the Element.

Parameters:
node - an Element value

createUserLayoutNodeDescription

public static IALNodeDescription createUserLayoutNodeDescription(org.w3c.dom.Element xmlNode)
                                                          throws PortalException
A factory method to create a IALNodeDescription instance, based on the information provided in the user layout Element.

Parameters:
xmlNode - a user layout DTD folder/channel Element value
Returns:
an IALNodeDescription value
Throws:
PortalException - if the xml passed is somehow invalid.

createALNode

public static ALNode createALNode(IUserLayoutNodeDescription nodeDescription)
                           throws PortalException
Throws:
PortalException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object