public class VFSUtils
extends org.apache.axis2.transport.base.BaseUtils
Constructor and Description |
---|
VFSUtils() |
Modifier and Type | Method and Description |
---|---|
static boolean |
acquireLock(org.apache.commons.vfs2.FileSystemManager fsManager,
org.apache.commons.vfs2.FileObject fo)
Acquires a file item lock before processing the item, guaranteeing that the file is not
processed while it is being uploaded and/or the item is not processed by two listeners
|
static String |
generateTempFileName()
Generate a unique file name to be used as a temp file
|
static String |
getFileName(org.apache.axis2.context.MessageContext msgCtx,
VFSOutTransportInfo vfsOutInfo) |
static String |
getProperty(org.apache.commons.vfs2.FileContent message,
String property)
Get a String property from FileContent message
|
static String |
getSystemTime(String dateFormat) |
static String |
maskURLPassword(String url)
Mask the password of the connection url with ***
|
static void |
releaseLock(org.apache.commons.vfs2.FileSystemManager fsManager,
org.apache.commons.vfs2.FileObject fo)
Release a file item lock acquired either by the VFS listener or a sender
|
public static String getProperty(org.apache.commons.vfs2.FileContent message, String property)
message
- the File messageproperty
- property namepublic static String getFileName(org.apache.axis2.context.MessageContext msgCtx, VFSOutTransportInfo vfsOutInfo)
public static boolean acquireLock(org.apache.commons.vfs2.FileSystemManager fsManager, org.apache.commons.vfs2.FileObject fo)
fsManager
- used to resolve the processing filefo
- representing the processing file itempublic static void releaseLock(org.apache.commons.vfs2.FileSystemManager fsManager, org.apache.commons.vfs2.FileObject fo)
fsManager
- which is used to resolve the processed filefo
- representing the processed filepublic static String maskURLPassword(String url)
url
- the actual urlpublic static String generateTempFileName()
Copyright © 2005-2017 Apache Software Foundation. All Rights Reserved.