Package org.apache.shiro.mgt
Interface SubjectFactory
-
- All Known Implementing Classes:
DefaultSubjectFactory
public interface SubjectFactoryASubjectFactoryis responsible for constructingSubjectinstances as needed.- Since:
- 1.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SubjectcreateSubject(SubjectContext context)Creates a new Subject instance reflecting the state of the specified contextual data.
-
-
-
Method Detail
-
createSubject
Subject createSubject(SubjectContext context)
Creates a new Subject instance reflecting the state of the specified contextual data. The data would be anything required to required to construct aSubjectinstance and its contents can vary based on environment. Any data supported by Shiro core will be accessible by one of theSubjectContext'sget*orresolve*methods. All other data is available as mapattributes.- Parameters:
context- the contextual data to be used by the implementation to construct an appropriateSubjectinstance.- Returns:
- a
Subjectinstance created based on the specified context. - See Also:
SubjectContext
-
-