started to do isostream and some little changes
corrected handle types