|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.pentaho.platform.engine.core.system.StandaloneApplicationContext
public class StandaloneApplicationContext
Constructor Summary | |
---|---|
StandaloneApplicationContext(String solutionRootPath,
String applicationPath)
|
|
StandaloneApplicationContext(String solutionRootPath,
String applicationPath,
Object context)
|
Method Summary | |
---|---|
void |
addEntryPointHandler(IPentahoSystemEntryPoint entryPoint)
Adds an entry point handler. |
void |
addExitPointHandler(IPentahoSystemExitPoint exitPoint)
Adds an exit point handler. |
File |
createTempFile(IPentahoSession session,
String prefix,
String extn,
boolean trackFile)
Creates a temporary file in the system/tmp solutions folder |
File |
createTempFile(IPentahoSession session,
String prefix,
String extn,
File parentDir,
boolean trackFile)
Creates a temporary file in the specified parent folder and optionally tracks it for deletion on session termination |
String |
getApplicationPath(String path)
Returns the path to the web application or standalone application. |
String |
getBaseUrl()
Returns a URL to the server application, up to and including the context. |
Object |
getContext()
|
String |
getFileOutputPath(String path)
Used for content output (temporary and otherwise), returns a fully qualified path suitable for creating a File object from. |
String |
getPentahoServerName()
Retrieves the descriptive name of the platform application. |
String |
getProperty(String key)
If there were any other properties set (for example, initParams in the servlet context), this will let you have access to all of those properties that are set. |
String |
getProperty(String key,
String defaultValue)
If there were any other properties set (for example, initParams in the servlet context), this will let you have access to all of those properties that are set. |
int |
getServerPort()
|
String |
getSolutionPath(String path)
Retrieves the fully qualified path to the location of the Pentaho solution, appending the path given in the parameter. |
String |
getSolutionRootPath()
|
void |
invokeEntryPoints()
Invokes all entry point handlers. |
void |
invokeExitPoints()
Invokes all exit point handlers. |
void |
removeEntryPointHandler(IPentahoSystemEntryPoint entryPoint)
Removes an entry point handler. |
void |
removeExitPointHandler(IPentahoSystemExitPoint exitPoint)
Removes an exit point handler. |
void |
setBaseUrl(String baseUrl)
|
void |
setContext(Object context)
|
void |
setProperties(Properties props)
|
void |
setSolutionRootPath(String solutionRootPath)
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StandaloneApplicationContext(String solutionRootPath, String applicationPath, Object context)
public StandaloneApplicationContext(String solutionRootPath, String applicationPath)
Method Detail |
---|
public void setBaseUrl(String baseUrl)
setBaseUrl
in interface IApplicationContext
public String getFileOutputPath(String path)
IApplicationContext
getFileOutputPath
in interface IApplicationContext
path
- Relative path within the solution to the file location. Solution path
will be pre-pended
public String getSolutionPath(String path)
IApplicationContext
getSolutionPath
in interface IApplicationContext
path
- a path to a location that exists relative to the solution tree
public void setSolutionRootPath(String solutionRootPath)
setSolutionRootPath
in interface IApplicationContext
public File createTempFile(IPentahoSession session, String prefix, String extn, boolean trackFile) throws IOException
IApplicationContext
createTempFile
in interface IApplicationContext
session
- - IPentahoSessionprefix
- - file prefixextn
- - file extensiontrackFile
- - true = add it to the session deleter
IOException
public File createTempFile(IPentahoSession session, String prefix, String extn, File parentDir, boolean trackFile) throws IOException
IApplicationContext
createTempFile
in interface IApplicationContext
session
- - IPentahoSessionprefix
- - file prefixextn
- - file extensionparentDir
- - parent folder to create the temp file intrackFile
- - true = add it to the session deleter
IOException
public String getPentahoServerName()
IApplicationContext
The Pentaho server name should specified in the system settings
configuration file, using the name
element
getPentahoServerName
in interface IApplicationContext
public int getServerPort()
public String getBaseUrl()
IApplicationContext
The URL that is returned is derived from the server context, and thus will include the protocol, host name, port, and application context root.
getBaseUrl
in interface IApplicationContext
public String getApplicationPath(String path)
IApplicationContext
getApplicationPath
in interface IApplicationContext
path
- a path to a location that exists relative to the application
root directory
public String getProperty(String key)
IApplicationContext
getProperty
in interface IApplicationContext
key
- property Name
public String getProperty(String key, String defaultValue)
IApplicationContext
getProperty
in interface IApplicationContext
key
- property NamedefaultValue
- default value if the property is not specified.
public void setProperties(Properties props)
public void addEntryPointHandler(IPentahoSystemEntryPoint entryPoint)
IApplicationContext
addEntryPointHandler
in interface IApplicationContext
public void removeEntryPointHandler(IPentahoSystemEntryPoint entryPoint)
IApplicationContext
removeEntryPointHandler
in interface IApplicationContext
public void addExitPointHandler(IPentahoSystemExitPoint exitPoint)
IApplicationContext
addExitPointHandler
in interface IApplicationContext
public void removeExitPointHandler(IPentahoSystemExitPoint exitPoint)
IApplicationContext
removeExitPointHandler
in interface IApplicationContext
public void invokeEntryPoints()
IApplicationContext
invokeEntryPoints
in interface IApplicationContext
public void invokeExitPoints()
IApplicationContext
invokeExitPoints
in interface IApplicationContext
public Object getContext()
getContext
in interface IApplicationContext
public void setContext(Object context)
setContext
in interface IApplicationContext
public String getSolutionRootPath()
getSolutionRootPath
in interface IApplicationContext
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |