public class DeviceFileHelper extends Object
Constructor and Description |
---|
DeviceFileHelper() |
Modifier and Type | Method and Description |
---|---|
static List<DeviceFile> |
downloadAllDeviceFiles(AccessDevice device,
ErrorableProcess errorableProcess)
Method to download all
DeviceFile s for a provided AccessDevice. |
static List<DeviceFile> |
downloadFTPFiles(AccessDevice device,
ErrorableProcess errorableProcess)
Helper Method to download device files that are stored on an FTP server.
|
static List<DeviceFile> |
downloadHTTPFiles(AccessDevice device,
ErrorableProcess errorableProcess)
Helper Method to download device files that are stored on an HTTP/HTTPS server.
|
static String |
getRepositoryURL(AccessDevice accessDevice,
String deviceType,
String macAddress,
String fileFormat,
String method)
Deprecated.
|
static void |
rebuildAccessDeviceConfigurationFiles(AccessDevice accessDevice)
Utility Method to rebuild an AccessDevice configuration files.
|
public static List<DeviceFile> downloadAllDeviceFiles(AccessDevice device, ErrorableProcess errorableProcess)
DeviceFile
s for a provided AccessDevice. This retrieves both DMS and FTP based files.device
- The AccessDevice to retrieve Device FileserrorableProcess
- An optional process to insert errors and warnings. Can be null.public static List<DeviceFile> downloadHTTPFiles(AccessDevice device, ErrorableProcess errorableProcess) throws HelperException
device
- The source AccessDeviceerrorableProcess
- An optional process to insert errors and warnings. Can be null.HelperException
- Thrown if an error occurs while attempting to download the files.public static List<DeviceFile> downloadFTPFiles(AccessDevice device, ErrorableProcess errorableProcess) throws HelperException, FTPNotSupportedException
device
- The access device that owns the files that are being retrieved.errorableProcess
- An optional process to insert errors and warnings. Can be null.HelperException
- Thrown if there is an error while retrieving device files.FTPNotSupportedException
- Thrown if there is no FTP server for the provided AccessDevice.public static void rebuildAccessDeviceConfigurationFiles(AccessDevice accessDevice) throws HelperException
accessDevice
- The access device to rebuildHelperException
- Thrown if an error occurs while rebuilding AccessDevice configuration files.@Deprecated public static String getRepositoryURL(AccessDevice accessDevice, String deviceType, String macAddress, String fileFormat, String method) throws HelperException, MalformedURLException
accessDevice
- The access device to retrieve the URL fordeviceType
- The device type of the access devicemacAddress
- The MAC address of the access devicefileFormat
- The file format to retrievemethod
- GET or PUTHelperException
- Thrown if an error occurs during retrieval.MalformedURLException
Copyright © 2017 ECG. All rights reserved.