Added constructors and some basic functions