refactor platform collector to share methods