Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2000, 2008, Oracle and/or its affiliates. All rights reserved.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.campaign
Class AddAdToPlaceholderAction

    java.lang.Object
      com.bea.campaign.action.Action
          com.bea.campaign.AddAdToPlaceholderAction

All Implemented Interfaces
  Serializable

    public class AddAdToPlaceholderAction

extends Action

Action implementation to add an Ad query to the users placeholder.

This action understands the following action parameters:

- adQuery (required): either the String ad query expression or the `ContentQueryNode`.
- placeholder (required): the array of String placeholder ids.
- adWeight (required): the Integer ad weight/priority
- ttl (optional): time-to-live string in the form of "days:hours:minutes"
- expireDate (optional): TimeInstant or Timestamp of the expiration date.
- clearingPolicy (optional): String of either "campaign" (to clear all ads in the placeholders from the campaign), "all" (to clear all ads in the placeholders), or anything else to not clear the placeholders at all.

See Also
  Serialized Form

Field Summary
`static String` | `AD_EXPIRATION_DATE` The name of the expiration date parameter.
`static String` | `AD_QUERY` The name of adQuery action parameter.
`static String` | `AD_TTL` The name of the time-to-live parameter.
`static String` | `AD_WEIGHT` The name of the adWeight action parameter.
`static String` | `CLEARING_POLICY` The name of the clearing policy paramter.
`static String` | `PLACEHOLDER` The name of placeholder action parameter.
`static String` | `REMOVE` The name of the remove action parameter.

Constructor Summary
`AddAdToPlaceholderAction()`

Method Summary
`void` | `init(Map params)` Initialize this action from a set of action parameters.
`void` | `run()` Execute this action.
`String` | `toString()` Get string representation of this.

Methods inherited from class com.bea.campaign.action.Action
`getEvent, getRandom, getRequest, getScenario, getScenarioContainer, getScenarioContainerName, getScenarioId, getScenarioName, getServiceLocator, getSession, getTimestamp, getUser, getUserId, locateService, setEvent, setRandom, setRequest, setScenario, setScenarioContainer, setServiceLocator, setSession, setTimestamp, setUser`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### AD_QUERY

    public static final String AD_QUERY

  The name of adQuery action parameter.

  See Also
    Constants Summary

### PLACEHOLDER

    public static final String PLACEHOLDER

  The name of placeholder action parameter.

  See Also
    Constants Summary

### AD_WEIGHT

    public static final String AD_WEIGHT

  The name of the adWeight action parameter.

  See Also
    Constants Summary

### REMOVE

    public static final String REMOVE

  The name of the remove action parameter.

  See Also
    Constants Summary

### AD_TTL

    public static final String AD_TTL

  The name of the time-to-live parameter.

  See Also
    Constants Summary

### AD_EXPIRATION_DATE

    public static final String AD_EXPIRATION_DATE

  The name of the expiration date parameter.

  See Also
    Constants Summary

### CLEARING_POLICY

    public static final String CLEARING_POLICY

  The name of the clearing policy paramter.

  See Also
    Constants Summary

Constructor Detail

### AddAdToPlaceholderAction

    public AddAdToPlaceholderAction()

Method Detail

### run

    public void run()
             throws ActionException

  Execute this action.

  This will place the adQuery in the user's buckets for the named placeholders with the adWeight.

  Specified by:
    `run` in class `Action`
  Throws
    `ActionException` - thrown on an error.

### init

    public void init(Map params)
              throws IllegalArgumentException

  Initialize this action from a set of action parameters.

  See the class notes about that action parameters this action understands and requires.

  This method will be invoked by the `ActionService`.

  Specified by:
    `init` in class `Action`
  Parameters
    `the` - action parameters.
  Throws
    `IllegalArgumentException` - thrown on invalid action paramters.

### toString

    public String toString()

  Get string representation of this.

  Overrides:
    `toString` in class `Object`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000, 2008, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
Other names may be trademarks of their respective owners.