added implemenation with boost::any
added move semantic