changed data class to use std::string as buffer