|
||||||||||
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.PentahoBase org.pentaho.platform.engine.services.PentahoMessenger org.pentaho.platform.repository.solution.SolutionRepositoryBase
public abstract class SolutionRepositoryBase
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.repository.ISolutionRepository |
---|
ACTION_ADMIN, ACTION_CREATE, ACTION_DELETE, ACTION_EXECUTE, ACTION_SHARE, ACTION_SUBSCRIBE, ACTION_UPDATE, FILE_ADD_FAILED, FILE_ADD_INVALID_PUBLISH_PASSWORD, FILE_ADD_INVALID_USER_CREDENTIALS, FILE_ADD_SUCCESSFUL, FILE_EXISTS, INDEX_FILENAME, REPOSITORY_SERVICE_CACHE_REGION, 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 | |
---|---|
SolutionRepositoryBase()
|
Method Summary | |
---|---|
int |
addSolutionFile(String baseUrl,
String path,
String fileName,
byte[] data,
boolean overwrite)
Adds a solution to the solution repository defined by the url that is built by concatenating baseUrl, path, and fileName. |
int |
addSolutionFile(String baseUrl,
String path,
String fileName,
File f,
boolean overwrite)
Adds a solution to the solution repository defined by the url that is built by concatenating baseUrl, path, and fileName. |
ISolutionFile |
createFolder(File newFolder)
This method creates a new folder in the Repository |
String[] |
getAllActionSequences()
Deprecated. |
ISolutionFile |
getFileByPath(String path)
Deprecated. |
org.dom4j.Document |
getFullSolutionTree(int actionOperation,
ISolutionFilter filter)
|
org.dom4j.Document |
getFullSolutionTree(int actionOperation,
ISolutionFilter filter,
ISolutionFile startingFile)
|
String |
getLocalizedFileProperty(ISolutionFile resourceFile,
String key)
Deprecated. |
String |
getLocalizedFileProperty(ISolutionFile resourceFile,
String key,
int actionOperation)
This method retrieves a locale aware value given a key and a file. |
org.apache.commons.logging.Log |
getLogger()
|
org.dom4j.Document |
getNavigationUIDocument(String solution,
String path,
int actionOperation)
Get an XML document that describes the structure of the solution repository. |
byte[] |
getResourceAsBytes(IActionSequenceResource actionResource,
boolean getLocalizedResource)
Deprecated. |
byte[] |
getResourceAsBytes(IActionSequenceResource actionResource,
boolean getLocalizedResource,
int actionOperation)
See getResourceInputBytes(String solutionPath). |
byte[] |
getResourceAsBytes(String solutionPath,
boolean getLocalizedResource)
Deprecated. |
byte[] |
getResourceAsBytes(String solutionPath,
boolean getLocalizedResource,
int actionOperation)
See getResourceInputBytes(String solutionPath). |
org.dom4j.Document |
getResourceAsDocument(IActionSequenceResource actionResource)
Deprecated. |
org.dom4j.Document |
getResourceAsDocument(IActionSequenceResource actionResource,
int actionOperation)
See getResourceInputStream(IActionResource actionResource). |
org.dom4j.Document |
getResourceAsDocument(String solutionPath)
Deprecated. |
org.dom4j.Document |
getResourceAsDocument(String solutionPath,
int actionOperation)
See getResourceInputStream(String solutionPath). |
String |
getResourceAsString(IActionSequenceResource actionResource)
Deprecated. |
String |
getResourceAsString(IActionSequenceResource actionResource,
int actionOperation)
See getResourceInputStream(IActionResource actionResource). |
String |
getResourceAsString(String solutionPath)
Deprecated. |
String |
getResourceAsString(String solutionPath,
int actionOperation)
See getResourceInputStream(String solutionPath). |
org.pentaho.commons.connection.IPentahoStreamSource |
getResourceDataSource(IActionSequenceResource actionResource)
Deprecated. |
org.pentaho.commons.connection.IPentahoStreamSource |
getResourceDataSource(IActionSequenceResource actionResource,
int actionOperation)
See getResourceInputStream(IActionResource actionResource). |
org.pentaho.commons.connection.IPentahoStreamSource |
getResourceDataSource(String solutionPath)
Deprecated. |
org.pentaho.commons.connection.IPentahoStreamSource |
getResourceDataSource(String solutionPath,
int actionOperation)
See getResourceInputStream(String solutionPath). |
InputStream |
getResourceInputStream(IActionSequenceResource actionResource,
boolean getLocalizedResource)
Deprecated. |
InputStream |
getResourceInputStream(IActionSequenceResource actionResource,
boolean getLocalizedResource,
int actionOperation)
Given a IActionResource this method returns a InputStream that references the content of the actionResource. |
InputStream |
getResourceInputStream(String solutionPath,
boolean getLocalizedResource)
Deprecated. |
InputStream |
getResourceInputStream(String solutionPath,
boolean getLocalizedResource,
int actionOperation)
Returns an InputStream that contains the data of the resource defined by the solutionPath. |
Reader |
getResourceReader(IActionSequenceResource actionResource)
Deprecated. |
Reader |
getResourceReader(IActionSequenceResource actionResource,
int actionOperation)
See getResourceInputStream(IActionResource actionResource). |
Reader |
getResourceReader(String solutionPath)
Deprecated. |
Reader |
getResourceReader(String solutionPath,
int actionOperation)
See getResourceInputStream(String solutionPath). |
ISolutionFile |
getRootFolder(int actionOperation)
|
ISolutionFile |
getSolutionFile(IActionSequenceResource actionResource)
Deprecated. |
ISolutionFile |
getSolutionFile(IActionSequenceResource actionResource,
int actionOperation)
|
ISolutionFile |
getSolutionFile(String path)
Deprecated. |
ISolutionFile |
getSolutionFile(String path,
int actionOperation)
|
long |
getSolutionFileLastModified(String path)
Deprecated. |
org.dom4j.Document |
getSolutions(int actionOperation)
Gets an XML Document representing all the solutions and all the files within all the solutions |
String |
getXSLName(org.dom4j.Document document,
String solution,
String inputXSLName)
Interprets the XSL name coming in against the document to see if there are any repository-specific changes based on display type associated with the XSL name |
void |
init(IPentahoSession pentahoSession)
NOTE regarding old code: the cacheManager cannot be cached, because it is possible that the SolutionRepository implementation has a scope that is longer lived than the cacheManager. |
void |
localizeDoc(org.dom4j.Node document,
ISolutionFile file)
|
boolean |
removeSolutionFile(String solutionPath)
|
boolean |
removeSolutionFile(String solution,
String path,
String fileName)
this is the file based removeSolutionFile, used by subclasses |
void |
resetRepository()
Clears cached data for ALL users |
boolean |
resourceExists(String solutionPath)
Deprecated. |
long |
resourceSize(String solutionPath)
Deprecated. |
void |
setSession(IPentahoSession inSession)
Set the session for this session container. |
Methods inherited from class org.pentaho.platform.engine.services.PentahoMessenger |
---|
debug, debug, error, error, error, fatal, fatal, getMessages, getUserString, info, info, setMessages, trace, trace, warn, warn |
Methods inherited from class org.pentaho.platform.engine.core.system.PentahoBase |
---|
genLogIdFromInfo, genLogIdFromInfo, genLogIdFromSession, getLoggingLevel, getLogId, getObjectName, setLoggingLevel, setLogId |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.pentaho.platform.api.repository.ISolutionRepository |
---|
addPermission, getActionSequence, getAllActionSequences, getClassLoader, getEffectivePermissions, getMessages, getPermissions, getRepositoryName, getSolutionFileLastModified, getSolutions, getSolutionStructure, getSolutionTree, getSolutionTree, hasAccess, publish, publish, reloadSolutionRepository, resourceExists, resourceSize, setMessages, setPermissions, share, solutionSynchronizationSupported, supportsAccessControls, synchronizeSolutionWithSolutionSource |
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 |
---|
public SolutionRepositoryBase()
Method Detail |
---|
public org.apache.commons.logging.Log getLogger()
getLogger
in class PentahoBase
public void init(IPentahoSession pentahoSession)
init
in interface IPentahoInitializer
init
in interface ISolutionRepository
pentahoSession
- The current user sessionpublic void setSession(IPentahoSession inSession)
ISessionContainer
setSession
in interface ISessionContainer
inSession
- The IPentahoSession to setpublic InputStream getResourceInputStream(IActionSequenceResource actionResource, boolean getLocalizedResource, int actionOperation) throws FileNotFoundException
ISolutionRepository
getResourceInputStream
in interface ISolutionRepository
actionResource
- - resource to create a stream for.getLocalizedResource
- - flag to use to check if we should attempt to get a localized version of the resourceactionOperation
- - Type of action operation to be performed
FileNotFoundException
public void localizeDoc(org.dom4j.Node document, ISolutionFile file)
localizeDoc
in interface ISolutionRepository
public InputStream getResourceInputStream(String solutionPath, boolean getLocalizedResource, int actionOperation) throws FileNotFoundException
ISolutionRepository
getResourceInputStream
in interface ISolutionRepository
solutionPath
- - location of a resource.actionOperation
- - Type of action operation to be performed
FileNotFoundException
public Reader getResourceReader(IActionSequenceResource actionResource, int actionOperation) throws FileNotFoundException, IOException
ISolutionRepository
getResourceReader
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
FileNotFoundException
IOException
public Reader getResourceReader(String solutionPath, int actionOperation) throws FileNotFoundException, IOException
ISolutionRepository
getResourceReader
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
FileNotFoundException
IOException
public String getResourceAsString(IActionSequenceResource actionResource, int actionOperation) throws IOException
ISolutionRepository
getResourceAsString
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
IOException
public String getResourceAsString(String solutionPath, int actionOperation) throws IOException
ISolutionRepository
getResourceAsString
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
IOException
public byte[] getResourceAsBytes(IActionSequenceResource actionResource, boolean getLocalizedResource, int actionOperation) throws IOException
ISolutionRepository
getResourceAsBytes
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
IOException
public byte[] getResourceAsBytes(String solutionPath, boolean getLocalizedResource, int actionOperation) throws IOException
ISolutionRepository
getResourceAsBytes
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
IOException
public org.pentaho.commons.connection.IPentahoStreamSource getResourceDataSource(IActionSequenceResource actionResource, int actionOperation) throws FileNotFoundException
ISolutionRepository
getResourceDataSource
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
FileNotFoundException
public org.pentaho.commons.connection.IPentahoStreamSource getResourceDataSource(String solutionPath, int actionOperation) throws FileNotFoundException
ISolutionRepository
getResourceDataSource
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
FileNotFoundException
public org.dom4j.Document getResourceAsDocument(String solutionPath, int actionOperation) throws IOException
ISolutionRepository
getResourceAsDocument
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
IOException
public org.dom4j.Document getResourceAsDocument(IActionSequenceResource actionResource, int actionOperation) throws IOException
ISolutionRepository
getResourceAsDocument
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
IOException
public org.dom4j.Document getSolutions(int actionOperation)
ISolutionRepository
getSolutions
in interface ISolutionRepository
actionOperation
- Indicates what the list will be used for - execution or administration
public void resetRepository()
resetRepository
in interface ISolutionRepository
public ISolutionFile getRootFolder(int actionOperation)
getRootFolder
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
public String getXSLName(org.dom4j.Document document, String solution, String inputXSLName)
ISolutionRepository
getXSLName
in interface ISolutionRepository
public org.dom4j.Document getNavigationUIDocument(String solution, String path, int actionOperation)
ISolutionRepository
getNavigationUIDocument
in interface ISolutionRepository
solution
- String The name of the solution. If this is empty (null or ""), and path
is empty, return the root of the document. Otherwise return a document that
starts at the node specified by the solution and path in the solutionpath
- String The path of the interested folder. See notes for
parameter solution.actionOperation
- - Type of action operation to be performed
public int addSolutionFile(String baseUrl, String path, String fileName, File f, boolean overwrite)
ISolutionRepository
addSolutionFile
in interface ISolutionRepository
public int addSolutionFile(String baseUrl, String path, String fileName, byte[] data, boolean overwrite)
ISolutionRepository
addSolutionFile
in interface ISolutionRepository
public boolean removeSolutionFile(String solutionPath)
removeSolutionFile
in interface ISolutionRepository
public boolean removeSolutionFile(String solution, String path, String fileName)
removeSolutionFile
in interface ISolutionRepository
public org.dom4j.Document getFullSolutionTree(int actionOperation, ISolutionFilter filter)
getFullSolutionTree
in interface ISolutionRepository
public org.dom4j.Document getFullSolutionTree(int actionOperation, ISolutionFilter filter, ISolutionFile startingFile)
getFullSolutionTree
in interface ISolutionRepository
public ISolutionFile getSolutionFile(String path, int actionOperation)
getSolutionFile
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
public ISolutionFile getSolutionFile(IActionSequenceResource actionResource, int actionOperation)
getSolutionFile
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
public ISolutionFile createFolder(File newFolder) throws IOException
ISolutionRepository
createFolder
in interface ISolutionRepository
newFolder
- The File that points to the new folder to create
IOException
public String getLocalizedFileProperty(ISolutionFile resourceFile, String key, int actionOperation)
ISolutionRepository
getLocalizedFileProperty
in interface ISolutionRepository
actionOperation
- - Type of action operation to be performed
@Deprecated public String[] getAllActionSequences()
ISolutionRepository
getAllActionSequences
in interface ISolutionRepository
@Deprecated public String getLocalizedFileProperty(ISolutionFile resourceFile, String key)
ISolutionRepository
getLocalizedFileProperty
in interface ISolutionRepository
@Deprecated public byte[] getResourceAsBytes(String solutionPath, boolean getLocalizedResource) throws IOException
ISolutionRepository
getResourceAsBytes
in interface ISolutionRepository
IOException
@Deprecated public byte[] getResourceAsBytes(IActionSequenceResource actionResource, boolean getLocalizedResource) throws IOException
ISolutionRepository
getResourceAsBytes
in interface ISolutionRepository
IOException
@Deprecated public org.dom4j.Document getResourceAsDocument(String solutionPath) throws IOException
ISolutionRepository
getResourceAsDocument
in interface ISolutionRepository
IOException
@Deprecated public org.dom4j.Document getResourceAsDocument(IActionSequenceResource actionResource) throws IOException
ISolutionRepository
getResourceAsDocument
in interface ISolutionRepository
IOException
@Deprecated public String getResourceAsString(IActionSequenceResource actionResource) throws IOException
ISolutionRepository
getResourceAsString
in interface ISolutionRepository
IOException
@Deprecated public String getResourceAsString(String solutionPath) throws IOException
ISolutionRepository
getResourceAsString
in interface ISolutionRepository
IOException
@Deprecated public org.pentaho.commons.connection.IPentahoStreamSource getResourceDataSource(String solutionPath) throws FileNotFoundException
ISolutionRepository
getResourceDataSource
in interface ISolutionRepository
FileNotFoundException
@Deprecated public org.pentaho.commons.connection.IPentahoStreamSource getResourceDataSource(IActionSequenceResource actionResource) throws FileNotFoundException
ISolutionRepository
getResourceDataSource
in interface ISolutionRepository
FileNotFoundException
@Deprecated public InputStream getResourceInputStream(IActionSequenceResource actionResource, boolean getLocalizedResource) throws FileNotFoundException
ISolutionRepository
getResourceInputStream
in interface ISolutionRepository
actionResource
- - resource to create a stream for.getLocalizedResource
- - flag to use to check if we should attempt to get a localized version of the resource
FileNotFoundException
@Deprecated public InputStream getResourceInputStream(String solutionPath, boolean getLocalizedResource) throws FileNotFoundException
ISolutionRepository
getResourceInputStream
in interface ISolutionRepository
solutionPath
- - location of a resource.
FileNotFoundException
@Deprecated public Reader getResourceReader(IActionSequenceResource actionResource) throws FileNotFoundException, IOException
ISolutionRepository
getResourceReader
in interface ISolutionRepository
FileNotFoundException
IOException
@Deprecated public Reader getResourceReader(String solutionPath) throws FileNotFoundException, IOException
ISolutionRepository
getResourceReader
in interface ISolutionRepository
FileNotFoundException
IOException
@Deprecated public ISolutionFile getSolutionFile(String path)
getSolutionFile
in interface ISolutionRepository
@Deprecated public ISolutionFile getSolutionFile(IActionSequenceResource actionResource)
ISolutionRepository
getSolutionFile
in interface ISolutionRepository
@Deprecated public long getSolutionFileLastModified(String path)
ISolutionRepository
getSolutionFileLastModified
in interface ISolutionRepository
@Deprecated public boolean resourceExists(String solutionPath)
ISolutionRepository
resourceExists
in interface ISolutionRepository
solutionPath
- - path to the resource
@Deprecated public long resourceSize(String solutionPath)
ISolutionRepository
resourceSize
in interface ISolutionRepository
solutionPath
- - path to the resource
@Deprecated public ISolutionFile getFileByPath(String path)
getFileByPath
in interface ISolutionRepository
path
- the solution path to the desired resource
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |