Added missing property declarations
Extracted the computation of the typehint to a separate method