Add checkNotNull statements in constructor