Class Source
java.lang.Object
com.yahoo.component.provider.FreezableClass
com.yahoo.search.pagetemplates.model.Source
- All Implemented Interfaces:
com.yahoo.component.provider.Freezable,PageElement
A source mentioned in a page template.
Two sources are equal if they have the same name and parameters.
- Author:
- bratseth
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(PageTemplateVisitor visitor) Accepts a visitor to this structurebooleanvoidfreeze()getName()Returns the name of this source (never null)getUrl()Returns the url of this source or null if noneinthashCode()Returns the parameters of this source as a live reference (never null).Returns the renderers or choices of renderers to apply on individual items of this sourcefinal voidvoidSets the url of this source.toString()Methods inherited from class com.yahoo.component.provider.FreezableClass
clone, ensureNotFrozen, isFrozenMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.yahoo.component.provider.Freezable
isFrozen
-
Field Details
-
any
The "any" source - used to mark that any source is acceptable here
-
-
Constructor Details
-
Source
-
-
Method Details
-
getName
Returns the name of this source (never null) -
setName
-
getUrl
Returns the url of this source or null if none -
setUrl
Sets the url of this source. If a source has an url (i.e this returns non-null), the content of the url is not fetched - fetching is left to the frontend by exposing this url in the result. -
renderers
Returns the renderers or choices of renderers to apply on individual items of this sourceIf this contains multiple renderers/choices, they are to be used on different types of hits returned by this source.
-
parameters
Returns the parameters of this source as a live reference (never null). The parameters will be passed to the provider getting source data. -
freeze
public void freeze()- Specified by:
freezein interfacecom.yahoo.component.provider.Freezable- Overrides:
freezein classcom.yahoo.component.provider.FreezableClass
-
accept
Accepts a visitor to this structure- Specified by:
acceptin interfacePageElement
-
hashCode
public int hashCode() -
equals
-
toString
-