moved swig stuff to .i for moiety converter, minor cleanup