added Tree prototype with swig support