Added function constructor