added reflection to read properties