|
© 2001 BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.bea.commerce.platform.ad.AdHelper
A set of static methods which perform provide utilities services to the ad package.
Fields inherited from interface com.bea.commerce.platform.ad.AdConstants |
AD_EVENT_TRACKING, AD_RENDERING, AD_SERVICE_NAME, ADBUCKET_DB_NAME, ADBUCKET_SERVICE_NAME, ADCOUNT_DB_NAME, CONFLICT_RESOLVER_NAME, EVENT_SERVICE_NAME, GLOBAL_ADBUCKET_NAME |
Constructor Summary | |
AdHelper()
|
Method Summary | |
static java.lang.String |
getAdContent(java.lang.String adQuery,
long identifier,
java.lang.String containerUID,
java.lang.String contextUID,
java.lang.String placeholder,
java.lang.String userId,
java.lang.String servletBase,
Request request,
AdService as,
int height,
int width)
Return the content for an ad Query as an XHTML string. |
static AdService |
getAdService()
return the currently active AdService EJB |
static Content |
getContent(AdService as,
java.lang.String contentId)
return the Content object for the passed content id. |
static java.lang.String |
getMimeRenderingClass(java.lang.String mimeType)
Return the name of a class that may handle rendering for an unsupported mime type |
static int |
getNextRandom(int max)
Return a random number between [0,max)Returns a pseudorandom, uniformly distributed int value between 0 (inclusive) and the specified value max (exclusive). |
static AdContentProvider |
getRendering()
return the env-entry which defines if global ads are being mixed with context and container based ads. |
static void |
raiseClickThruEvent(java.lang.String userId,
javax.servlet.http.HttpServletRequest request,
java.lang.String containerUID,
java.lang.String contextUID,
java.lang.String placeholder,
java.lang.String contId)
raise a click thru event |
static void |
raiseDisplayEvent(java.lang.String userId,
javax.servlet.http.HttpServletRequest request,
java.lang.String containerUID,
java.lang.String contextUID,
java.lang.String placeholder,
java.lang.String contId)
raise an display event |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AdHelper()
Method Detail |
public static java.lang.String getAdContent(java.lang.String adQuery, long identifier, java.lang.String containerUID, java.lang.String contextUID, java.lang.String placeholder, java.lang.String userId, java.lang.String servletBase, Request request, AdService as, int height, int width) throws AdContentException, javax.ejb.CreateException
adQuery
- the content management queryindentifier
- a indentifier for the content bucket the query
is fromcontainerUID
- the UID of the containercontextUID
- the UID of the contextplaceholder
- the name of the placeholderuserId
- the user IdservletBase
- the Web App root for the click thru servletrequest
- the HTTP requestas
- the AdService EJBheight
- the suggested content heightwidth
- the suggested content widthAdContent
- if there is a problem getting the contentpublic static Content getContent(AdService as, java.lang.String contentId)
as
- the AdService EJBcontentId
- the identifier of the content being requestedpublic static AdService getAdService() throws javax.ejb.CreateException
public static AdContentProvider getRendering()
public static java.lang.String getMimeRenderingClass(java.lang.String mimeType)
mimetype
- the mimetypepublic static void raiseDisplayEvent(java.lang.String userId, javax.servlet.http.HttpServletRequest request, java.lang.String containerUID, java.lang.String contextUID, java.lang.String placeholder, java.lang.String contId)
userId
- the user Idrequest
- the HTTP requestcontainerUID
- the UID for the containercontextUID
- the UID for the contextplaceholder
- the name of the placeholdercontId
- the content identifierpublic static void raiseClickThruEvent(java.lang.String userId, javax.servlet.http.HttpServletRequest request, java.lang.String containerUID, java.lang.String contextUID, java.lang.String placeholder, java.lang.String contId)
userId
- the user Idrequest
- the HTTP requestcontainerUID
- the UID for the containercontextUID
- the UID for the contextplaceholder
- the name of the placeholdercontId
- the content identifierpublic static int getNextRandom(int max)
max
- the max number to return
|
© 2001 BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |