FileImporter
class FileImporter (View source)
A class to be used to import files into the application file manager.
Properties
| protected Application | $app | The container instance to be used to build dependencies.  | 
                |
| private ProcessorManager | $processorManager | ||
| private Application | $applicationFileService | ||
| private Incoming | $incoming | 
Methods
Initialize the instance.
Get the processor list manager.
Import a local file into the application file manager.
Import a file from the incoming directory into the application file manager.
Import a file received via a POST request into the application file manager.
Generate a file prefix.
Import a file into the application file manager.
Apply the validators to the file being imported.
Apply the pre-processors to the file being imported.
Actually import a file into the application file manager.
Apply the post-processors to the imported file.
Get the local path of an incoming file (if the incoming file system is not local, we'll create a copy of it in a volatile directory).
Details
        
                            
    __construct(Application $app, ProcessorManager $processorManager, Application $applicationFileService, Incoming $incoming)
        
    
    Initialize the instance.
        
                            ProcessorManager
    getProcessorManager()
        
    
    Get the processor list manager.
        
                            Version
    importLocalFile(string $localFilename, string $concreteFilename = '', ImportOptions $options = null)
        
    
    Import a local file into the application file manager.
        
                            Version
    importFromIncoming(string $incomingFilename, string $concreteFilename = '', ImportOptions $options = null)
        
    
    Import a file from the incoming directory into the application file manager.
        
                            Version
    importUploadedFile(UploadedFile $uploadedFile = null, string $concreteFilename = '', ImportOptions $options = null)
        
    
    Import a file received via a POST request into the application file manager.
        
                            string
    generatePrefix()
        
    
    Generate a file prefix.
        
                    protected        Version
    import(ImportingFile $importingFile, ImportOptions $options)
        
    
    Import a file into the application file manager.
        
                    protected        
    applyValidators(ImportingFile $importingFile, ImportOptions $options)
        
    
    Apply the validators to the file being imported.
        
                    protected        
    applyPreProcessors(ImportingFile $importingFile, ImportOptions $options)
        
    
    Apply the pre-processors to the file being imported.
        
                    protected        Version
    save(ImportingFile $importingFile, ImportOptions $options)
        
    
    Actually import a file into the application file manager.
        
                    protected        
    applyPostProcessors(ImportingFile $importingFile, ImportOptions $options, Version $fileVersion)
        
    
    Apply the post-processors to the imported file.
        
                    protected        string
    resolveIncomingFilename(string $incomingFilename, bool $copiedLocally, VolatileDirectory $volatileDirectory = null)
        
    
    Get the local path of an incoming file (if the incoming file system is not local, we'll create a copy of it in a volatile directory).