Does virus scanner app work with E2EE enabled?

Is the antivirus scanner set up to scan files on disc or in memory prior to being on disk? I assume that If the antivirus scanner is designed to scan on disk, that antivirus app functionally does nothing if end-to-end encryption is enabled.