Added optional $time parameter to 'replaceDatePlaceholder'
Added 'Collector' class and unit tests