public abstract class Feed
extends com.exalead.access.feedapi.eval.mel.extension.AbstractMELType
Modifier and Type | Class and Description |
---|---|
static class |
Feed.Constants |
static class |
Feed.FieldsHolder |
Constructor and Description |
---|
Feed() |
Modifier and Type | Method and Description |
---|---|
<R,P> R |
accept(com.exalead.access.feedapi.eval.mel.extension.MELTypeVisitor<R,P> visitor,
P p) |
FeedTrigger.Result |
afterQuery(QueryContext context,
ResultFeed result)
Generic after query routine that is called after the feed's execution.
|
FeedTrigger.Result |
beforeQuery(QueryContext context)
Generic before query routine that is called before the feed's execution.
|
void |
disable(QueryContext context)
Disable this feed for the current running query.
|
void |
embed(QueryContext context,
boolean embedFeed)
Embed or not this feed for the current running query.
|
void |
enable(QueryContext context)
Enable this feed for the current running query.
|
abstract ResultFeed |
execute(QueryContext context)
Execute routine.
|
abstract ResultFeed |
get(QueryContext context,
java.lang.String id)
Get routine.
|
java.lang.String |
getActAsFeed()
Internal use only: Returns whether this feed should act as another feed (ie.
|
com.exalead.access.feedapi.v10.Parameter[] |
getAllSupportedParameters()
Get the complete list of the supported parameters of the feed
Note: you may NOT override this methods.
|
com.exalead.access.feedapi.v10.AvailableMetas |
getAvailableMetas(java.util.Map<java.lang.String,java.lang.String[]> feedConf)
Get the list of available metas for the given feed configuration.
|
com.exalead.access.configuration.v10.Feed.Property[] |
getDefaultProperties()
Get the default property mappings of the feed.
|
com.exalead.access.feedapi.v10.AvailableFeed |
getDefinition()
Return the feed definition
|
java.lang.String |
getDescription()
Return the description of this Feed.
|
abstract java.lang.String |
getDisplayName()
Return a human friendly name for this Feed, to be used by the Mashup Builder.
|
java.lang.String |
getEvaluatedParameter(QueryContext context,
java.lang.String name)
Get the first evaluated value or NULL of a given feed Parameter, according to the current query and with resolved MEL expressions.
|
java.util.List<java.lang.String> |
getEvaluatedParameters(QueryContext context,
java.lang.String name)
Get all evaluated values of a given feed Parameter, according to the current query and with resolved MEL expressions.
|
com.exalead.access.feedapi.eval.mel.extension.AbstractMELType.FieldsHolder |
getFields() |
java.lang.String |
getFullId()
Deprecated.
|
java.lang.String |
getGroup()
Return the group of this Feed.
|
java.lang.String |
getId()
Get the feed's ID
|
com.exalead.access.feedapi.v10.Parameter |
getParameter(java.lang.String name)
Get a specific Parameter given its name.
|
com.exalead.access.feedapi.v10.Parameter |
getParameterByName(java.lang.String name)
Deprecated.
|
java.util.List<com.exalead.access.feedapi.v10.Parameter> |
getParameters()
Get this feed's Parameter (raw, non resolved).
|
java.util.List<java.lang.String> |
getParametersNames(QueryContext context)
Get the values of the raw extra query string parameters
The parameters are prefixed by the feed ID
|
java.util.List<java.lang.String> |
getParametersNames(QueryContext context,
boolean prefixParameters)
Get the values of the raw extra query string parameters
|
java.util.List<java.lang.String> |
getParametersNamesFromPattern(QueryContext context)
Deprecated.
|
java.util.List<java.lang.String> |
getParametersNamesFromPattern(QueryContext context,
boolean prefixParameters)
Deprecated.
|
java.lang.String |
getParameterV(java.lang.String name)
Returns the first value of the given parameter name
|
Feed |
getSubFeed(java.lang.String id)
Returns the subfeed corresponding to the provided id, and null if not found.
|
java.util.List<Feed> |
getSubFeeds()
Get this feed's subfeeds.
|
protected abstract com.exalead.access.feedapi.v10.Parameter[] |
getSupportedParameters()
Get the list of supported parameters by this Feed.
|
protected java.lang.String[] |
getSupportedPatterns()
Deprecated.
|
java.util.List<FeedTrigger> |
getTriggers()
Internal use only: Get this feed's triggers.
|
void |
init()
Initialization method, called on Feed construction.
|
java.lang.Boolean |
isEmbedded(QueryContext context)
Returns whether this feed is embed or not for the current running query.
|
java.lang.Boolean |
isEmbeddedByDefault()
Returns whether this feed is embed by default
|
boolean |
isEnabled(QueryContext context)
Returns true if the current feed is enable for the current running query.
|
boolean |
isEnabledByDefault()
Returns whether this feed is enabled by default or not.
|
boolean |
isRootFeed(QueryContext context)
Returns whether this feed is the "Root Feed" of the query.
|
boolean |
isSynchronized()
Get whether this feed is synchronized or not.
|
protected Entry |
mapEntry(QueryContext context,
Entry entry,
com.exalead.access.configuration.v10.Feed.Property.MappingType mappingType)
Map the feed's entry with the configured properties
|
void |
mapPostResult(QueryContext context,
Entry parentEntry,
ResultFeed result)
Results properties mapping routine, automatically fun pre|post feed's execution (according to the mappingType parameter).
|
ResultFeed |
mapResult(QueryContext context,
ResultFeed result,
com.exalead.access.configuration.v10.Feed.Property.MappingType mappingType)
Results properties mapping routine, automatically fun pre|post feed's execution (according to the mappingType parameter).
|
void |
overrideParameter(QueryContext context,
java.lang.String name,
java.util.List<java.lang.String> values)
Override the parameter "name" with the given "values" for the current running query.
|
void |
overrideParameter(QueryContext context,
java.lang.String name,
java.lang.String value)
Override the parameter "name" with the given "value" for the current running query.
|
void |
setActAsFeed(java.lang.String actAsFeed)
Internal use only: Set whether this feed should act as another feed (ie.
|
void |
setEmbed(java.lang.Boolean embed)
Internal use only: Specifies if this feed should be embed or not by default
|
void |
setEnable(boolean enable)
Internal use only: Set whether this feed should be enabled by default or not.
|
void |
setId(java.lang.String id)
Internal use only: Set the feed's ID
The feed ID is unique with a page
|
void |
setParameters(java.util.List<com.exalead.access.feedapi.v10.Parameter> parameters)
Internal use only: Set the parameters (with raw, non resolved values) of this feed.
|
void |
setProperties(java.util.List<com.exalead.access.configuration.v10.Feed.Property> properties)
Internal use only: Set this feed's Properties mappings.
|
void |
setSynchronized(boolean sync)
Internal use only: Set whether this feed should be synchronized or not.
|
com.exalead.access.feedapi.v10.AvailableFeed |
setupDefinition()
Setup the feed definition with its supported parameters and how they should behave in the front-end.
|
void |
uninit()
Uninitialization method, called on Feed destruction (ex: When reloading the feed configuration).
|
collateTo, getFlags, rawStringValue, resolveField, resolveOperation, setFlags, stringValue, stringValue, visit, visitBoolean, visitCategory, visitCategory, visitFacet, visitFacet, visitFeed, visitList, visitMeta, visitNumber, visitString, visitUnknown
public abstract java.lang.String getDisplayName()
public java.lang.String getGroup()
public java.lang.String getDescription()
public abstract ResultFeed execute(QueryContext context) throws AccessException
context
- AccessException
public abstract ResultFeed get(QueryContext context, java.lang.String id) throws AccessException
context
- id
- AccessException
public com.exalead.access.feedapi.v10.AvailableMetas getAvailableMetas(java.util.Map<java.lang.String,java.lang.String[]> feedConf) throws AccessException
feedConf
- AccessException
protected abstract com.exalead.access.feedapi.v10.Parameter[] getSupportedParameters()
public com.exalead.access.feedapi.v10.Parameter[] getAllSupportedParameters()
@Deprecated protected java.lang.String[] getSupportedPatterns()
public com.exalead.access.configuration.v10.Feed.Property[] getDefaultProperties()
public void init() throws java.lang.Exception
java.lang.Exception
public void uninit()
public com.exalead.access.feedapi.v10.AvailableFeed setupDefinition()
public void disable(QueryContext context)
context
- public void enable(QueryContext context)
context
- public boolean isEnabled(QueryContext context)
context
- public ResultFeed mapResult(QueryContext context, ResultFeed result, com.exalead.access.configuration.v10.Feed.Property.MappingType mappingType) throws AccessException
context
- result
- mappingType
- AccessException
public void mapPostResult(QueryContext context, Entry parentEntry, ResultFeed result) throws AccessException
context
- result
- mappingType
- AccessException
protected Entry mapEntry(QueryContext context, Entry entry, com.exalead.access.configuration.v10.Feed.Property.MappingType mappingType) throws AccessException
context
- entry
- mappingType
- AccessException
public final java.util.List<java.lang.String> getParametersNames(QueryContext context)
context
- @Deprecated public final java.util.List<java.lang.String> getParametersNamesFromPattern(QueryContext context)
public final java.util.List<java.lang.String> getParametersNames(QueryContext context, boolean prefixParameters)
context
- prefixParameters
- true to prefix parameters name with the feedId, false otherwise@Deprecated public final java.util.List<java.lang.String> getParametersNamesFromPattern(QueryContext context, boolean prefixParameters)
public final java.util.List<java.lang.String> getEvaluatedParameters(QueryContext context, java.lang.String name)
context
- name
- AccessException
public final java.lang.String getEvaluatedParameter(QueryContext context, java.lang.String name)
context
- name
- public FeedTrigger.Result beforeQuery(QueryContext context)
context
- public FeedTrigger.Result afterQuery(QueryContext context, ResultFeed result)
context
- public final void overrideParameter(QueryContext context, java.lang.String name, java.util.List<java.lang.String> values)
context
- name
- values
- public final void overrideParameter(QueryContext context, java.lang.String name, java.lang.String value)
context
- name
- value
- public final boolean isRootFeed(QueryContext context)
context
- public final com.exalead.access.feedapi.v10.AvailableFeed getDefinition()
public boolean isEnabledByDefault()
public final java.util.List<Feed> getSubFeeds()
public final Feed getSubFeed(java.lang.String id)
id
- @Deprecated public final java.lang.String getFullId()
public final java.lang.String getId()
public void embed(QueryContext context, boolean embedFeed)
context
- embedFeed
- public java.lang.Boolean isEmbedded(QueryContext context)
public java.lang.Boolean isEmbeddedByDefault()
public com.exalead.access.feedapi.v10.Parameter getParameter(java.lang.String name)
name
- public java.lang.String getParameterV(java.lang.String name)
name
- public java.util.List<com.exalead.access.feedapi.v10.Parameter> getParameters()
@Deprecated public final com.exalead.access.feedapi.v10.Parameter getParameterByName(java.lang.String name)
public boolean isSynchronized()
public void setEnable(boolean enable)
public final void setId(java.lang.String id)
id
- public void setEmbed(java.lang.Boolean embed)
embed
- embed
public void setParameters(java.util.List<com.exalead.access.feedapi.v10.Parameter> parameters)
parameters
- public void setProperties(java.util.List<com.exalead.access.configuration.v10.Feed.Property> properties)
properties
- public java.util.List<FeedTrigger> getTriggers()
public void setSynchronized(boolean sync)
sync
- public void setActAsFeed(java.lang.String actAsFeed)
actAsFeed
- public java.lang.String getActAsFeed()
public com.exalead.access.feedapi.eval.mel.extension.AbstractMELType.FieldsHolder getFields()
getFields
in class com.exalead.access.feedapi.eval.mel.extension.AbstractMELType
public <R,P> R accept(com.exalead.access.feedapi.eval.mel.extension.MELTypeVisitor<R,P> visitor, P p)
accept
in interface com.exalead.access.feedapi.eval.mel.extension.MELType
accept
in class com.exalead.access.feedapi.eval.mel.extension.AbstractMELType
Copyright © 2013 Dassault Systèmes, All Rights Reserved.