diff --git a/Directory.Packages.props b/Directory.Packages.props index 3639c677..44071838 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -15,7 +15,7 @@ - + diff --git a/src/AXSharp.compiler/src/AXSharp.Cs.Compiler/Onliner/CsOnlinerSourceBuilder.cs b/src/AXSharp.compiler/src/AXSharp.Cs.Compiler/Onliner/CsOnlinerSourceBuilder.cs index 9212fd03..61ca236f 100644 --- a/src/AXSharp.compiler/src/AXSharp.Cs.Compiler/Onliner/CsOnlinerSourceBuilder.cs +++ b/src/AXSharp.compiler/src/AXSharp.Cs.Compiler/Onliner/CsOnlinerSourceBuilder.cs @@ -435,7 +435,7 @@ private void CreateITwinObjectImplementation() "public string Symbol { get; protected set; }" + "private string _attributeName;" + "public System.String AttributeName { get => string.IsNullOrEmpty(_attributeName) ? SymbolTail : _attributeName.Interpolate(this).CleanUpLocalizationTokens(); set => _attributeName = value; }" + - "public System.String GetAttributeName(System.Globalization.CultureInfo culture) { return this.Translate(_attributeName, culture).Interpolate(this); }" + + "public System.String GetAttributeName(System.Globalization.CultureInfo culture) { if (string.IsNullOrEmpty(_attributeName)) { return SymbolTail; } return this.Translate(_attributeName, culture).Interpolate(this); }" + "private string _humanReadable;" + "public string HumanReadable { get => string.IsNullOrEmpty(_humanReadable) ? SymbolTail : _humanReadable.Interpolate(this).CleanUpLocalizationTokens(); set => _humanReadable = value; }" + "public System.String GetHumanReadable(System.Globalization.CultureInfo culture) { return this.Translate(_humanReadable, culture); }" + diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Cs/CsSourceBuilderTests.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Cs/CsSourceBuilderTests.cs index 9d2c214f..240cb14e 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Cs/CsSourceBuilderTests.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Cs/CsSourceBuilderTests.cs @@ -327,7 +327,8 @@ private void CompareOutputs(string memberName) var actualFileContentLines = actualFileContent.Split("\n").Select(a => a.Trim()).ToArray(); var expectedFileContentLines = expectedFileContent.Split("\n").Select(a => a.Trim()).ToArray(); - + output.WriteLine($"Actual output file: {actualSourceFile}"); + output.WriteLine($"Expected output file: {expectedSourceFile}"); for (int i = 0; i < expectedFileContentLines.Length; i++) { Assert.Equal(expectedFileContentLines[i], actualFileContentLines[i]); diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Integration.Cs/IxProjectTests.IntegrationCs.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Integration.Cs/IxProjectTests.IntegrationCs.cs index 46a8d493..d82fa75b 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Integration.Cs/IxProjectTests.IntegrationCs.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/Integration.Cs/IxProjectTests.IntegrationCs.cs @@ -173,6 +173,12 @@ public void should_match_expected_and_generated_whole_project() } catch (Exception) { + + output.WriteLine("--------------------------------------------------"); + output.WriteLine($"Actual file: {actualList[currentIndex]}"); + output.WriteLine($"Expected file: {exp}"); + output.WriteLine("--------------------------------------------------"); + output.WriteLine($"-- Case: {new FileInfo(exp).Name} vs {new FileInfo(actualList[currentIndex]).Name}"); output.WriteLine($"-- expected\n{expectedFileContent}"); output.WriteLine($"-- actual\n{actualFileContent}"); @@ -216,10 +222,15 @@ public void should_generate_all_even_when_fails_somewhere() var actualFileContent = File.ReadAllText(actualList[currentIndex]); try { + Assert.Equal(expectedFileContent, actualFileContent); } catch (Exception) { + output.WriteLine("--------------------------------------------------"); + output.WriteLine($"Actual file: {actualList[currentIndex]}"); + output.WriteLine($"Expected file: {exp}"); + output.WriteLine("--------------------------------------------------"); output.WriteLine($"-- Case: {new FileInfo(exp).Name} vs {new FileInfo(actualList[currentIndex]).Name}"); output.WriteLine($"-- expected\n{expectedFileContent}"); output.WriteLine($"-- actual\n{actualFileContent}"); diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/abstract_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/abstract_members.g.cs index 0cca8db0..0e57b992 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/abstract_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/abstract_members.g.cs @@ -216,6 +216,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/array_declaration.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/array_declaration.g.cs index 07d65c64..49415da1 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/array_declaration.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/array_declaration.g.cs @@ -240,6 +240,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -434,6 +439,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_all_primitives.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_all_primitives.g.cs index 2bbfc818..36c26531 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_all_primitives.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_all_primitives.g.cs @@ -536,6 +536,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extended_by_known_type.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extended_by_known_type.g.cs index ae421d05..41bd6829 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extended_by_known_type.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extended_by_known_type.g.cs @@ -350,6 +350,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends.g.cs index 1e6c8e99..ae98b0e0 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends.g.cs @@ -312,6 +312,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends_and_implements.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends_and_implements.g.cs index 368ec06c..2f519df4 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends_and_implements.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_extends_and_implements.g.cs @@ -312,6 +312,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_generic_extension.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_generic_extension.g.cs index 075728fd..6f1bf375 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_generic_extension.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_generic_extension.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -705,6 +710,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements.g.cs index 83ff8171..ee0cb2ce 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements_multiple.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements_multiple.g.cs index c26cd6c1..95d287ca 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements_multiple.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_implements_multiple.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_internal.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_internal.g.cs index 2152c32a..4125361e 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_internal.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_internal.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_no_access_modifier.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_no_access_modifier.g.cs index 15ae3809..2d2272b1 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_no_access_modifier.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_no_access_modifier.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_complex_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_complex_members.g.cs index 61be20d4..d423ae31 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_complex_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_complex_members.g.cs @@ -208,6 +208,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -402,6 +407,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_non_public_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_non_public_members.g.cs index f17ad6f3..aced06ee 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_non_public_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_non_public_members.g.cs @@ -208,6 +208,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -402,6 +407,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_pragmas.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_pragmas.g.cs index 77a23dba..383d092d 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_pragmas.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_pragmas.g.cs @@ -210,6 +210,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -404,6 +409,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_primitive_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_primitive_members.g.cs index 411b70b5..279c7fb4 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_primitive_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_primitive_members.g.cs @@ -618,6 +618,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_using_directives.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_using_directives.g.cs index 0565f1a3..41fa3c4c 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_using_directives.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/class_with_using_directives.g.cs @@ -186,6 +186,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/compileromitsattribute.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/compileromitsattribute.g.cs index 2eec0b17..b302f337 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/compileromitsattribute.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/compileromitsattribute.g.cs @@ -213,6 +213,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -440,6 +445,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -673,6 +683,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -929,6 +944,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1140,6 +1160,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1349,6 +1374,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1580,6 +1610,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1832,6 +1867,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -2059,6 +2099,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/configuration.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/configuration.g.cs index 5430b4c0..bf55ab8e 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/configuration.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/configuration.g.cs @@ -638,6 +638,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -861,6 +866,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1092,6 +1102,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/file_with_usings.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/file_with_usings.g.cs index f14a7ebc..56f39f28 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/file_with_usings.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/file_with_usings.g.cs @@ -188,6 +188,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -385,6 +390,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -584,6 +594,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -782,6 +797,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/generics.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/generics.g.cs index c127640e..2e4106be 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/generics.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/generics.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -412,6 +417,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonce.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonce.g.cs index 56cb820b..54dfa84f 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonce.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonce.g.cs @@ -267,6 +267,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -494,6 +499,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonly.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonly.g.cs index 82c4ef16..f33dd211 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonly.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/makereadonly.g.cs @@ -267,6 +267,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -494,6 +499,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/misc.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/misc.g.cs index bd85dc56..0ad24a32 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/misc.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/misc.g.cs @@ -221,6 +221,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -477,6 +482,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -688,6 +698,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -897,6 +912,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1128,6 +1148,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1380,6 +1405,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1607,6 +1637,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/mixed_access.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/mixed_access.g.cs index 7e4e5853..07e927da 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/mixed_access.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/mixed_access.g.cs @@ -200,6 +200,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -415,6 +420,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -630,6 +640,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -845,6 +860,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1054,6 +1074,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1281,6 +1306,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/multiline_pragmas.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/multiline_pragmas.g.cs index 13baad6a..73d9d290 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/multiline_pragmas.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/multiline_pragmas.g.cs @@ -213,6 +213,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/ref_to_simple.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/ref_to_simple.g.cs index bda9940b..44712577 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/ref_to_simple.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/ref_to_simple.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -396,6 +401,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class.g.cs index d3ae6727..9c0e8c99 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class_within_namespace.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class_within_namespace.g.cs index e31295aa..35d2fc8b 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class_within_namespace.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/simple_empty_class_within_namespace.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/struct_simple.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/struct_simple.g.cs index 20c5d929..f316e620 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/struct_simple.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/struct_simple.g.cs @@ -198,6 +198,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -429,6 +434,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values.g.cs index 3b2559c1..13a8bca3 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values.g.cs @@ -210,6 +210,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values_literals.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values_literals.g.cs index 2d73add6..343ca703 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values_literals.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_named_values_literals.g.cs @@ -212,6 +212,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_with_enum.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_with_enum.g.cs index 16446adc..21d4caed 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_with_enum.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/type_with_enum.g.cs @@ -237,6 +237,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_name_attributes.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_name_attributes.g.cs index b7b81a79..687e6895 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_name_attributes.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_name_attributes.g.cs @@ -201,6 +201,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -432,6 +437,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -659,6 +669,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_property_attributes.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_property_attributes.g.cs index d38a8408..c9c7212d 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_property_attributes.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/.g/Onliners/types_with_property_attributes.g.cs @@ -220,6 +220,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/units.csproj b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/units.csproj index a02121aa..2cb3c2ea 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/units.csproj +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/ax/units.csproj @@ -6,8 +6,8 @@ - - + + diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/abstract_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/abstract_members.g.cs index 0cca8db0..0e57b992 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/abstract_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/abstract_members.g.cs @@ -216,6 +216,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/array_declaration.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/array_declaration.g.cs index 07d65c64..49415da1 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/array_declaration.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/array_declaration.g.cs @@ -240,6 +240,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -434,6 +439,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_all_primitives.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_all_primitives.g.cs index 2bbfc818..36c26531 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_all_primitives.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_all_primitives.g.cs @@ -536,6 +536,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extended_by_known_type.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extended_by_known_type.g.cs index ae421d05..41bd6829 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extended_by_known_type.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extended_by_known_type.g.cs @@ -350,6 +350,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends.g.cs index 1e6c8e99..ae98b0e0 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends.g.cs @@ -312,6 +312,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends_and_implements.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends_and_implements.g.cs index 368ec06c..2f519df4 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends_and_implements.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_extends_and_implements.g.cs @@ -312,6 +312,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_generic_extension.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_generic_extension.g.cs index 075728fd..6f1bf375 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_generic_extension.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_generic_extension.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -705,6 +710,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements.g.cs index 83ff8171..ee0cb2ce 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements_multiple.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements_multiple.g.cs index c26cd6c1..95d287ca 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements_multiple.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_implements_multiple.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_internal.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_internal.g.cs index 2152c32a..4125361e 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_internal.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_internal.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_no_access_modifier.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_no_access_modifier.g.cs index 15ae3809..2d2272b1 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_no_access_modifier.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_no_access_modifier.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_complex_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_complex_members.g.cs index 61be20d4..d423ae31 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_complex_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_complex_members.g.cs @@ -208,6 +208,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -402,6 +407,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_non_public_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_non_public_members.g.cs index f17ad6f3..aced06ee 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_non_public_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_non_public_members.g.cs @@ -208,6 +208,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -402,6 +407,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_pragmas.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_pragmas.g.cs index 77a23dba..383d092d 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_pragmas.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_pragmas.g.cs @@ -210,6 +210,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -404,6 +409,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_primitive_members.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_primitive_members.g.cs index 411b70b5..279c7fb4 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_primitive_members.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_primitive_members.g.cs @@ -618,6 +618,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_using_directives.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_using_directives.g.cs index 0565f1a3..41fa3c4c 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_using_directives.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/class_with_using_directives.g.cs @@ -186,6 +186,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/compileromitsattribute.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/compileromitsattribute.g.cs index 2eec0b17..b302f337 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/compileromitsattribute.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/compileromitsattribute.g.cs @@ -213,6 +213,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -440,6 +445,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -673,6 +683,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -929,6 +944,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1140,6 +1160,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1349,6 +1374,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1580,6 +1610,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1832,6 +1867,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -2059,6 +2099,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/configuration.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/configuration.g.cs index 5430b4c0..bf55ab8e 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/configuration.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/configuration.g.cs @@ -638,6 +638,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -861,6 +866,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1092,6 +1102,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/file_with_usings.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/file_with_usings.g.cs index f14a7ebc..56f39f28 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/file_with_usings.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/file_with_usings.g.cs @@ -188,6 +188,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -385,6 +390,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -584,6 +594,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -782,6 +797,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/generics.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/generics.g.cs index c127640e..2e4106be 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/generics.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/generics.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -412,6 +417,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonce.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonce.g.cs index 56cb820b..54dfa84f 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonce.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonce.g.cs @@ -267,6 +267,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -494,6 +499,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonly.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonly.g.cs index 82c4ef16..f33dd211 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonly.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/makereadonly.g.cs @@ -267,6 +267,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -494,6 +499,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/misc.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/misc.g.cs index bd85dc56..0ad24a32 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/misc.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/misc.g.cs @@ -221,6 +221,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -477,6 +482,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -688,6 +698,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -897,6 +912,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1128,6 +1148,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1380,6 +1405,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1607,6 +1637,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/mixed_access.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/mixed_access.g.cs index 7e4e5853..07e927da 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/mixed_access.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/mixed_access.g.cs @@ -200,6 +200,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -415,6 +420,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -630,6 +640,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -845,6 +860,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1054,6 +1074,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -1281,6 +1306,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/multiline_pragmas.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/multiline_pragmas.g.cs index 13baad6a..73d9d290 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/multiline_pragmas.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/multiline_pragmas.g.cs @@ -213,6 +213,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/ref_to_simple.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/ref_to_simple.g.cs index bda9940b..44712577 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/ref_to_simple.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/ref_to_simple.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -396,6 +401,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class.g.cs index d3ae6727..9c0e8c99 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class.g.cs @@ -183,6 +183,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class_within_namespace.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class_within_namespace.g.cs index e31295aa..35d2fc8b 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class_within_namespace.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/simple_empty_class_within_namespace.g.cs @@ -185,6 +185,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/struct_simple.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/struct_simple.g.cs index 20c5d929..f316e620 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/struct_simple.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/struct_simple.g.cs @@ -198,6 +198,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -429,6 +434,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values.g.cs index 3b2559c1..13a8bca3 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values.g.cs @@ -210,6 +210,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values_literals.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values_literals.g.cs index 2d73add6..343ca703 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values_literals.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_named_values_literals.g.cs @@ -212,6 +212,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_with_enum.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_with_enum.g.cs index 16446adc..21d4caed 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_with_enum.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/type_with_enum.g.cs @@ -237,6 +237,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_name_attributes.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_name_attributes.g.cs index b7b81a79..687e6895 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_name_attributes.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_name_attributes.g.cs @@ -201,6 +201,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -432,6 +437,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } @@ -659,6 +669,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_property_attributes.g.cs b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_property_attributes.g.cs index d38a8408..c9c7212d 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_property_attributes.g.cs +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/.g/Onliners/types_with_property_attributes.g.cs @@ -220,6 +220,11 @@ public AXSharp.Connector.ITwinObject GetParent() public System.String GetAttributeName(System.Globalization.CultureInfo culture) { + if (string.IsNullOrEmpty(_attributeName)) + { + return SymbolTail; + } + return this.Translate(_attributeName, culture).Interpolate(this); } diff --git a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/units.csproj b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/units.csproj index a02121aa..2cb3c2ea 100644 --- a/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/units.csproj +++ b/src/AXSharp.compiler/tests/AXSharp.Compiler.CsTests/samples/units/expected/tia/units.csproj @@ -6,8 +6,8 @@ - - + +