Skip to content

Commit 76abbe3

Browse files
author
linzhijun
committed
修改 版本号
1 parent 05478a7 commit 76abbe3

File tree

8 files changed

+4611
-6569
lines changed

8 files changed

+4611
-6569
lines changed

csharp/ToolGood.Algorithm2.Test/AlgorithmEngine/AlgorithmEngineTest_dateTime.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,14 @@ public void DATEVALUE_Test()
3535
// chinese time
3636
dt = engine.TryEvaluate("DATEVALUE('1691234899',0)", DateTime.Now);
3737
Assert.AreEqual(dt, new DateTime(2023, 8, 5, 19, 28, 19));
38+
39+
// chinese time
40+
dt = engine.TryEvaluate("DATEVALUE('1691234899000')", DateTime.Now);
41+
Assert.AreEqual(dt, new DateTime(2023, 8, 5, 19, 28, 19));
42+
43+
// chinese time
44+
dt = engine.TryEvaluate("DATEVALUE('1691234899')", DateTime.Now);
45+
Assert.AreEqual(dt, new DateTime(2023, 8, 5, 19, 28, 19));
3846
}
3947
[Test]
4048
public void TIMESTAMP_Test()

csharp/ToolGood.Algorithm2/ToolGood.Algorithm2.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<Product>ToolGood.Algorithm</Product>
2121
<PackageLicenseFile>LICENSE</PackageLicenseFile>
2222
<SignAssembly>true</SignAssembly>
23-
<Version>3.4.0.5</Version>
23+
<Version>3.4.1</Version>
2424
<AssemblyOriginatorKeyFile>ToolGood.Algorithm.snk</AssemblyOriginatorKeyFile>
2525
<DelaySign>false</DelaySign>
2626
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\ToolGood.Algorithm.xml</DocumentationFile>

csharp/ToolGood.Algorithm2/math/mathLexer.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
using DFA = Antlr4.Runtime.Dfa.DFA;
2929

3030
[System.CodeDom.Compiler.GeneratedCode("ANTLR", "4.13.0")]
31-
[System.CLSCompliant(false)]
3231
partial class mathLexer : Lexer {
3332
protected static DFA[] decisionToDFA;
3433
protected static PredictionContextCache sharedContextCache = new PredictionContextCache();

csharp/ToolGood.Algorithm2/math/mathParser.cs

Lines changed: 3002 additions & 4975 deletions
Large diffs are not rendered by default.

csharp/ToolGood.Algorithm2/math/mathVisitor.cs

Lines changed: 1589 additions & 1589 deletions
Large diffs are not rendered by default.

java/toolgood.algorithm/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
<groupId>io.github.toolgood</groupId>
88
<artifactId>toolgood-algorithm</artifactId>
9-
<version>3.4.0.5</version>
9+
<version>3.4.1.0</version>
1010
<packaging>jar</packaging>
1111

1212
<name>toolgood.algorithm</name>

java/toolgood.algorithm/src/test/java/toolgood/algorithm/Tests/AlgorithmEngineTest_dateTime.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,14 @@ public void DATEVALUE_Test()
3636
// chinese time
3737
dt = engine.TryEvaluate("DATEVALUE('1691234899',0)", DateTime.now());
3838
assertEquals(dt, new DateTime(2023, 8, 5, 19, 28, 19,DateTimeZone.getDefault()));
39+
40+
// chinese time
41+
dt = engine.TryEvaluate("DATEVALUE('1691234899000')", DateTime.now());
42+
assertEquals(dt, new DateTime(2023, 8, 5, 19, 28, 19,DateTimeZone.getDefault()));
43+
44+
// chinese time
45+
dt = engine.TryEvaluate("DATEVALUE('1691234899')", DateTime.now());
46+
assertEquals(dt, new DateTime(2023, 8, 5, 19, 28, 19,DateTimeZone.getDefault()));
3947
}
4048

4149
@Test

tools/Antlr4Helper.CSharpHelper/Program.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ static void Main(string[] args)
4848
ENDSWITH=228, ISNULLOREMPTY=229, ISNULLORWHITESPACE=230, REMOVESTART=231,
4949
REMOVEEND=232, JSON=233, VLOOKUP=234, LOOKUP=235, ARRAY=236, ADDYEARS=237,
5050
ADDMONTHS=238, ADDDAYS=239, ADDHOURS=240, ADDMINUTES=241, ADDSECONDS=242,
51-
PARAMETER=243, PARAMETER2=244, WS=245, COMMENT=246, LINE_COMMENT=247;
51+
TIMESTAMP=243, PARAMETER=244, PARAMETER2=245, WS=246, COMMENT=247, LINE_COMMENT=248;
5252
5353
RULE_prog=0, RULE_expr=1, RULE_parameter2=2;
5454
";
@@ -59,7 +59,7 @@ static void Main(string[] args)
5959
dict[sp[0].Trim()] = sp[1].Trim();
6060
}
6161

62-
var filePath = Path.GetFullPath(@"..\..\..\..\..\..\g4\bin\mathParser.cs");
62+
var filePath = Path.GetFullPath(@"..\..\..\..\..\g4\bin\mathParser.cs");
6363
//var filePath = Path.GetFullPath(@"..\..\..\..\..\..\csharp\ToolGood.Algorithm2\math\mathParser.cs");
6464
var csText = File.ReadAllText(filePath);
6565

0 commit comments

Comments
 (0)