Added generality of types using typedefs