Nitido Inc.

com.nitido.nimbox.http.services.ad
Class NiMAdService

java.lang.Object
  extended by com.nitido.nimbox.http.services.ad.NiMAdService
Direct Known Subclasses:
SimpleAdService

public abstract class NiMAdService
extends java.lang.Object

This interface defines the methods for accessing the NiM Ad Service.


Field Summary
static java.lang.String KEY_AD_DEST
           
static java.lang.String KEY_AD_SRC
           
static java.lang.String KEY_TRACKING_ID
           
 
Constructor Summary
protected NiMAdService()
          Default constructor
 
Method Summary
protected  SkinAd copySkinAd(SkinAd ad)
          This method returns a deep copy of the given AD parameter.
protected  SkinAdMap copySkinAdMap(SkinAdMap original)
          return a copy of the original SkinAdMap
protected  SkinAd createSkinAd(java.lang.String id, java.lang.String linkURL, java.lang.String content, java.lang.String description)
          This method is used by extenders of this class to create a new instance of a Skin AD.
protected  SkinAdMap createSkinAdMap(java.lang.String skinID, boolean enableDisplayTracking)
          This method is used by extenders of this class to create a new instance of an empty SkinMap.
abstract  SkinAdMap getAdMap(Entity entity, NimletOutput output)
          This method returns the set of Ads to be displayed for the given entity and skin.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

KEY_TRACKING_ID

public static final java.lang.String KEY_TRACKING_ID
See Also:
Constant Field Values

KEY_AD_SRC

public static final java.lang.String KEY_AD_SRC
See Also:
Constant Field Values

KEY_AD_DEST

public static final java.lang.String KEY_AD_DEST
See Also:
Constant Field Values
Constructor Detail

NiMAdService

protected NiMAdService()
Default constructor

Method Detail

getAdMap

public abstract SkinAdMap getAdMap(Entity entity,
                                   NimletOutput output)
This method returns the set of Ads to be displayed for the given entity and skin.

Parameters:
entity - Reference to the Entity that is making the request.
output - Reference to the NimletOutput object that resulted from the execution of a Nimlet. This NimletOutput object contains the skin name that is going to be dispatched to the user.

createSkinAdMap

protected SkinAdMap createSkinAdMap(java.lang.String skinID,
                                    boolean enableDisplayTracking)
This method is used by extenders of this class to create a new instance of an empty SkinMap.

Returns:
A new instance of an empty SkinMap

copySkinAdMap

protected SkinAdMap copySkinAdMap(SkinAdMap original)
return a copy of the original SkinAdMap

Parameters:
original - Reference to the SkinAdMap to be copied
Returns:
Copy of the given SkinAdMap

createSkinAd

protected SkinAd createSkinAd(java.lang.String id,
                              java.lang.String linkURL,
                              java.lang.String content,
                              java.lang.String description)
This method is used by extenders of this class to create a new instance of a Skin AD.

Parameters:
id - The AD id. This parameter cannot be null or an empty string.
linkURL - URL to the Ad. This parameter cannot be null or an empty string.
content - The AD content. This parameter cannot be null or an empty string.
description - The AD description.
Throws:
java.lang.IllegalArgumentException - If the link or image URL is null or an empty string

copySkinAd

protected SkinAd copySkinAd(SkinAd ad)
This method returns a deep copy of the given AD parameter.

Parameters:
ad - The AD to be copied
Returns:
Reference to a new AD that is a copy of the given AD parameter.
Throws:
java.lang.IllegalArgumentException - If the given AD parameter is null

Nitido NiM 2.5 Java API

These JavaDoc pages are generated for release/nim_2_5-2.5.44

Copyright © 1999-2009 Nitido Inc.    Proprietary and Confidential.    All Rights Reserved.