You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by jb...@apache.org on 2017/04/12 19:14:57 UTC
[02/12] lucene-solr:master: SOLR-10303: Switched to pascal casing
SOLR-10303: Switched to pascal casing
Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/b314bc67
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/b314bc67
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/b314bc67
Branch: refs/heads/master
Commit: b314bc67764131bb677f25d98212577182af0b1e
Parents: c6fbb27
Author: Gethin James <ge...@alfresco.com>
Authored: Mon Mar 20 17:08:15 2017 +0100
Committer: Joel Bernstein <jb...@apache.org>
Committed: Wed Apr 12 15:00:06 2017 -0400
----------------------------------------------------------------------
.../apache/solr/client/solrj/io/eval/DatePartEvaluator.java | 6 +++---
.../client/solrj/io/stream/eval/DatePartEvaluatorTest.java | 8 ++++----
2 files changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/b314bc67/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/DatePartEvaluator.java
----------------------------------------------------------------------
diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/DatePartEvaluator.java b/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/DatePartEvaluator.java
index c3c5a61..592d4af 100644
--- a/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/DatePartEvaluator.java
+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/DatePartEvaluator.java
@@ -41,7 +41,7 @@ import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;
*/
public class DatePartEvaluator extends NumberEvaluator {
- public enum FUNCTION {year, month, day, dayofyear, dayofquarter, hour, minute, quarter, week, second, epoch}
+ public enum FUNCTION {year, month, day, dayOfYear, dayOfQuarter, hour, minute, quarter, week, second, epoch}
private final FUNCTION function;
@@ -122,7 +122,7 @@ public class DatePartEvaluator extends NumberEvaluator {
return date.get(ChronoField.MONTH_OF_YEAR);
case day:
return date.get(ChronoField.DAY_OF_MONTH);
- case dayofyear:
+ case dayOfYear:
return date.get(ChronoField.DAY_OF_YEAR);
case hour:
return date.get(ChronoField.HOUR_OF_DAY);
@@ -130,7 +130,7 @@ public class DatePartEvaluator extends NumberEvaluator {
return date.get(ChronoField.MINUTE_OF_HOUR);
case second:
return date.get(ChronoField.SECOND_OF_MINUTE);
- case dayofquarter:
+ case dayOfQuarter:
return date.get(IsoFields.DAY_OF_QUARTER);
case quarter:
return date.get(IsoFields.QUARTER_OF_YEAR);
http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/b314bc67/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DatePartEvaluatorTest.java
----------------------------------------------------------------------
diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DatePartEvaluatorTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DatePartEvaluatorTest.java
index 2e5c4b0..8b3317e 100644
--- a/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DatePartEvaluatorTest.java
+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/io/stream/eval/DatePartEvaluatorTest.java
@@ -145,8 +145,8 @@ public class DatePartEvaluatorTest {
testFunction("year(a)", "1995-12-31T23:59:59Z", 1995);
testFunction("month(a)","1995-12-31T23:59:59Z", 12);
testFunction("day(a)", "1995-12-31T23:59:59Z", 31);
- testFunction("dayofyear(a)", "1995-12-31T23:59:59Z", 365);
- testFunction("dayofquarter(a)", "1995-12-31T23:59:59Z", 92);
+ testFunction("dayOfYear(a)", "1995-12-31T23:59:59Z", 365);
+ testFunction("dayOfQuarter(a)", "1995-12-31T23:59:59Z", 92);
testFunction("hour(a)", "1995-12-31T23:59:59Z", 23);
testFunction("minute(a)", "1995-12-31T23:59:59Z", 59);
testFunction("quarter(a)","1995-12-31T23:59:59Z", 4);
@@ -159,8 +159,8 @@ public class DatePartEvaluatorTest {
testFunction("month(a)","2017-03-17T10:30:45Z", 3);
testFunction("day(a)", "2017-03-17T10:30:45Z", 17);
testFunction("day('a')", "2017-03-17T10:30:45Z", 17);
- testFunction("dayofyear(a)", "2017-03-17T10:30:45Z", 76);
- testFunction("dayofquarter(a)", "2017-03-17T10:30:45Z", 76);
+ testFunction("dayOfYear(a)", "2017-03-17T10:30:45Z", 76);
+ testFunction("dayOfQuarter(a)", "2017-03-17T10:30:45Z", 76);
testFunction("hour(a)", "2017-03-17T10:30:45Z", 10);
testFunction("minute(a)", "2017-03-17T10:30:45Z", 30);
testFunction("quarter(a)","2017-03-17T10:30:45Z", 1);