org.hippoecm.hst.mock.core.container
Class MockHstComponentWindow

java.lang.Object
  extended by org.hippoecm.hst.mock.core.container.MockHstComponentWindow
All Implemented Interfaces:
HstComponentWindow

public class MockHstComponentWindow
extends Object
implements HstComponentWindow


Constructor Summary
MockHstComponentWindow()
           
 
Method Summary
 void addComponentExcpetion(HstComponentException e)
          Adds a component exceptions during initialization or runtime.
 void clearComponentExceptions()
          Adds a component exceptions during initialization or runtime.
 Object getAttribute(String name)
           
 Enumeration<String> getAttributeNames()
           
 HstComponentWindow getChildWindow(String name)
          The child component window which can be accessed by the name.
 HstComponentWindow getChildWindowByReferenceName(String referenceName)
          The child component window which can be accessed by the reference name.
 Map<String,HstComponentWindow> getChildWindowMap()
          The child component windows contained in this component window.
 List<String> getChildWindowNames()
          The child component window names contained in this component window.
 HstComponent getComponent()
          The actual HstComponent instance.
 List<HstComponentException> getComponentExceptions()
          The component exceptions during initialization or runtime.
 HstComponentInfo getComponentInfo()
           
 String getComponentName()
          The HstComponent name.
 String getLocalParameter(String name)
           
 String getName()
          The name of the component window.
 String getNamedRenderer()
           
 String getNamedResourceServer()
           
 String getPageErrorHandlerClassName()
           
 String getParameter(String name)
           
 HstComponentWindow getParentWindow()
          The parent component window containing this component window.
 String getReferenceName()
          The reference name of the component window.
 String getReferenceNamespace()
          The reference namespace of the component window.
 String getRenderPath()
          The dispatching path path to render this component window.
 HstResponseState getResponseState()
          Returns the response state of this component window
 String getServeResourcePath()
          The dispatching path path to serve resource in this component window.
 boolean hasComponentExceptions()
          Whether it has component exceptions or not
 Object removeAttribute(String name)
           
 void setAttribute(String name, Object value)
           
 void setComponent(HstComponent component)
           
 void setComponentInfo(HstComponentInfo componentInfo)
           
 void setLocalParameter(String name, String value)
           
 void setName(String name)
           
 void setNamedRenderer(String namedRenderer)
           
 void setNamedResourceServer(String namedResourceServer)
           
 void setPageErrorHandlerClassName(String pageErrorHandlerClassName)
           
 void setParameter(String name, String value)
           
 void setParentWindow(HstComponentWindow parentWindow)
           
 void setReferenceName(String referenceName)
           
 void setReferenceNamespace(String referenceNamespace)
           
 void setRenderPath(String renderPath)
           
 void setResponseState(HstResponseState responseState)
           
 void setServeResourcePath(String serveResourcePath)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MockHstComponentWindow

public MockHstComponentWindow()
Method Detail

addComponentExcpetion

public void addComponentExcpetion(HstComponentException e)
Description copied from interface: HstComponentWindow
Adds a component exceptions during initialization or runtime.

Specified by:
addComponentExcpetion in interface HstComponentWindow

clearComponentExceptions

public void clearComponentExceptions()
Description copied from interface: HstComponentWindow
Adds a component exceptions during initialization or runtime.

Specified by:
clearComponentExceptions in interface HstComponentWindow

getChildWindow

public HstComponentWindow getChildWindow(String name)
Description copied from interface: HstComponentWindow
The child component window which can be accessed by the name.

Specified by:
getChildWindow in interface HstComponentWindow
Parameters:
name - the name of the child component window
Returns:
the child component window which has the referenceName

getChildWindowByReferenceName

public HstComponentWindow getChildWindowByReferenceName(String referenceName)
Description copied from interface: HstComponentWindow
The child component window which can be accessed by the reference name.

Specified by:
getChildWindowByReferenceName in interface HstComponentWindow
Parameters:
referenceName - the referenceName of the child component window
Returns:
the child component window which has the referenceName

getChildWindowMap

public Map<String,HstComponentWindow> getChildWindowMap()
Description copied from interface: HstComponentWindow
The child component windows contained in this component window.

Specified by:
getChildWindowMap in interface HstComponentWindow
Returns:
the component windows contained in this component window

getChildWindowNames

public List<String> getChildWindowNames()
Description copied from interface: HstComponentWindow
The child component window names contained in this component window.

Specified by:
getChildWindowNames in interface HstComponentWindow
Returns:
the component window names contained in this component window

getComponent

public HstComponent getComponent()
Description copied from interface: HstComponentWindow
The actual HstComponent instance.

Specified by:
getComponent in interface HstComponentWindow
Returns:
the actual HstComponent instance

setComponent

public void setComponent(HstComponent component)

getComponentName

public String getComponentName()
Description copied from interface: HstComponentWindow
The HstComponent name. Normally the component name is fully qualified class name.

Specified by:
getComponentName in interface HstComponentWindow
Returns:
the HstComponent name

