|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Profiler
ProfilerService Jetspeed-2 Profiler service. Locates portal resources given a set of request parameters, properties, and attributes The Profiler is invoked during the request processing pipeline. It requires that the request context is already populated with the portal request and response, and capability and user information. The request context parameters, properties and attributes make up the profile criterion which the profiler uses to locate portal resources: 1. page 2. navigations 3. document lists In all cases, a fallback algorithm should be applied to fallback to default portal resources.
Method Summary | |
---|---|
ProfileLocator |
createLocator(RequestContext context)
Creates a new ProfileLocator object that can be managed by the current Profiler implementation |
PrincipalRule |
createPrincipalRule()
Factory for PrincipalRule, the container to connect profiling rule and (user) prinicpal |
ProfilingRule |
createProfilingRule(boolean standard)
Factory for Profiling Rule. |
RuleCriterion |
createRuleCriterion()
Factory for Rule Criterion |
void |
deletePrincipalRule(PrincipalRule rule)
|
void |
deleteProfilingRule(ProfilingRule rule)
|
ProfileLocator |
getDefaultProfile(RequestContext context,
String locatorName)
getDefaultProfile |
Map |
getDefaultProfileLocators(RequestContext context)
getDefaultProfileLocators |
ProfilingRule |
getDefaultRule()
Lookup the portal's default profiling rule. |
String[] |
getLocatorNamesForPrincipal(Principal principal)
For a given principal, find all supported locators and return a string array of locator names. |
ProfileLocator |
getProfile(RequestContext context,
ProfilingRule rule)
Get the Profile object using the request parameters and the rule. |
ProfileLocator |
getProfile(RequestContext context,
String locatorName)
Get the Profile object using the request parameters. |
Map |
getProfileLocators(RequestContext context,
Principal principal)
Gets all supported locators for a principal. |
ProfilingRule |
getRule(String id)
Given a rule id, get the rule |
ProfilingRule |
getRuleForPrincipal(Principal principal,
String locatorName)
For a given principal, lookup the associated profiling rule to that principal name. |
Collection |
getRules()
|
Collection |
getRulesForPrincipal(Principal principal)
For a given principal, find all supported locators and return a collection of principal rules. |
void |
setDefaultRule(String defaultRule)
Resets the default rule for this portal |
void |
setRuleForPrincipal(Principal principal,
ProfilingRule rule,
String locatorName)
For a given principal, associate a profiling rule to that principal name. |
void |
storePrincipalRule(PrincipalRule rule)
|
void |
storeProfilingRule(ProfilingRule rule)
|
Method Detail |
---|
ProfileLocator getProfile(RequestContext context, String locatorName) throws ProfilerException
context
- The request contextlocatorName
- The name of the profile locator to find i.e. "page", "docset", ...
ProfilerException
ProfileLocator getDefaultProfile(RequestContext context, String locatorName) throws ProfilerException
getDefaultProfile
Intstead of using the princpal found within the request, the DEFAULT_RULE_PRINCIPAL is used.
context
- The request contextlocatorName
- The name of the profile locator to find i.e. "page", "docset", ...
ProfilerException
ProfileLocator getProfile(RequestContext context, ProfilingRule rule) throws ProfilerException
context
- The request context
ProfilerException
ProfileLocator createLocator(RequestContext context)
context
- The request context
ProfilingRule getRuleForPrincipal(Principal principal, String locatorName)
principal
- Lookup the profiling rule based on this principal.locatorName
- the unique name of a locator for this principal/rule/locator
void setRuleForPrincipal(Principal principal, ProfilingRule rule, String locatorName)
principal
- Lookup the profiling rule based on this principal.locatorName
- the unique name of a locator for this principal/rule/locatorThe
- rule used to find profiles for this userProfilingRule getDefaultRule()
Collection getRules()
ProfilingRule getRule(String id)
id
-
String[] getLocatorNamesForPrincipal(Principal principal)
principal
- The given principal.
Collection getRulesForPrincipal(Principal principal)
principal
- The given principal.
Map getProfileLocators(RequestContext context, Principal principal) throws ProfilerException
context
- principal
-
ProfilerException
Map getDefaultProfileLocators(RequestContext context) throws ProfilerException
getDefaultProfileLocators
Gets all the supported locators for the DEFAULT_RULE_PRINCIPAL
context
-
ProfilerException
void storeProfilingRule(ProfilingRule rule) throws ProfilerException
ProfilerException
void deleteProfilingRule(ProfilingRule rule) throws ProfilerException
ProfilerException
void storePrincipalRule(PrincipalRule rule) throws ProfilerException
ProfilerException
void deletePrincipalRule(PrincipalRule rule) throws ProfilerException
ProfilerException
ProfilingRule createProfilingRule(boolean standard) throws ClassNotFoundException
standard
- true if standard rule is requested, false if fallback
ClassNotFoundException
- if the beanfactory couldn't instantiate the beanPrincipalRule createPrincipalRule() throws ClassNotFoundException
Replaces the previous Class.forName and .instantiate logic with the Spring based factory.
ClassNotFoundException
- if the beanfactory couldn't instantiate the beanRuleCriterion createRuleCriterion() throws ClassNotFoundException
ClassNotFoundException
- if the beanfactory couldn't instantiate the beanvoid setDefaultRule(String defaultRule)
defaultRule
- The default rule to set.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |