org.pentaho.platform.repository
Class SimpleRuntimeRepository

java.lang.Object
  extended by org.pentaho.platform.engine.core.system.PentahoBase
      extended by org.pentaho.platform.repository.SimpleRuntimeRepository
All Implemented Interfaces:
Serializable, ILogger, IRuntimeRepository

public class SimpleRuntimeRepository
extends PentahoBase
implements IRuntimeRepository

Author:
James Dixon This is a lightweight version on the runtime repository that will not persist any runtime elements. This class is intended for simple standalone applications that do not require workflow
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.pentaho.platform.engine.core.system.PentahoBase
EMPTYLOGID, LOGID_MASK1, LOGID_MASK2, LOGID_SEPARATOR
 
Fields inherited from interface org.pentaho.platform.api.engine.ILogger
ACTIVITY_LOG, DEBUG, ERROR, FATAL, INFO, INSTANCE_LOG, SESSION_LOG, SOLUTION_LOG, TRACE, UNKNOWN, WARN
 
Constructor Summary
SimpleRuntimeRepository()
           
 
Method Summary
 void exitPoint()
           
 Log getLogger()
           
 List getMessages()
           
static IPentahoSession getUserSession()
           
 IRuntimeElement loadElementById(String instanceId, Collection allowableReadAttributeNames)
          Loads an existing RuntimeElement
 IRuntimeElement newRuntimeElement(String parId, String parType, boolean transientOnly)
          Creates a new RuntimeElement
 IRuntimeElement newRuntimeElement(String parId, String parType, String solnId, boolean transientOnly)
          Creates a new RuntimeElement
 void setSession(IPentahoSession sess)
           
 boolean usesHibernate()
           
 
Methods inherited from class org.pentaho.platform.engine.core.system.PentahoBase
debug, debug, error, error, fatal, fatal, genLogIdFromInfo, genLogIdFromInfo, genLogIdFromSession, getLoggingLevel, getLogId, getObjectName, info, info, setLoggingLevel, setLogId, trace, trace, warn, warn
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.pentaho.platform.api.engine.ILogger
debug, debug, error, error, fatal, fatal, getLoggingLevel, info, info, setLoggingLevel, trace, trace, warn, warn
 

Constructor Detail

SimpleRuntimeRepository

public SimpleRuntimeRepository()
Method Detail

getUserSession

public static IPentahoSession getUserSession()
Returns:
Returns the userSession.

getMessages

public List getMessages()

setSession

public void setSession(IPentahoSession sess)
Specified by:
setSession in interface IRuntimeRepository
Parameters:
sess - The IPentahoSession to set

loadElementById

public IRuntimeElement loadElementById(String instanceId,
                                       Collection allowableReadAttributeNames)
                                throws RepositoryException
Loads an existing RuntimeElement

Specified by:
loadElementById in interface IRuntimeRepository
Parameters:
instId - The instance Id
Returns:
the RuntimeElement
Throws:
RepositoryException

newRuntimeElement

public IRuntimeElement newRuntimeElement(String parId,
                                         String parType,
                                         boolean transientOnly)
Creates a new RuntimeElement

Specified by:
newRuntimeElement in interface IRuntimeRepository
Parameters:
parId - Parent ID of this instance
parType - Parent type of the instance
transientOnly - Indicates whether this runtime element will be transient only (unsaved) or persistent. If true, then this will be in memory only, and will not be persisted when it goes out of scope.
Returns:
the created runtime element

newRuntimeElement

public IRuntimeElement newRuntimeElement(String parId,
                                         String parType,
                                         String solnId,
                                         boolean transientOnly)
Creates a new RuntimeElement

Specified by:
newRuntimeElement in interface IRuntimeRepository
Parameters:
parId - Parent Id of the runtime element
parType - Parent type of the runtime element
solnId - Solution Id of the element
transientOnly - Indicates whether this runtime element will be transient only (unsaved) or persistent. If true, then this will be in memory only, and will not be persisted when it goes out of scope.
Returns:
The created runtime element

getLogger

public Log getLogger()
Specified by:
getLogger in class PentahoBase

usesHibernate

public boolean usesHibernate()
Specified by:
usesHibernate in interface IRuntimeRepository

exitPoint

public void exitPoint()