File tree Expand file tree Collapse file tree 2 files changed +20
-0
lines changed
Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -96,12 +96,22 @@ class <#=complex.Name.ToUpperFirstChar()#>
9696 public function get<#=property.Name.ToCheckedCase()#>()
9797 {
9898 if (array_key_exists("<#=property.Name.ToCamelize()#>", $this->propDict)) {
99+ <#
100+ if (property.Type.GetTypeString() == "Json") {
101+ #>
102+ return $this->_propDict["<#=property.Name.ToCamelize()#>"];
103+ <#
104+ } else {
105+ #>
99106 if (is_a($this->propDict["<#=property.Name.ToCamelize()#>"], '<#=property.Type.GetTypeString()#>')) {
100107 return $this->propDict["<#=property.Name.ToCamelize()#>"];
101108 } else {
102109 $this->propDict["<#=property.Name.ToCamelize()#>"] = new <#=property.Type.GetTypeString()#>($this->propDict["<#=property.Name.ToCamelize()#>"]);
103110 return $this->propDict["<#=property.Name.ToCamelize()#>"];
104111 }
112+ <#
113+ }
114+ #>
105115 }
106116 return null;
107117 }
Original file line number Diff line number Diff line change @@ -75,12 +75,22 @@ class <#=entity.Name.ToCheckedCase()#>
7575 public function get<#=property.Name.ToCheckedCase()#>()
7676 {
7777 if (array_key_exists("<#=property.Name.ToCamelize()#>", $this->_propDict)) {
78+ <#
79+ if (property.Type.GetTypeString() == "Json") {
80+ #>
81+ return $this->_propDict["<#=property.Name.ToCamelize()#>"];
82+ <#
83+ } else {
84+ #>
7885 if (is_a($this->_propDict["<#=property.Name.ToCamelize()#>"], '<#=property.Type.GetTypeString()#>')) {
7986 return $this->_propDict["<#=property.Name.ToCamelize()#>"];
8087 } else {
8188 $this->_propDict["<#=property.Name.ToCamelize()#>"] = new <#=property.Type.GetTypeString()#>($this->_propDict["<#=property.Name.ToCamelize()#>"]);
8289 return $this->_propDict["<#=property.Name.ToCamelize()#>"];
8390 }
91+ <#
92+ }
93+ #>
8494 }
8595 return null;
8696 }
You can’t perform that action at this time.
0 commit comments