Buggfixes and wrapper classes