Refactor getter/setter to support compile.
issue #4277 : To support compile.
Merge.
Merge pull request #1654 from SmallAiTT/iss_4277_fix4release3.0

issue #4277 : To support compile.