add mixin function; takes a function and add the function to specified object