wrote bitwriter file constructor