© 2002 BEA Systems, Inc.


com.bea.p13n.content.advislets
Class ContentQueryAdvisletImpl

java.lang.Object
  |
  +--com.bea.p13n.advisor.AbstractAdvislet
        |
        +--com.bea.p13n.content.advislets.ContentQueryAdvisletImpl

public final class ContentQueryAdvisletImpl
extends AbstractAdvislet
implements java.io.Serializable

This class is the implementation class for a ContentQuery Advislet. This Advislet can issue queries against the content management system and retrieve content.

Required inputs to the Advislet are:
HTTP_SESSION - the Session object.

HTTP_REQUEST - The Request object.

USER - the User object.

CONTENT_QUERY_MAX_ITEMS - the maximum number of items to return (Long).

CONTENT_QUERY_SORT_BY - how the items should be sorted (String).

CONTENT_QUERY_CONTEXT_PARAMS (optional)- any additional parameters to put into the content search (Map).

CONTENT_MANAGER (optional)- the Content Manager to use (ContentManager).

CONTENT_MANAGER_HOME - the JNDI home name of the Content Manager to use (String) if the supplied CONTENT_MANAGER is null.

In addition either of these properties should be specified. Failure to specify either of these properties will result in an empty content query being returned. CONTENT_QUERY_NODE - the content query (as XML) to execute (ContentQueryAdvice).

CONTENT_QUERY_STRING - the content query (as a String) to execute (String).

See Also:
Serialized Form

Fields inherited from class com.bea.p13n.advisor.AbstractAdvislet
advisletMetadata, advisor, parametersMap
 
Constructor Summary
ContentQueryAdvisletImpl(Advisor advisor, Metadata metadata)
           
 
Method Summary
 Advice getAdvice(AdviceRequest adviceRequest)
          This method makes recommendations based the AdviceRequest passed in.
 java.lang.Object[] getRequiredAttributes()
           
 
Methods inherited from class com.bea.p13n.advisor.AbstractAdvislet
getAdvisor, getMetadata, initialize, toString, validateAdviceRequest
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContentQueryAdvisletImpl

public ContentQueryAdvisletImpl(Advisor advisor,
                                Metadata metadata)
Method Detail

getAdvice

public Advice getAdvice(AdviceRequest adviceRequest)
                 throws java.lang.IllegalArgumentException,
                        AdvisorException
This method makes recommendations based the AdviceRequest passed in.

Parameters:
adviceRequest - The AdviceRequest used to make a recommendation.
Overrides:
getAdvice in class AbstractAdvislet

getRequiredAttributes

public java.lang.Object[] getRequiredAttributes()

Returns:
an Object[] that contains the attributes required by the Advislet. The array contains pairs of items: even items are are attribute names while odd items are the Class for the item.
Overrides:
getRequiredAttributes in class AbstractAdvislet

© 2002 BEA Systems, Inc.

Copyright © 2002 BEA Systems, Inc. All Rights Reserved