|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.stratelia.webactiv.util.FileRepositoryManager
public class FileRepositoryManager
Field Summary | |
---|---|
static String |
CONTEXT_TOKEN
|
Method Summary | |
---|---|
static void |
copyFile(String from,
String to)
Copy a contents from a file to another one |
static void |
createAbsolutePath(String componentId,
String directoryName)
|
static void |
createAbsolutePath(String spaceId,
String componentId,
String directoryName)
Deprecated. |
static void |
createGlobalTempPath(String sDirectoryName)
|
static void |
createTempPath(String sComponentId,
String sDirectoryName)
|
static void |
createTempPath(String spaceId,
String componentId,
String directoryName)
Deprecated. |
static void |
deleteAbsolutePath(String sSpaceId,
String sComponentId,
String sDirectoryName)
|
static void |
deleteTempPath(String sSpaceId,
String sComponentId,
String sDirectoryName)
|
static String |
formatFileSize(long lSize)
Get the file size with the suitable unit |
static String |
formatFileUploadTime(long size)
|
static String |
getAbsolutePath(String sComponentId)
|
static String |
getAbsolutePath(String sSpaceId,
String sComponentId)
Deprecated. |
static String |
getAbsolutePath(String componentId,
String[] directoryName)
|
static String |
getAbsolutePath(String spaceId,
String componentId,
String[] directoryName)
Deprecated. |
static String[] |
getAttachmentContext(String str)
to create the array of the string this array represents the repertories where the files must be stored. |
static String |
getAvatarPath()
|
static String |
getComponentTemporaryPath(String sComponentId)
|
static String |
getDomainAuthenticationPropertiesPath(String domainName)
|
static String |
getDomainPropertiesPath(String domainName)
|
static String |
getExportTemplateRepository()
Gets the path of the repository that contains the templates to use in exports. |
static String |
getFileDownloadTime(long size)
Get the estimated download time |
static String |
getFileExtension(String fileName)
|
static String |
getFileIcon(boolean small,
String extension)
|
static String |
getFileIcon(boolean small,
String filename,
boolean isReadOnly)
|
static String |
getFileIcon(String extension)
|
static String |
getFileIcon(String extension,
boolean isReadOnly)
Get File icon |
static long |
getFileSize(String sourceFile)
Get the size of a file (in bytes) |
static String |
getRelativePath(String... directories)
Construct an OS specific relative path. |
static String |
getSecurityDirPath()
Gets the path of the directory in which all the resources related to the security in Silverpeas are stored. |
static String |
getTemporaryPath()
|
static String |
getTemporaryPath(String sSpaceId,
String sComponentId)
|
static long |
getUploadMaximumFileSize()
Gets the file size limit for an upload. |
static String |
getUploadPath()
Gets the path of the repository into which attachments and other files are uploaded in Silverpeas. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String CONTEXT_TOKEN
Method Detail |
---|
public static String getSecurityDirPath()
@Deprecated public static String getAbsolutePath(String sSpaceId, String sComponentId)
sSpaceId
- sComponentId
-
public static String getAbsolutePath(String sComponentId)
public static String getAvatarPath()
public static String getUploadPath()
@Deprecated public static String getAbsolutePath(String spaceId, String componentId, String[] directoryName)
public static String getAbsolutePath(String componentId, String[] directoryName)
componentId
- directoryName
-
public static String getRelativePath(String... directories)
directories
- the names of sub directory. (path1, path2,...)
public static String getTemporaryPath()
public static String getDomainPropertiesPath(String domainName)
public static String getDomainAuthenticationPropertiesPath(String domainName)
public static String getTemporaryPath(String sSpaceId, String sComponentId)
public static String getComponentTemporaryPath(String sComponentId)
@Deprecated public static void createAbsolutePath(String spaceId, String componentId, String directoryName)
spaceId
- componentId
- directoryName
- public static void createAbsolutePath(String componentId, String directoryName)
@Deprecated public static void createTempPath(String spaceId, String componentId, String directoryName)
spaceId
- componentId
- directoryName
- public static void createTempPath(String sComponentId, String sDirectoryName)
public static void createGlobalTempPath(String sDirectoryName)
public static void deleteAbsolutePath(String sSpaceId, String sComponentId, String sDirectoryName)
public static void deleteTempPath(String sSpaceId, String sComponentId, String sDirectoryName)
public static String getFileIcon(boolean small, String extension)
public static String getFileIcon(String extension)
public static String getFileIcon(String extension, boolean isReadOnly)
extension
- isReadOnly
-
public static String getFileIcon(boolean small, String filename, boolean isReadOnly)
public static String getFileExtension(String fileName)
public static String formatFileSize(long lSize)
lSize
- : size
public static long getFileSize(String sourceFile)
sourceFile
-
public static String getFileDownloadTime(long size)
size
- the file's size
public static long getUploadMaximumFileSize()
public static void copyFile(String from, String to) throws IOException
from
- The name of the source file, the one to copy.to
- The name of the destination file, where to paste data.
IOException
public static String formatFileUploadTime(long size)
public static String[] getAttachmentContext(String str)
str
- : type String: the string of repertories
public static String getExportTemplateRepository()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |