org.musicontroller.gui.components
Class SongList

java.lang.Object
  extended by org.apache.hivemind.impl.BaseLocatable
      extended by org.apache.tapestry.AbstractComponent
          extended by org.apache.tapestry.BaseComponent
              extended by org.musicontroller.gui.components.SongList
All Implemented Interfaces:
org.apache.hivemind.Locatable, org.apache.hivemind.LocationHolder, org.apache.tapestry.IComponent, org.apache.tapestry.IDirectEvent, org.apache.tapestry.internal.Component, org.apache.tapestry.IRender, org.apache.tapestry.ITemplateComponent

public abstract class SongList
extends org.apache.tapestry.BaseComponent

The component to show a list of Songs. Song-lists are very verbose. Because Hibernate loads everything lazily, it can very well be that we generate an OutOfMemoryException, while traversing through the SongList, initializing lazy-properties on our way. Because of that, this component throws objects away after rendering them. Note that this prevents OOME on huge lists, but penalizes the rendering of lists as well, because sometimes objects have to be fetched from the DB (or hopefully a 2nd-level cache) more than once.

Author:
Varienaja

Field Summary
 
Fields inherited from class org.apache.tapestry.AbstractComponent
_body, _bodyCount
 
Constructor Summary
SongList()
           
 
Method Summary
abstract  Dao getDao()
           
abstract  int getIndex()
           
 java.lang.String getLastplay()
           
abstract  Playlist getList()
           
abstract  McService getMcService()
          Getter for the MusiController services.
 java.lang.String getPlaycount()
           
 java.util.List<Playlist> getPlaylist()
          Returns the playlist the current song appears on.
abstract  Contract_PS getPlaylistcontract()
           
 java.lang.String getRequestcount()
           
 java.lang.String getRownumber()
           
abstract  boolean getShowbands()
           
 java.lang.String getSkipcount()
           
 Song getSong()
           
 java.util.Set<Contract_PS> getSongs()
           
abstract  User getUser()
           
abstract  void setIndex(int index)
           
abstract  void setList(Playlist playlist)
           
abstract  void setPlaylistcontract(Contract_PS contract)
           
 
Methods inherited from class org.apache.tapestry.BaseComponent
addOuter, finishLoad, getContainedRenderers, getInnerRenderers, renderComponent
 
Methods inherited from class org.apache.tapestry.AbstractComponent
addAsset, addBody, addComponent, checkActiveLock, cleanupAfterRender, enterActiveState, equals, finishLoad, generateClientId, getAsset, getAssets, getBeans, getBinding, getBindingNames, getBindings, getBody, getBodyCount, getBoundId, getClientId, getComponent, getComponents, getContainedComponent, getContainer, getEventInvoker, getExtendedId, getId, getIdPath, getListeners, getMessages, getNamespace, getPage, getRenderWorker, getSpecification, getSpecifiedId, getTemplateTagName, hasEvents, hashCode, isInActiveState, isParameterBound, isRendering, isStateful, pageEndRender, peekClientId, prepareForRender, render, renderBody, renderIdAttribute, renderInformalParameters, setBinding, setClientId, setContainedComponent, setContainer, setHasEvents, setId, setNamespace, setPage, setTemplateTagName, toString, triggerEvent
 
Methods inherited from class org.apache.hivemind.impl.BaseLocatable
getLocation, setLocation
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.apache.tapestry.IComponent
addAsset, addBody, addComponent, enterActiveState, getAsset, getAssets, getBeans, getBinding, getBindingNames, getBindings, getClientId, getComponent, getComponents, getContainedComponent, getContainer, getEventInvoker, getExtendedId, getId, getIdPath, getListeners, getMessages, getNamespace, getPage, getSpecification, getSpecifiedId, getTemplateTagName, isRendering, peekClientId, renderBody, setBinding, setClientId, setContainedComponent, setContainer, setId, setNamespace, setPage, setTemplateTagName
 
Methods inherited from interface org.apache.tapestry.IRender
render
 
Methods inherited from interface org.apache.hivemind.LocationHolder
setLocation
 
Methods inherited from interface org.apache.hivemind.Locatable
getLocation
 

Constructor Detail

SongList

public SongList()
Method Detail

getUser

public abstract User getUser()

getDao

public abstract Dao getDao()

getList

public abstract Playlist getList()

setList

public abstract void setList(Playlist playlist)

getShowbands

public abstract boolean getShowbands()

getPlaylistcontract

public abstract Contract_PS getPlaylistcontract()

setPlaylistcontract

public abstract void setPlaylistcontract(Contract_PS contract)

getIndex

public abstract int getIndex()

setIndex

public abstract void setIndex(int index)

getMcService

public abstract McService getMcService()
Getter for the MusiController services. This is injected by Spring.

Returns:
The Musicontroller service.

getSongs

public java.util.Set<Contract_PS> getSongs()

getSong

public Song getSong()

getPlaycount

public java.lang.String getPlaycount()

getRequestcount

public java.lang.String getRequestcount()

getSkipcount

public java.lang.String getSkipcount()

getLastplay

public java.lang.String getLastplay()

getRownumber

public java.lang.String getRownumber()

getPlaylist

public java.util.List<Playlist> getPlaylist()
Returns the playlist the current song appears on. This is used for displaying the cover art of this playlist. The result is a List containing just the playlist the current song is on.

Returns:


Copyright © 2010 A.J.V.. All Rights Reserved.