SourceForge.net Logo

de.mindmatters.faces.spring.factory.context
Interface ScopedBeanStorage


public interface ScopedBeanStorage

Stores and loads a scoped bean (see ScopedBeanDefinition) to/from the appropriate scope of faces' external context.

Author:
andreas.kuhrwahl

Method Summary
 java.lang.Object load(java.lang.String beanName, ScopedBeanDefinition beanDefinition)
          Tries to get the scoped bean with the bean-name name from the appropriate scope of the external context of faces.
 void save(java.lang.String beanName, java.lang.Object bean, ScopedBeanDefinition beanDefinition)
          Tries to store the scoped bean bean with the bean-name name to the appropriate scope of the external context of faces.
 

Method Detail

load

public java.lang.Object load(java.lang.String beanName,
                             ScopedBeanDefinition beanDefinition)
Tries to get the scoped bean with the bean-name name from the appropriate scope of the external context of faces.

Parameters:
beanName - the name of the bean to load
beanDefinition - the BeanDefiniton of the bean to load
Returns:
the loaded bean or null if not yet saved
Throws:
FacesBeansException - in cases of errors (e.g. not the defined type)

save

public void save(java.lang.String beanName,
                 java.lang.Object bean,
                 ScopedBeanDefinition beanDefinition)
Tries to store the scoped bean bean with the bean-name name to the appropriate scope of the external context of faces.

Parameters:
beanName - the name of the bean to store
bean - the bean to store
beanDefinition - the BeanDefiniton of the bean to store
Throws:
FacesBeansException - in cases of errors

SourceForge.net Logo

Copyright © 2002 mindmatters GmbH & Co. KG