added Buffer and Chan classes