getComponentExceptions

public List<HstComponentException> getComponentExceptions()
Description copied from interface: HstComponentWindow
The component exceptions during initialization or runtime.

Specified by:
getComponentExceptions in interface HstComponentWindow
Returns:
the possible component exception list

getName

public String getName()
Description copied from interface: HstComponentWindow
The name of the component window.

Specified by:
getName in interface HstComponentWindow
Returns:
the name of the component window

setName

public void setName(String name)

getParentWindow

public HstComponentWindow getParentWindow()
Description copied from interface: HstComponentWindow
The parent component window containing this component window.

Specified by:
getParentWindow in interface HstComponentWindow
Returns:
the component window containing this component window

setParentWindow

public void setParentWindow(HstComponentWindow parentWindow)

getReferenceName

public String getReferenceName()
Description copied from interface: HstComponentWindow
The reference name of the component window.

Specified by:
getReferenceName in interface HstComponentWindow
Returns:
the reference name of the component window

setReferenceName

public void setReferenceName(String referenceName)

getReferenceNamespace

public String getReferenceNamespace()
Description copied from interface: HstComponentWindow
The reference namespace of the component window.

Specified by:
getReferenceNamespace in interface HstComponentWindow
Returns:
the reference namespace of the component window

setReferenceNamespace

public void setReferenceNamespace(String referenceNamespace)

getRenderPath

public String getRenderPath()
Description copied from interface: HstComponentWindow
The dispatching path path to render this component window.

Specified by:
getRenderPath in interface HstComponentWindow
Returns:
the dispatching path to render this component window

setRenderPath

public void setRenderPath(String renderPath)

getNamedRenderer

public String getNamedRenderer()
Specified by:
getNamedRenderer in interface HstComponentWindow
Returns:
the name of the renderer, when using named servlet. Returns null when HstComponentWindow.getRenderPath() does not return null
See Also:
HstComponentWindow.getRenderPath()

setNamedRenderer

public void setNamedRenderer(String namedRenderer)

getResponseState

public HstResponseState getResponseState()
Description copied from interface: HstComponentWindow
Returns the response state of this component window

Specified by:
getResponseState in interface HstComponentWindow

setResponseState

public void setResponseState(HstResponseState responseState)

getServeResourcePath

public String getServeResourcePath()
Description copied from interface: HstComponentWindow
The dispatching path path to serve resource in this component window.

Specified by:
getServeResourcePath in interface HstComponentWindow
Returns:
the dispatching path to serve resource in this component window

setServeResourcePath

public void setServeResourcePath(String serveResourcePath)

getNamedResourceServer

public String getNamedResourceServer()
Specified by:
getNamedResourceServer in interface HstComponentWindow
Returns:
the name of the resource server, when using named servlet. Returns null when HstComponentWindow.getServeResourcePath() does not return null
See Also:
HstComponentWindow.getServeResourcePath()

setNamedResourceServer

public void setNamedResourceServer(String namedResourceServer)

getPageErrorHandlerClassName

public String getPageErrorHandlerClassName()
Specified by:
getPageErrorHandlerClassName in interface HstComponentWindow
Returns:
the fully classified className of the class implementing PageErrorHandler

setPageErrorHandlerClassName

public void setPageErrorHandlerClassName(String pageErrorHandlerClassName)

getParameter

public String getParameter(String name)
Specified by:
getParameter in interface HstComponentWindow
Parameters:
name - the name of the parameter
Returns:
the configured parameter value for this name and null if not existing
See Also:
org.hippoecm.hst.configuration.components.HstComponentConfiguration#getParameter(String)}

setParameter

public void setParameter(String name,
                         String value)

getLocalParameter

public String getLocalParameter(String name)
Specified by:
getLocalParameter in interface HstComponentWindow
Returns:
the configured parameter value for this name and null if not existing
See Also:
org.hippoecm.hst.configuration.components.HstComponentConfiguration#getLocalParameter(String)}

setLocalParameter

public void setLocalParameter(String name,
                              String value)

hasComponentExceptions

public boolean hasComponentExceptions()
Description copied from interface: HstComponentWindow
Whether it has component exceptions or not

Specified by:
hasComponentExceptions in interface HstComponentWindow
Returns:

getComponentInfo

public HstComponentInfo getComponentInfo()
Specified by:
getComponentInfo in interface HstComponentWindow
Returns:

setComponentInfo

public void setComponentInfo(HstComponentInfo componentInfo)

getAttribute

public Object getAttribute(String name)
Specified by:
getAttribute in interface HstComponentWindow
Returns:

setAttribute

public void setAttribute(String name,
                         Object value)
Specified by:
setAttribute in interface HstComponentWindow

removeAttribute

public Object removeAttribute(String name)
Specified by:
removeAttribute in interface HstComponentWindow
Returns:

getAttributeNames

public Enumeration<String> getAttributeNames()
Specified by:
getAttributeNames in interface HstComponentWindow
Returns:


Copyright © 2008-2012 Hippo. All Rights Reserved.