mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-03-09 14:34:43 +00:00
Merge branch 'master' into each
This commit is contained in:
commit
d1f4e2ef04
buildSrc/src/main/resources
core/src
main/java/org/elasticsearch
action/support/nodes
bootstrap
common/logging
indices
monitor/os
test/java/org/elasticsearch
action/support/nodes
index
indices
search
distribution
docs/reference/setup
modules
lang-mustache/src/test/java/org/elasticsearch/messy/tests
lang-painless/src/main
java/org/elasticsearch/painless
resources/org/elasticsearch/painless
qa/evil-tests/src/test/java/org/elasticsearch/plugins
@ -1197,7 +1197,6 @@
|
||||
<suppress files="modules[/\\]lang-groovy[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]script[/\\]groovy[/\\]GroovySecurityTests.java" checks="LineLength" />
|
||||
<suppress files="modules[/\\]lang-mustache[/\\]src[/\\]main[/\\]java[/\\]org[/\\]elasticsearch[/\\]script[/\\]mustache[/\\]MustachePlugin.java" checks="LineLength" />
|
||||
<suppress files="modules[/\\]lang-mustache[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]messy[/\\]tests[/\\]RenderSearchTemplateTests.java" checks="LineLength" />
|
||||
<suppress files="modules[/\\]lang-mustache[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]messy[/\\]tests[/\\]SuggestSearchTests.java" checks="LineLength" />
|
||||
<suppress files="modules[/\\]lang-mustache[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]messy[/\\]tests[/\\]TemplateQueryParserTests.java" checks="LineLength" />
|
||||
<suppress files="modules[/\\]lang-mustache[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]messy[/\\]tests[/\\]TemplateQueryTests.java" checks="LineLength" />
|
||||
<suppress files="modules[/\\]lang-mustache[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]messy[/\\]tests[/\\]package-info.java" checks="LineLength" />
|
||||
|
@ -21,5 +21,7 @@ com.carrotsearch.randomizedtesting.annotations.Repeat @ Don't commit hardcoded r
|
||||
org.apache.lucene.codecs.Codec#setDefault(org.apache.lucene.codecs.Codec) @ Use the SuppressCodecs("*") annotation instead
|
||||
org.apache.lucene.util.LuceneTestCase$Slow @ Don't write slow tests
|
||||
org.junit.Ignore @ Use AwaitsFix instead
|
||||
org.apache.lucene.util.LuceneTestCase$Nightly @ We don't run nightly tests at this point!
|
||||
com.carrotsearch.randomizedtesting.annotations.Nightly @ We don't run nightly tests at this point!
|
||||
|
||||
org.junit.Test @defaultMessage Just name your test method testFooBar
|
||||
|
@ -176,12 +176,10 @@ public abstract class TransportNodesAction<NodesRequest extends BaseNodesRequest
|
||||
this.request = request;
|
||||
this.listener = listener;
|
||||
ClusterState clusterState = clusterService.state();
|
||||
String[] nodesIds = resolveNodes(request, clusterState);
|
||||
this.nodesIds = filterNodeIds(clusterState.nodes(), nodesIds);
|
||||
ImmutableOpenMap<String, DiscoveryNode> nodes = clusterState.nodes().getNodes();
|
||||
nodesIds = filterNodeIds(clusterState.nodes(), resolveNodes(request, clusterState));
|
||||
this.nodes = new DiscoveryNode[nodesIds.length];
|
||||
for (int i = 0; i < nodesIds.length; i++) {
|
||||
this.nodes[i] = nodes.get(nodesIds[i]);
|
||||
this.nodes[i] = clusterState.nodes().get(nodesIds[i]);
|
||||
}
|
||||
this.responses = new AtomicReferenceArray<>(this.nodesIds.length);
|
||||
}
|
||||
|
@ -20,7 +20,7 @@
|
||||
package org.elasticsearch.bootstrap;
|
||||
|
||||
import org.apache.lucene.util.Constants;
|
||||
import org.apache.lucene.util.SuppressForbidden;
|
||||
import org.elasticsearch.common.SuppressForbidden;
|
||||
import org.elasticsearch.common.io.PathUtils;
|
||||
import org.elasticsearch.common.logging.ESLogger;
|
||||
import org.elasticsearch.common.logging.Loggers;
|
||||
|
@ -19,8 +19,8 @@
|
||||
|
||||
package org.elasticsearch.common.logging;
|
||||
|
||||
import org.apache.lucene.util.SuppressForbidden;
|
||||
import org.elasticsearch.common.Classes;
|
||||
import org.elasticsearch.common.SuppressForbidden;
|
||||
import org.elasticsearch.common.settings.Settings;
|
||||
import org.elasticsearch.index.Index;
|
||||
import org.elasticsearch.index.shard.ShardId;
|
||||
|
@ -133,7 +133,6 @@ public class IndicesService extends AbstractLifecycleComponent<IndicesService> i
|
||||
private final TimeValue shardsClosedTimeout;
|
||||
private final AnalysisRegistry analysisRegistry;
|
||||
private final IndicesQueriesRegistry indicesQueriesRegistry;
|
||||
private final ClusterService clusterService;
|
||||
private final IndexNameExpressionResolver indexNameExpressionResolver;
|
||||
private final IndexScopedSettings indexScopeSetting;
|
||||
private final IndicesFieldDataCache indicesFieldDataCache;
|
||||
@ -162,7 +161,7 @@ public class IndicesService extends AbstractLifecycleComponent<IndicesService> i
|
||||
public IndicesService(Settings settings, PluginsService pluginsService, NodeEnvironment nodeEnv,
|
||||
ClusterSettings clusterSettings, AnalysisRegistry analysisRegistry,
|
||||
IndicesQueriesRegistry indicesQueriesRegistry, IndexNameExpressionResolver indexNameExpressionResolver,
|
||||
ClusterService clusterService, MapperRegistry mapperRegistry, NamedWriteableRegistry namedWriteableRegistry,
|
||||
MapperRegistry mapperRegistry, NamedWriteableRegistry namedWriteableRegistry,
|
||||
ThreadPool threadPool, IndexScopedSettings indexScopedSettings, CircuitBreakerService circuitBreakerService,
|
||||
MetaStateService metaStateService) {
|
||||
super(settings);
|
||||
@ -173,7 +172,6 @@ public class IndicesService extends AbstractLifecycleComponent<IndicesService> i
|
||||
this.indexStoreConfig = new IndexStoreConfig(settings);
|
||||
this.analysisRegistry = analysisRegistry;
|
||||
this.indicesQueriesRegistry = indicesQueriesRegistry;
|
||||
this.clusterService = clusterService;
|
||||
this.indexNameExpressionResolver = indexNameExpressionResolver;
|
||||
this.indicesRequestCache = new IndicesRequestCache(settings);
|
||||
this.indicesQueryCache = new IndicesQueryCache(settings);
|
||||
@ -379,6 +377,7 @@ public class IndicesService extends AbstractLifecycleComponent<IndicesService> i
|
||||
*/
|
||||
private synchronized IndexService createIndexService(final String reason, final NodeServicesProvider nodeServicesProvider, IndexMetaData indexMetaData, IndicesQueryCache indicesQueryCache, IndicesFieldDataCache indicesFieldDataCache, List<IndexEventListener> builtInListeners, IndexingOperationListener... indexingOperationListeners) throws IOException {
|
||||
final Index index = indexMetaData.getIndex();
|
||||
final ClusterService clusterService = nodeServicesProvider.getClusterService();
|
||||
final Predicate<String> indexNameMatcher = (indexExpression) -> indexNameExpressionResolver.matchesIndex(index.getName(), indexExpression, clusterService.state());
|
||||
final IndexSettings idxSettings = new IndexSettings(indexMetaData, this.settings, indexNameMatcher, indexScopeSetting);
|
||||
logger.debug("creating Index [{}], shards [{}]/[{}{}] - reason [{}]",
|
||||
|
@ -20,7 +20,7 @@
|
||||
package org.elasticsearch.monitor.os;
|
||||
|
||||
import org.apache.lucene.util.Constants;
|
||||
import org.apache.lucene.util.SuppressForbidden;
|
||||
import org.elasticsearch.common.SuppressForbidden;
|
||||
import org.elasticsearch.common.io.PathUtils;
|
||||
import org.elasticsearch.monitor.Probes;
|
||||
|
||||
|
@ -66,9 +66,10 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
|
||||
private ClusterService clusterService;
|
||||
private CapturingTransport transport;
|
||||
private TestTransportNodesAction action;
|
||||
private TransportService transportService;
|
||||
|
||||
public void testRequestIsSentToEachNode() throws Exception {
|
||||
TransportNodesAction action = getTestTransportNodesAction();
|
||||
TestNodesRequest request = new TestNodesRequest();
|
||||
PlainActionFuture<TestNodesResponse> listener = new PlainActionFuture<>();
|
||||
action.new AsyncAction(null, request, listener).start();
|
||||
@ -79,6 +80,7 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
}
|
||||
|
||||
public void testNodesSelectors() {
|
||||
TransportNodesAction action = getTestTransportNodesAction();
|
||||
int numSelectors = randomIntBetween(1, 5);
|
||||
Set<String> nodeSelectors = new HashSet<>();
|
||||
for (int i = 0; i < numSelectors; i++) {
|
||||
@ -98,10 +100,12 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
}
|
||||
|
||||
public void testNewResponseNullArray() {
|
||||
TransportNodesAction action = getTestTransportNodesAction();
|
||||
expectThrows(NullPointerException.class, () -> action.newResponse(new TestNodesRequest(), null));
|
||||
}
|
||||
|
||||
public void testNewResponse() {
|
||||
TestTransportNodesAction action = getTestTransportNodesAction();
|
||||
TestNodesRequest request = new TestNodesRequest();
|
||||
List<TestNodeResponse> expectedNodeResponses = mockList(TestNodeResponse.class, randomIntBetween(0, 2));
|
||||
expectedNodeResponses.add(new TestNodeResponse());
|
||||
@ -125,6 +129,19 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
assertTrue(failures.containsAll(response.failures()));
|
||||
}
|
||||
|
||||
public void testFiltering() throws Exception {
|
||||
TransportNodesAction action = getFilteringTestTransportNodesAction(transportService);
|
||||
TestNodesRequest request = new TestNodesRequest();
|
||||
PlainActionFuture<TestNodesResponse> listener = new PlainActionFuture<>();
|
||||
action.new AsyncAction(null, request, listener).start();
|
||||
Map<String, List<CapturingTransport.CapturedRequest>> capturedRequests = transport.getCapturedRequestsByTargetNodeAndClear();
|
||||
// check requests were only sent to data nodes
|
||||
for (String nodeTarget : capturedRequests.keySet()) {
|
||||
assertTrue(clusterService.state().nodes().get(nodeTarget).isDataNode());
|
||||
}
|
||||
assertEquals(clusterService.state().nodes().getDataNodes().size(), capturedRequests.size());
|
||||
}
|
||||
|
||||
private <T> List<T> mockList(Class<T> clazz, int size) {
|
||||
List<T> failures = new ArrayList<>(size);
|
||||
for (int i = 0; i < size; ++i) {
|
||||
@ -160,7 +177,7 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
super.setUp();
|
||||
transport = new CapturingTransport();
|
||||
clusterService = createClusterService(THREAD_POOL);
|
||||
final TransportService transportService = new TransportService(transport, THREAD_POOL, clusterService.state().getClusterName());
|
||||
transportService = new TransportService(transport, THREAD_POOL, clusterService.state().getClusterName());
|
||||
transportService.start();
|
||||
transportService.acceptIncomingRequests();
|
||||
int numNodes = randomIntBetween(3, 10);
|
||||
@ -182,7 +199,17 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
stateBuilder.nodes(discoBuilder);
|
||||
ClusterState clusterState = stateBuilder.build();
|
||||
setState(clusterService, clusterState);
|
||||
action = new TestTransportNodesAction(
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDown() throws Exception {
|
||||
super.tearDown();
|
||||
clusterService.close();
|
||||
transport.close();
|
||||
}
|
||||
|
||||
public TestTransportNodesAction getTestTransportNodesAction() {
|
||||
return new TestTransportNodesAction(
|
||||
Settings.EMPTY,
|
||||
THREAD_POOL,
|
||||
clusterService,
|
||||
@ -194,11 +221,17 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
);
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDown() throws Exception {
|
||||
super.tearDown();
|
||||
clusterService.close();
|
||||
transport.close();
|
||||
public FilteringTestTransportNodesAction getFilteringTestTransportNodesAction(TransportService transportService) {
|
||||
return new FilteringTestTransportNodesAction(
|
||||
Settings.EMPTY,
|
||||
THREAD_POOL,
|
||||
clusterService,
|
||||
transportService,
|
||||
new ActionFilters(Collections.emptySet()),
|
||||
TestNodesRequest::new,
|
||||
TestNodeRequest::new,
|
||||
ThreadPool.Names.SAME
|
||||
);
|
||||
}
|
||||
|
||||
private static DiscoveryNode newNode(int nodeId, Map<String, String> attributes, Set<DiscoveryNode.Role> roles) {
|
||||
@ -243,6 +276,21 @@ public class TransportNodesActionTests extends ESTestCase {
|
||||
}
|
||||
}
|
||||
|
||||
private static class FilteringTestTransportNodesAction
|
||||
extends TestTransportNodesAction {
|
||||
|
||||
FilteringTestTransportNodesAction(Settings settings, ThreadPool threadPool, ClusterService clusterService, TransportService
|
||||
transportService, ActionFilters actionFilters, Supplier<TestNodesRequest> request,
|
||||
Supplier<TestNodeRequest> nodeRequest, String nodeExecutor) {
|
||||
super(settings, threadPool, clusterService, transportService, actionFilters, request, nodeRequest, nodeExecutor);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String[] filterNodeIds(DiscoveryNodes nodes, String[] nodesIds) {
|
||||
return nodes.getDataNodes().keys().toArray(String.class);
|
||||
}
|
||||
}
|
||||
|
||||
private static class TestNodesRequest extends BaseNodesRequest<TestNodesRequest> {
|
||||
TestNodesRequest(String... nodesIds) {
|
||||
super(nodesIds);
|
||||
|
@ -2184,7 +2184,7 @@ public class InternalEngineTests extends ESTestCase {
|
||||
}
|
||||
|
||||
public void testDocStats() throws IOException {
|
||||
final int numDocs = randomIntBetween(1, 10);
|
||||
final int numDocs = randomIntBetween(2, 10); // at least 2 documents otherwise we don't see any deletes below
|
||||
for (int i = 0; i < numDocs; i++) {
|
||||
ParsedDocument doc = testParsedDocument(Integer.toString(i), Integer.toString(i), "test", null, -1, -1, testDocument(), new BytesArray("{}"), null);
|
||||
Engine.Index firstIndexRequest = new Engine.Index(newUid(Integer.toString(i)), doc, Versions.MATCH_ANY, VersionType.INTERNAL, PRIMARY, System.nanoTime());
|
||||
|
@ -986,7 +986,7 @@ public class ShadowEngineTests extends ESTestCase {
|
||||
}
|
||||
|
||||
public void testDocStats() throws IOException {
|
||||
final int numDocs = randomIntBetween(1, 10);
|
||||
final int numDocs = randomIntBetween(2, 10); // at least 2 documents otherwise we don't see any deletes below
|
||||
for (int i = 0; i < numDocs; i++) {
|
||||
ParsedDocument doc = testParsedDocument(Integer.toString(i), Integer.toString(i), "test", null, -1, -1, testDocument(), new BytesArray("{}"), null);
|
||||
Engine.Index firstIndexRequest = new Engine.Index(newUid(Integer.toString(i)), doc, Versions.MATCH_ANY, VersionType.INTERNAL, PRIMARY, System.nanoTime());
|
||||
|
@ -332,6 +332,7 @@ public class CorruptedFileIT extends ESIntegTestCase {
|
||||
.put(IndexMetaData.SETTING_NUMBER_OF_SHARDS, 1)
|
||||
.put("index.routing.allocation.include._name", primariesNode.getNode().getName())
|
||||
.put(EnableAllocationDecider.INDEX_ROUTING_REBALANCE_ENABLE_SETTING.getKey(), EnableAllocationDecider.Rebalance.NONE)
|
||||
.put("index.allocation.max_retries", Integer.MAX_VALUE) // keep on retrying
|
||||
|
||||
));
|
||||
ensureGreen(); // allocated with empty commit
|
||||
|
@ -105,6 +105,7 @@ public class IndicesServiceTests extends ESSingleNodeTestCase {
|
||||
indicesService.canDeleteShardContent(notAllocated, test.getIndexSettings()));
|
||||
}
|
||||
|
||||
@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/18558")
|
||||
public void testDeleteIndexStore() throws Exception {
|
||||
IndicesService indicesService = getIndicesService();
|
||||
IndexService test = createIndex("test");
|
||||
|
@ -43,15 +43,6 @@ import static org.hamcrest.Matchers.is;
|
||||
|
||||
@ESIntegTestCase.ClusterScope(minNumDataNodes = 2)
|
||||
public class SearchWhileRelocatingIT extends ESIntegTestCase {
|
||||
@Nightly
|
||||
public void testSearchAndRelocateConcurrently0Replicas() throws Exception {
|
||||
testSearchAndRelocateConcurrently(0);
|
||||
}
|
||||
|
||||
@Nightly
|
||||
public void testSearchAndRelocateConcurrently1Replicas() throws Exception {
|
||||
testSearchAndRelocateConcurrently(1);
|
||||
}
|
||||
|
||||
public void testSearchAndRelocateConcurrentlyRanodmReplicas() throws Exception {
|
||||
testSearchAndRelocateConcurrently(randomIntBetween(0, 1));
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -59,7 +59,7 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
private final BytesRef preTag = new BytesRef("<em>");
|
||||
private final BytesRef postTag = new BytesRef("</em>");
|
||||
|
||||
public void testMarvelHeros() throws IOException {
|
||||
public void testNgram() throws IOException {
|
||||
RAMDirectory dir = new RAMDirectory();
|
||||
Map<String, Analyzer> mapping = new HashMap<>();
|
||||
mapping.put("body_ngram", new Analyzer() {
|
||||
@ -87,9 +87,23 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
|
||||
IndexWriterConfig conf = new IndexWriterConfig(wrapper);
|
||||
IndexWriter writer = new IndexWriter(dir, conf);
|
||||
BufferedReader reader = new BufferedReader(new InputStreamReader(NoisyChannelSpellCheckerTests.class.getResourceAsStream("/config/names.txt"), StandardCharsets.UTF_8));
|
||||
String line = null;
|
||||
while ((line = reader.readLine()) != null) {
|
||||
String[] strings = new String[]{
|
||||
"Xorr the God-Jewel",
|
||||
"Grog the God-Crusher",
|
||||
"Xorn",
|
||||
"Walter Newell",
|
||||
"Wanda Maximoff",
|
||||
"Captain America",
|
||||
"American Ace",
|
||||
"USA Hero",
|
||||
"Wundarr the Aquarian",
|
||||
"Will o' the Wisp",
|
||||
"Xemnu the Titan",
|
||||
"Fantastic Four",
|
||||
"Quasar",
|
||||
"Quasar II"
|
||||
};
|
||||
for (String line : strings) {
|
||||
Document doc = new Document();
|
||||
doc.add(new Field("body", line, TextField.TYPE_NOT_STORED));
|
||||
doc.add(new Field("body_ngram", line, TextField.TYPE_NOT_STORED));
|
||||
@ -161,7 +175,7 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
TokenFilter filter = new LowerCaseFilter(t);
|
||||
try {
|
||||
SolrSynonymParser parser = new SolrSynonymParser(true, false, new WhitespaceAnalyzer());
|
||||
parser.parse(new StringReader("usa => usa, america, american\nursa => usa, america, american"));
|
||||
parser.parse(new StringReader("usa => usa, america, american"));
|
||||
filter = new SynonymFilter(filter, parser.build(), true);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
@ -191,7 +205,7 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
assertThat(corrections[0].join(space, preTag, postTag).utf8ToString(), equalTo("captain <em>america</em>"));
|
||||
}
|
||||
|
||||
public void testMarvelHerosMultiGenerator() throws IOException {
|
||||
public void testMultiGenerator() throws IOException {
|
||||
RAMDirectory dir = new RAMDirectory();
|
||||
Map<String, Analyzer> mapping = new HashMap<>();
|
||||
mapping.put("body_ngram", new Analyzer() {
|
||||
@ -228,9 +242,22 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
|
||||
IndexWriterConfig conf = new IndexWriterConfig(wrapper);
|
||||
IndexWriter writer = new IndexWriter(dir, conf);
|
||||
BufferedReader reader = new BufferedReader(new InputStreamReader(NoisyChannelSpellCheckerTests.class.getResourceAsStream("/config/names.txt"), StandardCharsets.UTF_8));
|
||||
String line = null;
|
||||
while ((line = reader.readLine()) != null) {
|
||||
String[] strings = new String[]{
|
||||
"Xorr the God-Jewel",
|
||||
"Grog the God-Crusher",
|
||||
"Xorn",
|
||||
"Walter Newell",
|
||||
"Wanda Maximoff",
|
||||
"Captain America",
|
||||
"American Ace",
|
||||
"Wundarr the Aquarian",
|
||||
"Will o' the Wisp",
|
||||
"Xemnu the Titan",
|
||||
"Fantastic Four",
|
||||
"Quasar",
|
||||
"Quasar II"
|
||||
};
|
||||
for (String line : strings) {
|
||||
Document doc = new Document();
|
||||
doc.add(new Field("body", line, TextField.TYPE_NOT_STORED));
|
||||
doc.add(new Field("body_reverse", line, TextField.TYPE_NOT_STORED));
|
||||
@ -284,7 +311,7 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
assertThat(corrections[0].join(new BytesRef(" ")).utf8ToString(), equalTo("quasar ii"));
|
||||
}
|
||||
|
||||
public void testMarvelHerosTrigram() throws IOException {
|
||||
public void testTrigram() throws IOException {
|
||||
RAMDirectory dir = new RAMDirectory();
|
||||
Map<String, Analyzer> mapping = new HashMap<>();
|
||||
mapping.put("body_ngram", new Analyzer() {
|
||||
@ -312,9 +339,23 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
|
||||
IndexWriterConfig conf = new IndexWriterConfig(wrapper);
|
||||
IndexWriter writer = new IndexWriter(dir, conf);
|
||||
BufferedReader reader = new BufferedReader(new InputStreamReader(NoisyChannelSpellCheckerTests.class.getResourceAsStream("/config/names.txt"), StandardCharsets.UTF_8));
|
||||
String line = null;
|
||||
while ((line = reader.readLine()) != null) {
|
||||
String[] strings = new String[]{
|
||||
"Xorr the God-Jewel",
|
||||
"Grog the God-Crusher",
|
||||
"Xorn",
|
||||
"Walter Newell",
|
||||
"Wanda Maximoff",
|
||||
"Captain America",
|
||||
"American Ace",
|
||||
"USA Hero",
|
||||
"Wundarr the Aquarian",
|
||||
"Will o' the Wisp",
|
||||
"Xemnu the Titan",
|
||||
"Fantastic Four",
|
||||
"Quasar",
|
||||
"Quasar II"
|
||||
};
|
||||
for (String line : strings) {
|
||||
Document doc = new Document();
|
||||
doc.add(new Field("body", line, TextField.TYPE_NOT_STORED));
|
||||
doc.add(new Field("body_ngram", line, TextField.TYPE_NOT_STORED));
|
||||
@ -370,7 +411,7 @@ public class NoisyChannelSpellCheckerTests extends ESTestCase {
|
||||
TokenFilter filter = new LowerCaseFilter(t);
|
||||
try {
|
||||
SolrSynonymParser parser = new SolrSynonymParser(true, false, new WhitespaceAnalyzer());
|
||||
parser.parse(new StringReader("usa => usa, america, american\nursa => usa, america, american"));
|
||||
parser.parse(new StringReader("usa => usa, america, american"));
|
||||
filter = new SynonymFilter(filter, parser.build(), true);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
|
@ -196,8 +196,8 @@ configure(subprojects.findAll { ['zip', 'tar', 'integ-test-zip'].contains(it.nam
|
||||
into('bin') {
|
||||
with copySpec {
|
||||
with binFiles
|
||||
from('../src/main/resources') {
|
||||
include 'bin/*.bat'
|
||||
from('../src/main/resources/bin') {
|
||||
include '*.bat'
|
||||
filter(FixCrLfFilter, eol: FixCrLfFilter.CrLf.newInstance('crlf'))
|
||||
}
|
||||
MavenFilteringHack.filter(it, expansions)
|
||||
|
@ -16,6 +16,7 @@ checks that fail appear as warnings in the Elasticsearch log. If
|
||||
Elasticsearch is in production mode, any bootstrap checks that fail will
|
||||
cause Elasticsearch to refuse to start.
|
||||
|
||||
[float]
|
||||
=== Development vs. production mode
|
||||
|
||||
By default, Elasticsearch binds and publishes to `localhost`. This is
|
||||
@ -45,7 +46,7 @@ check, you must configure the <<heap-size,heap size>>.
|
||||
File descriptors are a Unix construct for tracking open "files". In Unix
|
||||
though, https://en.wikipedia.org/wiki/Everything_is_a_file[everything is
|
||||
a file]. For example, "files" could be a physical file, a virtual file
|
||||
(e.g., ``/proc/loadavg`), or network sockets. Elasticsearch requires
|
||||
(e.g., `/proc/loadavg`), or network sockets. Elasticsearch requires
|
||||
lots file descriptors (e.g., every shard is composed of multiple
|
||||
segments and other files, plus connections to other nodes, etc.). This
|
||||
bootstrap check is enforced on OS X and Linux. To pass the file
|
||||
@ -85,14 +86,15 @@ equal to a quorum of master-eligible nodes, it is not possible for the
|
||||
cluster to suffer from split brain because during a network partition
|
||||
there can be at most one side of the partition that contains a quorum of
|
||||
master nodes. The minimum master nodes check enforces that you've set
|
||||
<<minimum_master_nodes>>. To pass the minimum master nodes check, you
|
||||
must configure
|
||||
<<minimum_master_nodes,`discovery.zen.minimum_master_nodes`>>. To pass
|
||||
the minimum master nodes check, you must configure
|
||||
<<minimum_master_nodes,`discovery.zen.minimum_master_nodes`>>.
|
||||
|
||||
NOTE: The minimum master nodes check does not enforce that you've
|
||||
configured <<minimum_master_nodes,`discovery.zen.minimum_master_nodes`>>
|
||||
correctly, only that you have it configured. Elasticsearch does log a
|
||||
warning message if it detects that <<minimum_master_nodes>> is
|
||||
warning message if it detects that
|
||||
<<minimum_master_nodes,`discovery.zen.minimum_master_nodes`>> is
|
||||
incorrectly configured based on the number of master-eligible nodes
|
||||
visible in the cluster state. Future versions of Elasticsearch will
|
||||
contain stricter enforcement of
|
||||
|
@ -105,10 +105,10 @@ LimitMEMLOCK=infinity
|
||||
==== Setting JVM system properties
|
||||
|
||||
The preferred method of setting Java Virtual Machine options (including
|
||||
system properties and JVM flags) is via the jvm.options configuration
|
||||
file. The default location of this file is config/jvm.options (when
|
||||
system properties and JVM flags) is via the `jvm.options` configuration
|
||||
file. The default location of this file is `config/jvm.options` (when
|
||||
installing from the tar or zip distributions) and
|
||||
/etc/elasticsearch/jvm.options (when installing from the Debian or RPM
|
||||
`/etc/elasticsearch/jvm.options` (when installing from the Debian or RPM
|
||||
packages). This file contains a line-delimited list of JVM arguments,
|
||||
which must begin with `-`. You can add custom JVM flags to this file and
|
||||
check this configuration into your version control system.
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -43,6 +43,11 @@ public final class Definition {
|
||||
"java.lang.txt",
|
||||
"java.math.txt",
|
||||
"java.text.txt",
|
||||
"java.time.txt",
|
||||
"java.time.chrono.txt",
|
||||
"java.time.format.txt",
|
||||
"java.time.temporal.txt",
|
||||
"java.time.zone.txt",
|
||||
"java.util.txt",
|
||||
"java.util.function.txt",
|
||||
"java.util.stream.txt"));
|
||||
|
336
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.chrono.txt
Normal file
336
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.chrono.txt
Normal file
@ -0,0 +1,336 @@
|
||||
#
|
||||
# Licensed to Elasticsearch under one or more contributor
|
||||
# license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright
|
||||
# ownership. Elasticsearch licenses this file to you under
|
||||
# the Apache License, Version 2.0 (the "License"); you may
|
||||
# not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
#
|
||||
|
||||
#
|
||||
# Painless definition file. This defines the hierarchy of classes,
|
||||
# what methods and fields they have, etc.
|
||||
#
|
||||
|
||||
#### Interfaces
|
||||
|
||||
class ChronoLocalDate -> java.time.chrono.ChronoLocalDate extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster {
|
||||
ChronoLocalDateTime atTime(LocalTime)
|
||||
boolean equals(Object)
|
||||
String format(DateTimeFormatter)
|
||||
ChronoLocalDate from(TemporalAccessor)
|
||||
Chronology getChronology()
|
||||
Era getEra()
|
||||
int hashCode()
|
||||
boolean isAfter(ChronoLocalDate)
|
||||
boolean isBefore(ChronoLocalDate)
|
||||
boolean isEqual(ChronoLocalDate)
|
||||
boolean isLeapYear()
|
||||
int lengthOfMonth()
|
||||
int lengthOfYear()
|
||||
ChronoLocalDate minus(TemporalAmount)
|
||||
ChronoLocalDate minus(long,TemporalUnit)
|
||||
ChronoLocalDate plus(TemporalAmount)
|
||||
ChronoLocalDate plus(long,TemporalUnit)
|
||||
Comparator timeLineOrder()
|
||||
long toEpochDay()
|
||||
String toString()
|
||||
ChronoPeriod until(ChronoLocalDate)
|
||||
ChronoLocalDate with(TemporalAdjuster)
|
||||
ChronoLocalDate with(TemporalField,long)
|
||||
}
|
||||
|
||||
class ChronoLocalDateTime -> java.time.chrono.ChronoLocalDateTime extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster {
|
||||
ChronoZonedDateTime atZone(ZoneId)
|
||||
boolean equals(Object)
|
||||
String format(DateTimeFormatter)
|
||||
ChronoLocalDateTime from(TemporalAccessor)
|
||||
int hashCode()
|
||||
boolean isAfter(ChronoLocalDateTime)
|
||||
boolean isBefore(ChronoLocalDateTime)
|
||||
boolean isEqual(ChronoLocalDateTime)
|
||||
Chronology getChronology()
|
||||
ChronoLocalDateTime minus(TemporalAmount)
|
||||
ChronoLocalDateTime minus(long,TemporalUnit)
|
||||
ChronoLocalDateTime plus(TemporalAmount)
|
||||
ChronoLocalDateTime plus(long,TemporalUnit)
|
||||
Comparator timeLineOrder()
|
||||
long toEpochSecond(ZoneOffset)
|
||||
Instant toInstant(ZoneOffset)
|
||||
ChronoLocalDate toLocalDate()
|
||||
LocalTime toLocalTime()
|
||||
String toString()
|
||||
ChronoLocalDateTime with(TemporalAdjuster)
|
||||
ChronoLocalDateTime with(TemporalField,long)
|
||||
}
|
||||
|
||||
class Chronology -> java.time.chrono.Chronology extends Comparable {
|
||||
ChronoLocalDate date(TemporalAccessor)
|
||||
ChronoLocalDate date(Era,int,int,int)
|
||||
ChronoLocalDate date(int,int,int)
|
||||
ChronoLocalDate dateEpochDay(long)
|
||||
ChronoLocalDate dateNow()
|
||||
ChronoLocalDate dateNow(ZoneId)
|
||||
ChronoLocalDate dateYearDay(Era,int,int)
|
||||
ChronoLocalDate dateYearDay(int,int)
|
||||
boolean equals(Object)
|
||||
Era eraOf(int)
|
||||
List eras()
|
||||
Chronology from(TemporalAccessor)
|
||||
Set getAvailableChronologies()
|
||||
String getDisplayName(TextStyle,Locale)
|
||||
String getId()
|
||||
String getCalendarType()
|
||||
int hashCode()
|
||||
boolean isLeapYear(long)
|
||||
ChronoLocalDateTime localDateTime(TemporalAccessor)
|
||||
Chronology of(String)
|
||||
Chronology ofLocale(Locale)
|
||||
ChronoPeriod period(int,int,int)
|
||||
int prolepticYear(Era,int)
|
||||
ValueRange range(ChronoField)
|
||||
ChronoLocalDate resolveDate(Map,ResolverStyle)
|
||||
String toString()
|
||||
ChronoZonedDateTime zonedDateTime(TemporalAccessor)
|
||||
ChronoZonedDateTime zonedDateTime(Instant,ZoneId)
|
||||
}
|
||||
|
||||
class ChronoPeriod -> java.time.chrono.ChronoPeriod extends TemporalAmount {
|
||||
ChronoPeriod between(ChronoLocalDate,ChronoLocalDate)
|
||||
boolean equals(Object)
|
||||
Chronology getChronology()
|
||||
List getUnits()
|
||||
int hashCode()
|
||||
boolean isNegative()
|
||||
boolean isZero()
|
||||
ChronoPeriod minus(TemporalAmount)
|
||||
ChronoPeriod multipliedBy(int)
|
||||
ChronoPeriod negated()
|
||||
ChronoPeriod normalized()
|
||||
ChronoPeriod plus(TemporalAmount)
|
||||
String toString()
|
||||
}
|
||||
|
||||
class ChronoZonedDateTime -> java.time.chrono.ChronoZonedDateTime extends Comparable,Temporal,TemporalAccessor {
|
||||
boolean equals(Object)
|
||||
String format(DateTimeFormatter)
|
||||
ChronoZonedDateTime from(TemporalAccessor)
|
||||
Chronology getChronology()
|
||||
ZoneOffset getOffset()
|
||||
ZoneId getZone()
|
||||
int hashCode()
|
||||
boolean isBefore(ChronoZonedDateTime)
|
||||
boolean isAfter(ChronoZonedDateTime)
|
||||
boolean isEqual(ChronoZonedDateTime)
|
||||
ChronoZonedDateTime minus(TemporalAmount)
|
||||
ChronoZonedDateTime minus(long,TemporalUnit)
|
||||
ChronoZonedDateTime plus(TemporalAmount)
|
||||
ChronoZonedDateTime plus(long,TemporalUnit)
|
||||
Comparator timeLineOrder()
|
||||
Instant toInstant()
|
||||
long toEpochSecond()
|
||||
ChronoLocalDate toLocalDate()
|
||||
LocalTime toLocalTime()
|
||||
ChronoLocalDateTime toLocalDateTime()
|
||||
String toString()
|
||||
ChronoZonedDateTime with(TemporalAdjuster)
|
||||
ChronoZonedDateTime with(TemporalField,long)
|
||||
ChronoZonedDateTime withEarlierOffsetAtOverlap()
|
||||
ChronoZonedDateTime withLaterOffsetAtOverlap()
|
||||
ChronoZonedDateTime withZoneSameLocal(ZoneId)
|
||||
ChronoZonedDateTime withZoneSameInstant(ZoneId)
|
||||
}
|
||||
|
||||
class Era -> java.time.chrono.Era extends TemporalAccessor,TemporalAdjuster {
|
||||
String getDisplayName(TextStyle,Locale)
|
||||
int getValue()
|
||||
}
|
||||
|
||||
#### Classes
|
||||
|
||||
class AbstractChronology -> java.time.chrono.Chronology extends Comparable,Chronology,Object {
|
||||
}
|
||||
|
||||
class HijrahChronology -> java.time.chrono.HijrahChronology extends AbstractChronology,Comparable,Chronology,Object {
|
||||
HijrahChronology INSTANCE
|
||||
HijrahDate date(TemporalAccessor)
|
||||
HijrahDate date(int,int,int)
|
||||
HijrahDate date(Era,int,int,int)
|
||||
HijrahDate dateEpochDay(long)
|
||||
HijrahDate dateNow()
|
||||
HijrahDate dateNow(ZoneId)
|
||||
HijrahDate dateYearDay(int,int)
|
||||
HijrahDate dateYearDay(Era,int,int)
|
||||
HijrahEra eraOf(int)
|
||||
}
|
||||
|
||||
class HijrahDate -> java.time.chrono.HijrahDate extends Comparable,ChronoLocalDate,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
HijrahDate now()
|
||||
HijrahDate now(ZoneId)
|
||||
HijrahDate of(int,int,int)
|
||||
HijrahDate from(TemporalAccessor)
|
||||
HijrahChronology getChronology()
|
||||
HijrahEra getEra()
|
||||
HijrahDate with(TemporalField,long)
|
||||
HijrahDate with(TemporalAdjuster)
|
||||
HijrahDate withVariant(HijrahChronology)
|
||||
HijrahDate plus(TemporalAmount)
|
||||
HijrahDate minus(TemporalAmount)
|
||||
HijrahDate plus(long,TemporalUnit)
|
||||
HijrahDate minus(long,TemporalUnit)
|
||||
}
|
||||
|
||||
class IsoChronology -> java.time.chrono.IsoChronology extends AbstractChronology,Comparable,Chronology,Object {
|
||||
IsoChronology INSTANCE
|
||||
LocalDate date(TemporalAccessor)
|
||||
LocalDate date(int,int,int)
|
||||
LocalDate date(Era,int,int,int)
|
||||
LocalDate dateEpochDay(long)
|
||||
LocalDate dateNow()
|
||||
LocalDate dateNow(ZoneId)
|
||||
LocalDate dateYearDay(int,int)
|
||||
LocalDate dateYearDay(Era,int,int)
|
||||
IsoEra eraOf(int)
|
||||
}
|
||||
|
||||
class JapaneseChronology -> java.time.chrono.JapaneseChronology extends AbstractChronology,Comparable,Chronology,Object {
|
||||
JapaneseChronology INSTANCE
|
||||
JapaneseDate date(TemporalAccessor)
|
||||
JapaneseDate date(int,int,int)
|
||||
JapaneseDate date(Era,int,int,int)
|
||||
JapaneseDate dateEpochDay(long)
|
||||
JapaneseDate dateNow()
|
||||
JapaneseDate dateNow(ZoneId)
|
||||
JapaneseDate dateYearDay(int,int)
|
||||
JapaneseDate dateYearDay(Era,int,int)
|
||||
JapaneseEra eraOf(int)
|
||||
}
|
||||
|
||||
class JapaneseDate -> java.time.chrono.JapaneseDate extends Comparable,ChronoLocalDate,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
JapaneseDate now()
|
||||
JapaneseDate now(ZoneId)
|
||||
JapaneseDate of(int,int,int)
|
||||
JapaneseDate from(TemporalAccessor)
|
||||
JapaneseChronology getChronology()
|
||||
JapaneseEra getEra()
|
||||
JapaneseDate with(TemporalField,long)
|
||||
JapaneseDate with(TemporalAdjuster)
|
||||
JapaneseDate plus(TemporalAmount)
|
||||
JapaneseDate minus(TemporalAmount)
|
||||
JapaneseDate plus(long,TemporalUnit)
|
||||
JapaneseDate minus(long,TemporalUnit)
|
||||
}
|
||||
|
||||
class JapaneseEra -> java.time.chrono.JapaneseEra extends Era,TemporalAccessor,TemporalAdjuster,Object {
|
||||
JapaneseEra HEISEI
|
||||
JapaneseEra MEIJI
|
||||
JapaneseEra SHOWA
|
||||
JapaneseEra TAISHO
|
||||
int getValue()
|
||||
JapaneseEra of(int)
|
||||
JapaneseEra valueOf(String)
|
||||
JapaneseEra[] values()
|
||||
}
|
||||
|
||||
class MinguoChronology -> java.time.chrono.MinguoChronology extends AbstractChronology,Comparable,Chronology,Object {
|
||||
MinguoChronology INSTANCE
|
||||
MinguoDate date(TemporalAccessor)
|
||||
MinguoDate date(int,int,int)
|
||||
MinguoDate date(Era,int,int,int)
|
||||
MinguoDate dateEpochDay(long)
|
||||
MinguoDate dateNow()
|
||||
MinguoDate dateNow(ZoneId)
|
||||
MinguoDate dateYearDay(int,int)
|
||||
MinguoDate dateYearDay(Era,int,int)
|
||||
MinguoEra eraOf(int)
|
||||
}
|
||||
|
||||
class MinguoDate -> java.time.chrono.MinguoDate extends Comparable,ChronoLocalDate,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
MinguoDate now()
|
||||
MinguoDate now(ZoneId)
|
||||
MinguoDate of(int,int,int)
|
||||
MinguoDate from(TemporalAccessor)
|
||||
MinguoChronology getChronology()
|
||||
MinguoEra getEra()
|
||||
MinguoDate with(TemporalField,long)
|
||||
MinguoDate with(TemporalAdjuster)
|
||||
MinguoDate plus(TemporalAmount)
|
||||
MinguoDate minus(TemporalAmount)
|
||||
MinguoDate plus(long,TemporalUnit)
|
||||
MinguoDate minus(long,TemporalUnit)
|
||||
}
|
||||
|
||||
class ThaiBuddhistChronology -> java.time.chrono.ThaiBuddhistChronology extends AbstractChronology,Comparable,Chronology,Object {
|
||||
ThaiBuddhistChronology INSTANCE
|
||||
ThaiBuddhistDate date(TemporalAccessor)
|
||||
ThaiBuddhistDate date(int,int,int)
|
||||
ThaiBuddhistDate date(Era,int,int,int)
|
||||
ThaiBuddhistDate dateEpochDay(long)
|
||||
ThaiBuddhistDate dateNow()
|
||||
ThaiBuddhistDate dateNow(ZoneId)
|
||||
ThaiBuddhistDate dateYearDay(int,int)
|
||||
ThaiBuddhistDate dateYearDay(Era,int,int)
|
||||
ThaiBuddhistEra eraOf(int)
|
||||
}
|
||||
|
||||
class ThaiBuddhistDate -> java.time.chrono.ThaiBuddhistDate extends Comparable,ChronoLocalDate,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
ThaiBuddhistDate now()
|
||||
ThaiBuddhistDate now(ZoneId)
|
||||
ThaiBuddhistDate of(int,int,int)
|
||||
ThaiBuddhistDate from(TemporalAccessor)
|
||||
ThaiBuddhistChronology getChronology()
|
||||
ThaiBuddhistEra getEra()
|
||||
ThaiBuddhistDate with(TemporalField,long)
|
||||
ThaiBuddhistDate with(TemporalAdjuster)
|
||||
ThaiBuddhistDate plus(TemporalAmount)
|
||||
ThaiBuddhistDate minus(TemporalAmount)
|
||||
ThaiBuddhistDate plus(long,TemporalUnit)
|
||||
ThaiBuddhistDate minus(long,TemporalUnit)
|
||||
}
|
||||
|
||||
#### Enums
|
||||
|
||||
class HijrahEra -> java.time.chrono.HijrahEra extends Enum,Comparable,Era,TemporalAccessor,TemporalAdjuster,Object {
|
||||
HijrahEra AH
|
||||
int getValue()
|
||||
HijrahEra of(int)
|
||||
HijrahEra valueOf(String)
|
||||
HijrahEra[] values()
|
||||
}
|
||||
|
||||
class IsoEra -> java.time.chrono.IsoEra extends Enum,Comparable,Era,TemporalAccessor,TemporalAdjuster,Object {
|
||||
IsoEra BCE
|
||||
IsoEra CE
|
||||
int getValue()
|
||||
IsoEra of(int)
|
||||
IsoEra valueOf(String)
|
||||
IsoEra[] values()
|
||||
}
|
||||
|
||||
class MinguoEra -> java.time.chrono.MinguoEra extends Enum,Comparable,Era,TemporalAccessor,TemporalAdjuster,Object {
|
||||
MinguoEra BEFORE_ROC
|
||||
MinguoEra ROC
|
||||
int getValue()
|
||||
MinguoEra of(int)
|
||||
MinguoEra valueOf(String)
|
||||
MinguoEra[] values()
|
||||
}
|
||||
|
||||
class ThaiBuddhistEra -> java.time.chrono.ThaiBuddhistEra extends Enum,Comparable,Era,TemporalAccessor,TemporalAdjuster,Object {
|
||||
ThaiBuddhistEra BE
|
||||
ThaiBuddhistEra BEFORE_BE
|
||||
int getValue()
|
||||
ThaiBuddhistEra of(int)
|
||||
ThaiBuddhistEra valueOf(String)
|
||||
ThaiBuddhistEra[] values()
|
||||
}
|
177
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.format.txt
Normal file
177
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.format.txt
Normal file
@ -0,0 +1,177 @@
|
||||
#
|
||||
# Licensed to Elasticsearch under one or more contributor
|
||||
# license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright
|
||||
# ownership. Elasticsearch licenses this file to you under
|
||||
# the Apache License, Version 2.0 (the "License"); you may
|
||||
# not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
#
|
||||
|
||||
#
|
||||
# Painless definition file. This defines the hierarchy of classes,
|
||||
# what methods and fields they have, etc.
|
||||
#
|
||||
|
||||
#### Classes
|
||||
|
||||
class DateTimeFormatter -> java.time.format.DateTimeFormatter extends Object {
|
||||
DateTimeFormatter BASIC_ISO_DATE
|
||||
DateTimeFormatter ISO_DATE
|
||||
DateTimeFormatter ISO_DATE_TIME
|
||||
DateTimeFormatter ISO_INSTANT
|
||||
DateTimeFormatter ISO_LOCAL_DATE
|
||||
DateTimeFormatter ISO_LOCAL_DATE_TIME
|
||||
DateTimeFormatter ISO_LOCAL_TIME
|
||||
DateTimeFormatter ISO_OFFSET_DATE
|
||||
DateTimeFormatter ISO_OFFSET_DATE_TIME
|
||||
DateTimeFormatter ISO_OFFSET_TIME
|
||||
DateTimeFormatter ISO_ORDINAL_DATE
|
||||
DateTimeFormatter ISO_TIME
|
||||
DateTimeFormatter ISO_WEEK_DATE
|
||||
DateTimeFormatter ISO_ZONED_DATE_TIME
|
||||
DateTimeFormatter RFC_1123_DATE_TIME
|
||||
String format(TemporalAccessor)
|
||||
void formatTo(TemporalAccessor,Appendable)
|
||||
Chronology getChronology()
|
||||
DecimalStyle getDecimalStyle()
|
||||
Locale getLocale()
|
||||
Set getResolverFields()
|
||||
ResolverStyle getResolverStyle()
|
||||
ZoneId getZone()
|
||||
DateTimeFormatter ofLocalizedDate(FormatStyle)
|
||||
DateTimeFormatter ofLocalizedDateTime(FormatStyle)
|
||||
DateTimeFormatter ofLocalizedDateTime(FormatStyle,FormatStyle)
|
||||
DateTimeFormatter ofLocalizedTime(FormatStyle)
|
||||
DateTimeFormatter ofPattern(String)
|
||||
DateTimeFormatter ofPattern(String,Locale)
|
||||
TemporalAccessor parse(CharSequence)
|
||||
def parse(CharSequence,TemporalQuery)
|
||||
TemporalAccessor parseBest(CharSequence,TemporalQuery[])
|
||||
TemporalQuery parsedExcessDays()
|
||||
TemporalQuery parsedLeapSecond()
|
||||
TemporalAccessor parseUnresolved(CharSequence,ParsePosition)
|
||||
Format toFormat()
|
||||
Format toFormat(TemporalQuery)
|
||||
DateTimeFormatter withChronology(Chronology)
|
||||
DateTimeFormatter withDecimalStyle(DecimalStyle)
|
||||
DateTimeFormatter withLocale(Locale)
|
||||
DateTimeFormatter withResolverFields(Set)
|
||||
DateTimeFormatter withResolverStyle(ResolverStyle)
|
||||
DateTimeFormatter withZone(ZoneId)
|
||||
}
|
||||
|
||||
class DateTimeFormatterBuilder -> java.time.format.DateTimeFormatterBuilder extends Object {
|
||||
DateTimeFormatterBuilder <init>()
|
||||
DateTimeFormatterBuilder append(DateTimeFormatter)
|
||||
DateTimeFormatterBuilder appendChronologyId()
|
||||
DateTimeFormatterBuilder appendChronologyText(TextStyle)
|
||||
DateTimeFormatterBuilder appendFraction(TemporalField,int,int,boolean)
|
||||
DateTimeFormatterBuilder appendInstant()
|
||||
DateTimeFormatterBuilder appendInstant(int)
|
||||
DateTimeFormatterBuilder appendLiteral(String)
|
||||
DateTimeFormatterBuilder appendLocalized(FormatStyle,FormatStyle)
|
||||
DateTimeFormatterBuilder appendLocalizedOffset(TextStyle)
|
||||
DateTimeFormatterBuilder appendOffset(String,String)
|
||||
DateTimeFormatterBuilder appendOffsetId()
|
||||
DateTimeFormatterBuilder appendOptional(DateTimeFormatter)
|
||||
DateTimeFormatterBuilder appendPattern(String)
|
||||
DateTimeFormatterBuilder appendText(TemporalField)
|
||||
DateTimeFormatterBuilder appendText(TemporalField,TextStyle)
|
||||
DateTimeFormatterBuilder appendValue(TemporalField)
|
||||
DateTimeFormatterBuilder appendValue(TemporalField,int)
|
||||
DateTimeFormatterBuilder appendValue(TemporalField,int,int,SignStyle)
|
||||
DateTimeFormatterBuilder appendValueReduced(TemporalField,int,int,int)
|
||||
DateTimeFormatterBuilder appendZoneId()
|
||||
DateTimeFormatterBuilder appendZoneOrOffsetId()
|
||||
DateTimeFormatterBuilder appendZoneRegionId()
|
||||
DateTimeFormatterBuilder appendZoneText(TextStyle)
|
||||
DateTimeFormatterBuilder appendZoneText(TextStyle,Set)
|
||||
String getLocalizedDateTimePattern(FormatStyle,FormatStyle,Chronology,Locale)
|
||||
DateTimeFormatterBuilder optionalEnd()
|
||||
DateTimeFormatterBuilder optionalStart()
|
||||
DateTimeFormatterBuilder padNext(int)
|
||||
DateTimeFormatterBuilder padNext(int,char)
|
||||
DateTimeFormatterBuilder parseCaseInsensitive()
|
||||
DateTimeFormatterBuilder parseCaseSensitive()
|
||||
DateTimeFormatterBuilder parseDefaulting(TemporalField,long)
|
||||
DateTimeFormatterBuilder parseLenient()
|
||||
DateTimeFormatterBuilder parseStrict()
|
||||
DateTimeFormatter toFormatter()
|
||||
DateTimeFormatter toFormatter(Locale)
|
||||
}
|
||||
|
||||
class DecimalStyle -> java.time.format.DecimalStyle extends Object {
|
||||
DecimalStyle STANDARD
|
||||
Set getAvailableLocales()
|
||||
char getDecimalSeparator()
|
||||
char getNegativeSign()
|
||||
char getPositiveSign()
|
||||
char getZeroDigit()
|
||||
DecimalStyle of(Locale)
|
||||
DecimalStyle ofDefaultLocale()
|
||||
DecimalStyle withDecimalSeparator(char)
|
||||
DecimalStyle withNegativeSign(char)
|
||||
DecimalStyle withPositiveSign(char)
|
||||
DecimalStyle withZeroDigit(char)
|
||||
}
|
||||
|
||||
#### Enums
|
||||
|
||||
class FormatStyle -> java.time.format.FormatStyle extends Enum,Comparable,Object {
|
||||
FormatStyle FULL
|
||||
FormatStyle LONG
|
||||
FormatStyle MEDIUM
|
||||
FormatStyle SHORT
|
||||
FormatStyle valueOf(String)
|
||||
FormatStyle[] values()
|
||||
}
|
||||
|
||||
class ResolverStyle -> java.time.format.ResolverStyle extends Enum,Comparable,Object {
|
||||
ResolverStyle LENIENT
|
||||
ResolverStyle SMART
|
||||
ResolverStyle STRICT
|
||||
ResolverStyle valueOf(String)
|
||||
ResolverStyle[] values()
|
||||
}
|
||||
|
||||
class SignStyle -> java.time.format.SignStyle extends Enum,Comparable,Object {
|
||||
SignStyle ALWAYS
|
||||
SignStyle EXCEEDS_PAD
|
||||
SignStyle NEVER
|
||||
SignStyle NORMAL
|
||||
SignStyle NOT_NEGATIVE
|
||||
SignStyle valueOf(String)
|
||||
SignStyle[] values()
|
||||
}
|
||||
|
||||
class TextStyle -> java.time.format.TextStyle extends Enum,Comparable,Object {
|
||||
TextStyle FULL
|
||||
TextStyle FULL_STANDALONE
|
||||
TextStyle NARROW
|
||||
TextStyle NARROW_STANDALONE
|
||||
TextStyle SHORT
|
||||
TextStyle SHORT_STANDALONE
|
||||
TextStyle asNormal()
|
||||
TextStyle asStandalone()
|
||||
boolean isStandalone()
|
||||
TextStyle valueOf(String)
|
||||
TextStyle[] values()
|
||||
}
|
||||
|
||||
#### Exceptions
|
||||
|
||||
class DateTimeParseException -> java.time.format.DateTimeParseException extends DateTimeException,RuntimeException,Exception,Object {
|
||||
DateTimeParseException <init>(String,CharSequence,int)
|
||||
int getErrorIndex()
|
||||
String getParsedString()
|
||||
}
|
225
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.temporal.txt
Normal file
225
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.temporal.txt
Normal file
@ -0,0 +1,225 @@
|
||||
#
|
||||
# Licensed to Elasticsearch under one or more contributor
|
||||
# license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright
|
||||
# ownership. Elasticsearch licenses this file to you under
|
||||
# the Apache License, Version 2.0 (the "License"); you may
|
||||
# not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
#
|
||||
|
||||
#
|
||||
# Painless definition file. This defines the hierarchy of classes,
|
||||
# what methods and fields they have, etc.
|
||||
#
|
||||
|
||||
#### Interfaces
|
||||
|
||||
class Temporal -> java.time.temporal.Temporal extends TemporalAccessor {
|
||||
Temporal minus(long,TemporalUnit)
|
||||
Temporal minus(TemporalAmount)
|
||||
Temporal plus(long,TemporalUnit)
|
||||
Temporal plus(TemporalAmount)
|
||||
long until(Temporal,TemporalUnit)
|
||||
Temporal with(TemporalAdjuster)
|
||||
Temporal with(TemporalField,long)
|
||||
}
|
||||
|
||||
class TemporalAccessor -> java.time.temporal.TemporalAccessor {
|
||||
int get(TemporalField)
|
||||
long getLong(TemporalField)
|
||||
boolean isSupported(TemporalField)
|
||||
def query(TemporalQuery)
|
||||
ValueRange range(TemporalField)
|
||||
}
|
||||
|
||||
class TemporalAdjuster -> java.time.temporal.TemporalAdjuster {
|
||||
Temporal adjustInto(Temporal)
|
||||
}
|
||||
|
||||
class TemporalAmount -> java.time.temporal.TemporalAmount {
|
||||
Temporal addTo(Temporal)
|
||||
long get(TemporalUnit)
|
||||
List getUnits()
|
||||
Temporal subtractFrom(Temporal)
|
||||
}
|
||||
|
||||
class TemporalField -> java.time.temporal.TemporalField {
|
||||
Temporal adjustInto(Temporal,long)
|
||||
TemporalUnit getBaseUnit()
|
||||
String getDisplayName(Locale)
|
||||
long getFrom(TemporalAccessor)
|
||||
TemporalUnit getRangeUnit()
|
||||
boolean isDateBased()
|
||||
boolean isSupportedBy(TemporalAccessor)
|
||||
boolean isTimeBased()
|
||||
ValueRange range()
|
||||
ValueRange rangeRefinedBy(TemporalAccessor)
|
||||
TemporalAccessor resolve(Map,TemporalAccessor,ResolverStyle)
|
||||
String toString()
|
||||
}
|
||||
|
||||
class TemporalQuery -> java.time.temporal.TemporalQuery {
|
||||
def queryFrom(TemporalAccessor)
|
||||
}
|
||||
|
||||
class TemporalUnit -> java.time.temporal.TemporalUnit {
|
||||
Temporal addTo(Temporal,long)
|
||||
long between(Temporal,Temporal)
|
||||
Duration getDuration()
|
||||
boolean isDateBased()
|
||||
boolean isDurationEstimated()
|
||||
boolean isSupportedBy(Temporal)
|
||||
boolean isTimeBased()
|
||||
String toString()
|
||||
}
|
||||
|
||||
#### Classes
|
||||
|
||||
class IsoFields -> java.time.temporal.IsoFields extends Object {
|
||||
TemporalField DAY_OF_QUARTER
|
||||
TemporalField QUARTER_OF_YEAR
|
||||
TemporalUnit QUARTER_YEARS
|
||||
TemporalField WEEK_BASED_YEAR
|
||||
TemporalUnit WEEK_BASED_YEARS
|
||||
TemporalField WEEK_OF_WEEK_BASED_YEAR
|
||||
}
|
||||
|
||||
class JulianFields -> java.time.temporal.JulianFields extends Object {
|
||||
TemporalField JULIAN_DAY
|
||||
TemporalField MODIFIED_JULIAN_DAY
|
||||
TemporalField RATA_DIE
|
||||
}
|
||||
|
||||
class TemporalAdjusters -> java.time.temporal.TemporalAdjusters extends Object {
|
||||
TemporalAdjuster dayOfWeekInMonth(int,DayOfWeek)
|
||||
TemporalAdjuster firstDayOfMonth()
|
||||
TemporalAdjuster firstDayOfNextMonth()
|
||||
TemporalAdjuster firstDayOfNextYear()
|
||||
TemporalAdjuster firstDayOfYear()
|
||||
TemporalAdjuster firstInMonth(DayOfWeek)
|
||||
TemporalAdjuster lastDayOfMonth()
|
||||
TemporalAdjuster lastDayOfYear()
|
||||
TemporalAdjuster lastInMonth(DayOfWeek)
|
||||
TemporalAdjuster next(DayOfWeek)
|
||||
TemporalAdjuster nextOrSame(DayOfWeek)
|
||||
TemporalAdjuster ofDateAdjuster(UnaryOperator)
|
||||
TemporalAdjuster previous(DayOfWeek)
|
||||
TemporalAdjuster previousOrSame(DayOfWeek)
|
||||
}
|
||||
|
||||
class TemporalQueries -> java.time.temporal.TemporalQueries extends Object {
|
||||
TemporalQuery chronology()
|
||||
TemporalQuery localDate()
|
||||
TemporalQuery localTime()
|
||||
TemporalQuery offset()
|
||||
TemporalQuery precision()
|
||||
TemporalQuery zone()
|
||||
TemporalQuery zoneId()
|
||||
}
|
||||
|
||||
class ValueRange -> java.time.temporal.ValueRange extends Object {
|
||||
int checkValidIntValue(long,TemporalField)
|
||||
long checkValidValue(long,TemporalField)
|
||||
long getLargestMinimum()
|
||||
long getMaximum()
|
||||
long getMinimum()
|
||||
long getSmallestMaximum()
|
||||
boolean isFixed()
|
||||
boolean isIntValue()
|
||||
boolean isValidIntValue(long)
|
||||
boolean isValidValue(long)
|
||||
ValueRange of(long,long)
|
||||
ValueRange of(long,long,long)
|
||||
ValueRange of(long,long,long,long)
|
||||
}
|
||||
|
||||
class WeekFields -> java.time.temporal.WeekFields extends Object {
|
||||
WeekFields ISO
|
||||
WeekFields SUNDAY_START
|
||||
TemporalUnit WEEK_BASED_YEARS
|
||||
TemporalField dayOfWeek()
|
||||
DayOfWeek getFirstDayOfWeek()
|
||||
int getMinimalDaysInFirstWeek()
|
||||
WeekFields of(DayOfWeek,int)
|
||||
WeekFields of(Locale)
|
||||
TemporalField weekBasedYear()
|
||||
TemporalField weekOfMonth()
|
||||
TemporalField weekOfWeekBasedYear()
|
||||
TemporalField weekOfYear()
|
||||
}
|
||||
|
||||
#### Enums
|
||||
|
||||
class ChronoField -> java.time.temporal.ChronoField extends Enum,Comparable,TemporalField,Object {
|
||||
ChronoField ALIGNED_DAY_OF_WEEK_IN_MONTH
|
||||
ChronoField ALIGNED_DAY_OF_WEEK_IN_YEAR
|
||||
ChronoField ALIGNED_WEEK_OF_MONTH
|
||||
ChronoField ALIGNED_WEEK_OF_YEAR
|
||||
ChronoField AMPM_OF_DAY
|
||||
ChronoField CLOCK_HOUR_OF_AMPM
|
||||
ChronoField CLOCK_HOUR_OF_DAY
|
||||
ChronoField DAY_OF_MONTH
|
||||
ChronoField DAY_OF_WEEK
|
||||
ChronoField DAY_OF_YEAR
|
||||
ChronoField EPOCH_DAY
|
||||
ChronoField ERA
|
||||
ChronoField HOUR_OF_AMPM
|
||||
ChronoField HOUR_OF_DAY
|
||||
ChronoField INSTANT_SECONDS
|
||||
ChronoField MICRO_OF_DAY
|
||||
ChronoField MICRO_OF_SECOND
|
||||
ChronoField MILLI_OF_DAY
|
||||
ChronoField MILLI_OF_SECOND
|
||||
ChronoField MINUTE_OF_DAY
|
||||
ChronoField MINUTE_OF_HOUR
|
||||
ChronoField MONTH_OF_YEAR
|
||||
ChronoField NANO_OF_DAY
|
||||
ChronoField NANO_OF_SECOND
|
||||
ChronoField OFFSET_SECONDS
|
||||
ChronoField PROLEPTIC_MONTH
|
||||
ChronoField SECOND_OF_DAY
|
||||
ChronoField SECOND_OF_MINUTE
|
||||
ChronoField YEAR
|
||||
ChronoField YEAR_OF_ERA
|
||||
int checkValidIntValue(long)
|
||||
long checkValidValue(long)
|
||||
ChronoField valueOf(String)
|
||||
ChronoField[] values()
|
||||
}
|
||||
|
||||
class ChronoUnit -> java.time.temporal.ChronoUnit extends Enum,Comparable,TemporalUnit,Object {
|
||||
ChronoUnit CENTURIES
|
||||
ChronoUnit DAYS
|
||||
ChronoUnit DECADES
|
||||
ChronoUnit ERAS
|
||||
ChronoUnit FOREVER
|
||||
ChronoUnit HALF_DAYS
|
||||
ChronoUnit HOURS
|
||||
ChronoUnit MICROS
|
||||
ChronoUnit MILLENNIA
|
||||
ChronoUnit MILLIS
|
||||
ChronoUnit MINUTES
|
||||
ChronoUnit MONTHS
|
||||
ChronoUnit NANOS
|
||||
ChronoUnit SECONDS
|
||||
ChronoUnit WEEKS
|
||||
ChronoUnit YEARS
|
||||
ChronoUnit valueOf(String)
|
||||
ChronoUnit[] values()
|
||||
}
|
||||
|
||||
#### Exceptions
|
||||
|
||||
class UnsupportedTemporalTypeException -> java.time.temporal.UnsupportedTemporalTypeException extends DateTimeException,RuntimeException,Exception,Object {
|
||||
UnsupportedTemporalTypeException <init>(String)
|
||||
}
|
@ -0,0 +1,643 @@
|
||||
#
|
||||
# Licensed to Elasticsearch under one or more contributor
|
||||
# license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright
|
||||
# ownership. Elasticsearch licenses this file to you under
|
||||
# the Apache License, Version 2.0 (the "License"); you may
|
||||
# not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
#
|
||||
|
||||
#
|
||||
# Painless definition file. This defines the hierarchy of classes,
|
||||
# what methods and fields they have, etc.
|
||||
#
|
||||
|
||||
#### Classes
|
||||
|
||||
class Clock -> java.time.Clock extends Object {
|
||||
Clock fixed(Instant,ZoneId)
|
||||
ZoneId getZone()
|
||||
Instant instant()
|
||||
long millis()
|
||||
Clock offset(Clock,Duration)
|
||||
Clock system(ZoneId)
|
||||
Clock systemDefaultZone()
|
||||
Clock systemUTC()
|
||||
Clock tick(Clock,Duration)
|
||||
Clock tickMinutes(ZoneId)
|
||||
Clock tickSeconds(ZoneId)
|
||||
Clock withZone(ZoneId)
|
||||
}
|
||||
|
||||
class Duration -> java.time.Duration extends Comparable,TemporalAmount,Object {
|
||||
Duration ZERO
|
||||
Duration abs()
|
||||
Duration between(Temporal,Temporal)
|
||||
Duration dividedBy(long)
|
||||
Duration from(TemporalAmount)
|
||||
int getNano()
|
||||
long getSeconds()
|
||||
boolean isNegative()
|
||||
boolean isZero()
|
||||
Duration minus(Duration)
|
||||
Duration minus(long,TemporalUnit)
|
||||
Duration minusDays(long)
|
||||
Duration minusHours(long)
|
||||
Duration minusMinutes(long)
|
||||
Duration minusSeconds(long)
|
||||
Duration minusMillis(long)
|
||||
Duration minusNanos(long)
|
||||
Duration multipliedBy(long)
|
||||
Duration negated()
|
||||
Duration of(long,TemporalUnit)
|
||||
Duration ofDays(long)
|
||||
Duration ofHours(long)
|
||||
Duration ofMillis(long)
|
||||
Duration ofMinutes(long)
|
||||
Duration ofNanos(long)
|
||||
Duration ofSeconds(long)
|
||||
Duration ofSeconds(long,long)
|
||||
Duration parse(CharSequence)
|
||||
Duration plus(Duration)
|
||||
Duration plus(long,TemporalUnit)
|
||||
Duration plusDays(long)
|
||||
Duration plusHours(long)
|
||||
Duration plusMinutes(long)
|
||||
Duration plusSeconds(long)
|
||||
Duration plusMillis(long)
|
||||
Duration plusNanos(long)
|
||||
long toDays()
|
||||
long toHours()
|
||||
long toMinutes()
|
||||
long toMillis()
|
||||
long toNanos()
|
||||
Duration withSeconds(long)
|
||||
Duration withNanos(int)
|
||||
}
|
||||
|
||||
class Instant -> java.time.Instant extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
Instant EPOCH
|
||||
Instant MAX
|
||||
Instant MIN
|
||||
OffsetDateTime atOffset(ZoneOffset)
|
||||
ZonedDateTime atZone(ZoneId)
|
||||
Instant from(TemporalAccessor)
|
||||
long getEpochSecond()
|
||||
int getNano()
|
||||
boolean isAfter(Instant)
|
||||
boolean isBefore(Instant)
|
||||
Instant minus(TemporalAmount)
|
||||
Instant minus(long,TemporalUnit)
|
||||
Instant minusMillis(long)
|
||||
Instant minusNanos(long)
|
||||
Instant minusSeconds(long)
|
||||
Instant now()
|
||||
Instant now(Clock)
|
||||
Instant ofEpochSecond(long)
|
||||
Instant ofEpochSecond(long,long)
|
||||
Instant ofEpochMilli(long)
|
||||
Instant parse(CharSequence)
|
||||
Instant plus(TemporalAmount)
|
||||
Instant plus(long,TemporalUnit)
|
||||
Instant plusMillis(long)
|
||||
Instant plusNanos(long)
|
||||
Instant plusSeconds(long)
|
||||
long toEpochMilli()
|
||||
Instant truncatedTo(TemporalUnit)
|
||||
Instant with(TemporalAdjuster)
|
||||
Instant with(TemporalField,long)
|
||||
}
|
||||
|
||||
class LocalDate -> java.time.LocalDate extends Comparable,ChronoLocalDate,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
LocalDate MAX
|
||||
LocalDate MIN
|
||||
LocalDateTime atStartOfDay()
|
||||
ZonedDateTime atStartOfDay(ZoneId)
|
||||
LocalDateTime atTime(LocalTime)
|
||||
LocalDateTime atTime(int,int)
|
||||
LocalDateTime atTime(int,int,int)
|
||||
LocalDateTime atTime(int,int,int,int)
|
||||
LocalDate from(TemporalAccessor)
|
||||
IsoChronology getChronology()
|
||||
int getDayOfMonth()
|
||||
DayOfWeek getDayOfWeek()
|
||||
int getDayOfYear()
|
||||
Month getMonth()
|
||||
int getMonthValue()
|
||||
int getYear()
|
||||
LocalDate minus(TemporalAmount)
|
||||
LocalDate minus(long,TemporalUnit)
|
||||
LocalDate minusYears(long)
|
||||
LocalDate minusMonths(long)
|
||||
LocalDate minusWeeks(long)
|
||||
LocalDate minusDays(long)
|
||||
LocalDate now()
|
||||
LocalDate now(ZoneId)
|
||||
LocalDate of(int,int,int)
|
||||
LocalDate ofYearDay(int,int)
|
||||
LocalDate ofEpochDay(long)
|
||||
LocalDate parse(CharSequence)
|
||||
LocalDate parse(CharSequence,DateTimeFormatter)
|
||||
LocalDate plus(TemporalAmount)
|
||||
LocalDate plus(long,TemporalUnit)
|
||||
LocalDate plusYears(long)
|
||||
LocalDate plusMonths(long)
|
||||
LocalDate plusWeeks(long)
|
||||
LocalDate plusDays(long)
|
||||
LocalDate with(TemporalAdjuster)
|
||||
LocalDate with(TemporalField,long)
|
||||
LocalDate withDayOfMonth(int)
|
||||
LocalDate withDayOfYear(int)
|
||||
LocalDate withMonth(int)
|
||||
LocalDate withYear(int)
|
||||
}
|
||||
|
||||
class LocalDateTime -> java.time.LocalDateTime extends Comparable,ChronoLocalDateTime,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
LocalDateTime MIN
|
||||
LocalDateTime MAX
|
||||
OffsetDateTime atOffset(ZoneOffset)
|
||||
ZonedDateTime atZone(ZoneId)
|
||||
LocalDateTime from(TemporalAccessor)
|
||||
int getDayOfMonth()
|
||||
DayOfWeek getDayOfWeek()
|
||||
int getDayOfYear()
|
||||
int getHour()
|
||||
int getMinute()
|
||||
Month getMonth()
|
||||
int getMonthValue()
|
||||
int getNano()
|
||||
int getSecond()
|
||||
int getYear()
|
||||
LocalDateTime minus(TemporalAmount)
|
||||
LocalDateTime minus(long,TemporalUnit)
|
||||
LocalDateTime minusDays(long)
|
||||
LocalDateTime minusHours(long)
|
||||
LocalDateTime minusMinutes(long)
|
||||
LocalDateTime minusMonths(long)
|
||||
LocalDateTime minusNanos(long)
|
||||
LocalDateTime minusSeconds(long)
|
||||
LocalDateTime minusWeeks(long)
|
||||
LocalDateTime minusYears(long)
|
||||
LocalDateTime now()
|
||||
LocalDateTime now(ZoneId)
|
||||
LocalDateTime of(LocalDate,LocalTime)
|
||||
LocalDateTime of(int,int,int,int,int)
|
||||
LocalDateTime of(int,int,int,int,int,int)
|
||||
LocalDateTime of(int,int,int,int,int,int,int)
|
||||
LocalDateTime ofInstant(Instant,ZoneId)
|
||||
LocalDateTime ofEpochSecond(long,int,ZoneOffset)
|
||||
LocalDateTime parse(CharSequence)
|
||||
LocalDateTime parse(CharSequence,DateTimeFormatter)
|
||||
LocalDateTime plus(TemporalAmount)
|
||||
LocalDateTime plus(long,TemporalUnit)
|
||||
LocalDateTime plusDays(long)
|
||||
LocalDateTime plusHours(long)
|
||||
LocalDateTime plusMinutes(long)
|
||||
LocalDateTime plusMonths(long)
|
||||
LocalDateTime plusNanos(long)
|
||||
LocalDateTime plusSeconds(long)
|
||||
LocalDateTime plusWeeks(long)
|
||||
LocalDateTime plusYears(long)
|
||||
LocalDateTime truncatedTo(TemporalUnit)
|
||||
LocalDateTime with(TemporalAdjuster)
|
||||
LocalDateTime with(TemporalField,long)
|
||||
LocalDateTime withDayOfMonth(int)
|
||||
LocalDateTime withDayOfYear(int)
|
||||
LocalDateTime withHour(int)
|
||||
LocalDateTime withMinute(int)
|
||||
LocalDateTime withMonth(int)
|
||||
LocalDateTime withSecond(int)
|
||||
LocalDateTime withYear(int)
|
||||
}
|
||||
|
||||
class LocalTime -> java.time.LocalTime extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
LocalTime MAX
|
||||
LocalTime MIDNIGHT
|
||||
LocalTime MIN
|
||||
LocalTime NOON
|
||||
LocalDateTime atDate(LocalDate)
|
||||
OffsetTime atOffset(ZoneOffset)
|
||||
String format(DateTimeFormatter)
|
||||
LocalTime from(TemporalAccessor)
|
||||
int getHour()
|
||||
int getMinute()
|
||||
int getNano()
|
||||
int getSecond()
|
||||
boolean isAfter(LocalTime)
|
||||
boolean isBefore(LocalTime)
|
||||
LocalTime minus(TemporalAmount)
|
||||
LocalTime minus(long,TemporalUnit)
|
||||
LocalTime minusHours(long)
|
||||
LocalTime minusMinutes(long)
|
||||
LocalTime minusNanos(long)
|
||||
LocalTime minusSeconds(long)
|
||||
LocalTime now()
|
||||
LocalTime now(ZoneId)
|
||||
LocalTime of(int,int)
|
||||
LocalTime of(int,int,int)
|
||||
LocalTime of(int,int,int,int)
|
||||
LocalTime ofNanoOfDay(long)
|
||||
LocalTime ofSecondOfDay(long)
|
||||
LocalTime parse(CharSequence)
|
||||
LocalTime parse(CharSequence,DateTimeFormatter)
|
||||
LocalTime plus(TemporalAmount)
|
||||
LocalTime plus(long,TemporalUnit)
|
||||
LocalTime plusHours(long)
|
||||
LocalTime plusMinutes(long)
|
||||
LocalTime plusNanos(long)
|
||||
LocalTime plusSeconds(long)
|
||||
long toNanoOfDay()
|
||||
int toSecondOfDay()
|
||||
LocalTime truncatedTo(TemporalUnit)
|
||||
LocalTime with(TemporalAdjuster)
|
||||
LocalTime with(TemporalField,long)
|
||||
LocalTime withHour(int)
|
||||
LocalTime withMinute(int)
|
||||
LocalTime withNano(int)
|
||||
LocalTime withSecond(int)
|
||||
}
|
||||
|
||||
class MonthDay -> java.time.MonthDay extends Comparable,TemporalAccessor,TemporalAdjuster,Object {
|
||||
LocalDate atYear(int)
|
||||
String format(DateTimeFormatter)
|
||||
MonthDay from(TemporalAccessor)
|
||||
int getMonthValue()
|
||||
Month getMonth()
|
||||
int getDayOfMonth()
|
||||
boolean isAfter(MonthDay)
|
||||
boolean isBefore(MonthDay)
|
||||
boolean isValidYear(int)
|
||||
MonthDay now()
|
||||
MonthDay now(ZoneId)
|
||||
MonthDay of(int,int)
|
||||
MonthDay parse(CharSequence)
|
||||
MonthDay parse(CharSequence,DateTimeFormatter)
|
||||
MonthDay with(Month)
|
||||
MonthDay withDayOfMonth(int)
|
||||
MonthDay withMonth(int)
|
||||
}
|
||||
|
||||
class OffsetDateTime -> java.time.OffsetDateTime extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
OffsetDateTime MAX
|
||||
OffsetDateTime MIN
|
||||
ZonedDateTime atZoneSameInstant(ZoneId)
|
||||
ZonedDateTime atZoneSimilarLocal(ZoneId)
|
||||
String format(DateTimeFormatter)
|
||||
OffsetDateTime from(TemporalAccessor)
|
||||
int getDayOfMonth()
|
||||
DayOfWeek getDayOfWeek()
|
||||
int getDayOfYear()
|
||||
int getHour()
|
||||
int getMinute()
|
||||
Month getMonth()
|
||||
int getMonthValue()
|
||||
int getNano()
|
||||
ZoneOffset getOffset()
|
||||
int getSecond()
|
||||
int getYear()
|
||||
boolean isAfter(OffsetDateTime)
|
||||
boolean isBefore(OffsetDateTime)
|
||||
boolean isEqual(OffsetDateTime)
|
||||
OffsetDateTime minus(TemporalAmount)
|
||||
OffsetDateTime minus(long,TemporalUnit)
|
||||
OffsetDateTime minusYears(long)
|
||||
OffsetDateTime minusMonths(long)
|
||||
OffsetDateTime minusWeeks(long)
|
||||
OffsetDateTime minusDays(long)
|
||||
OffsetDateTime minusHours(long)
|
||||
OffsetDateTime minusMinutes(long)
|
||||
OffsetDateTime minusSeconds(long)
|
||||
OffsetDateTime minusNanos(long)
|
||||
OffsetDateTime now()
|
||||
OffsetDateTime now(ZoneId)
|
||||
OffsetDateTime of(LocalDate,LocalTime,ZoneOffset)
|
||||
OffsetDateTime of(LocalDateTime,ZoneOffset)
|
||||
OffsetDateTime of(int,int,int,int,int,int,int,ZoneOffset)
|
||||
OffsetDateTime ofInstant(Instant,ZoneId)
|
||||
OffsetDateTime parse(CharSequence)
|
||||
OffsetDateTime parse(CharSequence,DateTimeFormatter)
|
||||
OffsetDateTime plus(TemporalAmount)
|
||||
OffsetDateTime plus(long,TemporalUnit)
|
||||
OffsetDateTime plusYears(long)
|
||||
OffsetDateTime plusMonths(long)
|
||||
OffsetDateTime plusWeeks(long)
|
||||
OffsetDateTime plusDays(long)
|
||||
OffsetDateTime plusHours(long)
|
||||
OffsetDateTime plusMinutes(long)
|
||||
OffsetDateTime plusSeconds(long)
|
||||
OffsetDateTime plusNanos(long)
|
||||
Comparator timeLineOrder()
|
||||
long toEpochSecond()
|
||||
Instant toInstant()
|
||||
LocalDate toLocalDate()
|
||||
LocalDateTime toLocalDateTime()
|
||||
LocalTime toLocalTime()
|
||||
OffsetTime toOffsetTime()
|
||||
ZonedDateTime toZonedDateTime()
|
||||
OffsetDateTime truncatedTo(TemporalUnit)
|
||||
OffsetDateTime with(TemporalAdjuster)
|
||||
OffsetDateTime with(TemporalField,long)
|
||||
OffsetDateTime withDayOfMonth(int)
|
||||
OffsetDateTime withDayOfYear(int)
|
||||
OffsetDateTime withHour(int)
|
||||
OffsetDateTime withMinute(int)
|
||||
OffsetDateTime withMonth(int)
|
||||
OffsetDateTime withNano(int)
|
||||
OffsetDateTime withSecond(int)
|
||||
OffsetDateTime withYear(int)
|
||||
OffsetDateTime withOffsetSameLocal(ZoneOffset)
|
||||
OffsetDateTime withOffsetSameInstant(ZoneOffset)
|
||||
}
|
||||
|
||||
class OffsetTime -> java.time.OffsetTime extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
OffsetTime MAX
|
||||
OffsetTime MIN
|
||||
String format(DateTimeFormatter)
|
||||
OffsetTime from(TemporalAccessor)
|
||||
int getHour()
|
||||
int getMinute()
|
||||
ZoneOffset getOffset()
|
||||
int getSecond()
|
||||
int getNano()
|
||||
boolean isAfter(OffsetTime)
|
||||
boolean isBefore(OffsetTime)
|
||||
boolean isEqual(OffsetTime)
|
||||
OffsetTime now()
|
||||
OffsetTime now(ZoneId)
|
||||
OffsetTime of(LocalTime,ZoneOffset)
|
||||
OffsetTime of(int,int,int,int,ZoneOffset)
|
||||
OffsetTime ofInstant(Instant,ZoneId)
|
||||
OffsetTime plus(TemporalAmount)
|
||||
OffsetTime plus(long,TemporalUnit)
|
||||
OffsetTime plusHours(long)
|
||||
OffsetTime plusMinutes(long)
|
||||
OffsetTime plusSeconds(long)
|
||||
OffsetTime plusNanos(long)
|
||||
OffsetTime minus(TemporalAmount)
|
||||
OffsetTime minus(long,TemporalUnit)
|
||||
OffsetTime minusHours(long)
|
||||
OffsetTime minusMinutes(long)
|
||||
OffsetTime minusSeconds(long)
|
||||
OffsetTime minusNanos(long)
|
||||
OffsetTime parse(CharSequence)
|
||||
OffsetTime parse(CharSequence,DateTimeFormatter)
|
||||
LocalTime toLocalTime()
|
||||
OffsetTime truncatedTo(TemporalUnit)
|
||||
OffsetTime with(TemporalAdjuster)
|
||||
OffsetTime with(TemporalField,long)
|
||||
OffsetTime withHour(int)
|
||||
OffsetTime withMinute(int)
|
||||
OffsetTime withNano(int)
|
||||
OffsetTime withOffsetSameLocal(ZoneOffset)
|
||||
OffsetTime withOffsetSameInstant(ZoneOffset)
|
||||
OffsetTime withSecond(int)
|
||||
}
|
||||
|
||||
class Period -> java.time.Period extends ChronoPeriod,TemporalAmount,Object {
|
||||
Period ZERO
|
||||
Period between(LocalDate,LocalDate)
|
||||
Period from(TemporalAmount)
|
||||
IsoChronology getChronology()
|
||||
int getDays()
|
||||
int getMonths()
|
||||
int getYears()
|
||||
Period of(int,int,int)
|
||||
Period ofYears(int)
|
||||
Period ofMonths(int)
|
||||
Period ofWeeks(int)
|
||||
Period ofDays(int)
|
||||
Period parse(CharSequence)
|
||||
Period plus(TemporalAmount)
|
||||
Period plusYears(long)
|
||||
Period plusMonths(long)
|
||||
Period plusDays(long)
|
||||
Period minus(TemporalAmount)
|
||||
Period minusYears(long)
|
||||
Period minusMonths(long)
|
||||
Period minusDays(long)
|
||||
Period multipliedBy(int)
|
||||
Period negated()
|
||||
Period normalized()
|
||||
long toTotalMonths()
|
||||
Period withDays(int)
|
||||
Period withMonths(int)
|
||||
Period withYears(int)
|
||||
}
|
||||
|
||||
class Year -> java.time.Year extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
int MAX_VALUE
|
||||
int MIN_VALUE
|
||||
LocalDate atDay(int)
|
||||
YearMonth atMonth(int)
|
||||
LocalDate atMonthDay(MonthDay)
|
||||
String format(DateTimeFormatter)
|
||||
Year from(TemporalAccessor)
|
||||
int getValue()
|
||||
boolean isAfter(Year)
|
||||
boolean isLeap()
|
||||
boolean isLeap(long)
|
||||
boolean isValidMonthDay(MonthDay)
|
||||
int length()
|
||||
Year minus(TemporalAmount)
|
||||
Year minus(long,TemporalUnit)
|
||||
Year minusYears(long)
|
||||
Year now()
|
||||
Year now(ZoneId)
|
||||
Year of(int)
|
||||
Year parse(CharSequence)
|
||||
Year parse(CharSequence,DateTimeFormatter)
|
||||
Year plus(TemporalAmount)
|
||||
Year plus(long,TemporalUnit)
|
||||
Year plusYears(long)
|
||||
Year with(TemporalAdjuster)
|
||||
Year with(TemporalField,long)
|
||||
}
|
||||
|
||||
class YearMonth -> java.time.YearMonth extends Comparable,Temporal,TemporalAccessor,TemporalAdjuster,Object {
|
||||
LocalDate atDay(int)
|
||||
LocalDate atEndOfMonth()
|
||||
String format(DateTimeFormatter)
|
||||
YearMonth from(TemporalAccessor)
|
||||
Month getMonth()
|
||||
int getMonthValue()
|
||||
int getYear()
|
||||
boolean isAfter(YearMonth)
|
||||
boolean isBefore(YearMonth)
|
||||
boolean isLeapYear()
|
||||
boolean isValidDay(int)
|
||||
int lengthOfMonth()
|
||||
int lengthOfYear()
|
||||
YearMonth minus(TemporalAmount)
|
||||
YearMonth minus(long,TemporalUnit)
|
||||
YearMonth minusYears(long)
|
||||
YearMonth minusMonths(long)
|
||||
YearMonth now()
|
||||
YearMonth now(ZoneId)
|
||||
YearMonth of(int,int)
|
||||
YearMonth parse(CharSequence)
|
||||
YearMonth parse(CharSequence,DateTimeFormatter)
|
||||
YearMonth plus(TemporalAmount)
|
||||
YearMonth plus(long,TemporalUnit)
|
||||
YearMonth plusYears(long)
|
||||
YearMonth plusMonths(long)
|
||||
YearMonth with(TemporalAdjuster)
|
||||
YearMonth with(TemporalField,long)
|
||||
YearMonth withYear(int)
|
||||
YearMonth withMonth(int)
|
||||
}
|
||||
|
||||
class ZonedDateTime -> java.time.ZonedDateTime extends Comparable,ChronoZonedDateTime,Temporal,TemporalAccessor,Object {
|
||||
int getDayOfMonth()
|
||||
DayOfWeek getDayOfWeek()
|
||||
int getDayOfYear()
|
||||
int getHour()
|
||||
LocalDate toLocalDate()
|
||||
LocalDateTime toLocalDateTime()
|
||||
int getMinute()
|
||||
Month getMonth()
|
||||
int getMonthValue()
|
||||
int getNano()
|
||||
int getSecond()
|
||||
int getYear()
|
||||
ZonedDateTime from(TemporalAccessor)
|
||||
ZonedDateTime minus(TemporalAmount)
|
||||
ZonedDateTime minus(long,TemporalUnit)
|
||||
ZonedDateTime minusYears(long)
|
||||
ZonedDateTime minusMonths(long)
|
||||
ZonedDateTime minusWeeks(long)
|
||||
ZonedDateTime minusDays(long)
|
||||
ZonedDateTime minusHours(long)
|
||||
ZonedDateTime minusMinutes(long)
|
||||
ZonedDateTime minusSeconds(long)
|
||||
ZonedDateTime minusNanos(long)
|
||||
ZonedDateTime now()
|
||||
ZonedDateTime now(ZoneId)
|
||||
ZonedDateTime of(LocalDate,LocalTime,ZoneId)
|
||||
ZonedDateTime of(LocalDateTime,ZoneId)
|
||||
ZonedDateTime of(int,int,int,int,int,int,int,ZoneId)
|
||||
ZonedDateTime ofInstant(Instant,ZoneId)
|
||||
ZonedDateTime ofInstant(LocalDateTime,ZoneOffset,ZoneId)
|
||||
ZonedDateTime ofLocal(LocalDateTime,ZoneId,ZoneOffset)
|
||||
ZonedDateTime ofStrict(LocalDateTime,ZoneOffset,ZoneId)
|
||||
ZonedDateTime parse(CharSequence)
|
||||
ZonedDateTime parse(CharSequence,DateTimeFormatter)
|
||||
ZonedDateTime plus(TemporalAmount)
|
||||
ZonedDateTime plus(long,TemporalUnit)
|
||||
ZonedDateTime plusDays(long)
|
||||
ZonedDateTime plusHours(long)
|
||||
ZonedDateTime plusMinutes(long)
|
||||
ZonedDateTime plusMonths(long)
|
||||
ZonedDateTime plusNanos(long)
|
||||
ZonedDateTime plusSeconds(long)
|
||||
ZonedDateTime plusWeeks(long)
|
||||
ZonedDateTime plusYears(long)
|
||||
OffsetDateTime toOffsetDateTime()
|
||||
ZonedDateTime truncatedTo(TemporalUnit)
|
||||
ZonedDateTime with(TemporalAdjuster)
|
||||
ZonedDateTime with(TemporalField,long)
|
||||
ZonedDateTime withDayOfMonth(int)
|
||||
ZonedDateTime withDayOfYear(int)
|
||||
ZonedDateTime withEarlierOffsetAtOverlap()
|
||||
ZonedDateTime withFixedOffsetZone()
|
||||
ZonedDateTime withHour(int)
|
||||
ZonedDateTime withLaterOffsetAtOverlap()
|
||||
ZonedDateTime withMinute(int)
|
||||
ZonedDateTime withMonth(int)
|
||||
ZonedDateTime withNano(int)
|
||||
ZonedDateTime withSecond(int)
|
||||
ZonedDateTime withYear(int)
|
||||
ZonedDateTime withZoneSameLocal(ZoneId)
|
||||
ZonedDateTime withZoneSameInstant(ZoneId)
|
||||
}
|
||||
|
||||
class ZoneId -> java.time.ZoneId extends Object {
|
||||
Map SHORT_IDS
|
||||
Set getAvailableZoneIds()
|
||||
ZoneId of(String)
|
||||
ZoneId of(String,Map)
|
||||
ZoneId ofOffset(String,ZoneOffset)
|
||||
ZoneId from(TemporalAccessor)
|
||||
String getId()
|
||||
String getDisplayName(TextStyle,Locale)
|
||||
ZoneId normalized()
|
||||
ZoneId systemDefault()
|
||||
ZoneRules getRules()
|
||||
}
|
||||
|
||||
class ZoneOffset -> java.time.ZoneOffset extends ZoneId,Object {
|
||||
ZoneOffset MAX
|
||||
ZoneOffset MIN
|
||||
ZoneOffset UTC
|
||||
ZoneOffset from(TemporalAccessor)
|
||||
int getTotalSeconds()
|
||||
ZoneOffset of(String)
|
||||
ZoneOffset ofHours(int)
|
||||
ZoneOffset ofHoursMinutes(int,int)
|
||||
ZoneOffset ofHoursMinutesSeconds(int,int,int)
|
||||
ZoneOffset ofTotalSeconds(int)
|
||||
}
|
||||
|
||||
#### Enums
|
||||
|
||||
class DayOfWeek -> java.time.DayOfWeek extends Enum,Comparable,TemporalAccessor,TemporalAdjuster,Object {
|
||||
DayOfWeek FRIDAY
|
||||
DayOfWeek MONDAY
|
||||
DayOfWeek SATURDAY
|
||||
DayOfWeek SUNDAY
|
||||
DayOfWeek THURSDAY
|
||||
DayOfWeek TUESDAY
|
||||
DayOfWeek WEDNESDAY
|
||||
DayOfWeek of(int)
|
||||
DayOfWeek from(TemporalAccessor)
|
||||
int getValue()
|
||||
String getDisplayName(TextStyle,Locale)
|
||||
DayOfWeek minus(long)
|
||||
DayOfWeek plus(long)
|
||||
DayOfWeek valueOf(String)
|
||||
DayOfWeek[] values()
|
||||
}
|
||||
|
||||
class Month -> java.time.Month extends Enum,Comparable,TemporalAccessor,TemporalAdjuster,Object {
|
||||
Month APRIL
|
||||
Month AUGUST
|
||||
Month DECEMBER
|
||||
Month FEBRUARY
|
||||
Month JANUARY
|
||||
Month JULY
|
||||
Month JUNE
|
||||
Month MARCH
|
||||
Month MAY
|
||||
Month NOVEMBER
|
||||
Month OCTOBER
|
||||
Month SEPTEMBER
|
||||
Month from(TemporalAccessor)
|
||||
int firstDayOfYear(boolean)
|
||||
Month firstMonthOfQuarter()
|
||||
int getValue()
|
||||
String getDisplayName(TextStyle,Locale)
|
||||
int length(boolean)
|
||||
int maxLength()
|
||||
int minLength()
|
||||
Month minus(long)
|
||||
Month of(int)
|
||||
Month plus(long)
|
||||
Month valueOf(String)
|
||||
Month[] values()
|
||||
}
|
||||
|
||||
#### Exceptions
|
||||
|
||||
class DateTimeException -> java.time.DateTimeException extends RuntimeException,Exception,Object {
|
||||
DateTimeException <init>(String)
|
||||
}
|
||||
|
93
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.zone.txt
Normal file
93
modules/lang-painless/src/main/resources/org/elasticsearch/painless/java.time.zone.txt
Normal file
@ -0,0 +1,93 @@
|
||||
#
|
||||
# Licensed to Elasticsearch under one or more contributor
|
||||
# license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright
|
||||
# ownership. Elasticsearch licenses this file to you under
|
||||
# the Apache License, Version 2.0 (the "License"); you may
|
||||
# not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
#
|
||||
|
||||
#
|
||||
# Painless definition file. This defines the hierarchy of classes,
|
||||
# what methods and fields they have, etc.
|
||||
#
|
||||
|
||||
#### Classes
|
||||
|
||||
class ZoneOffsetTransition -> java.time.zone.ZoneOffsetTransition extends Comparable,Object {
|
||||
LocalDateTime getDateTimeAfter()
|
||||
LocalDateTime getDateTimeBefore()
|
||||
Duration getDuration()
|
||||
Instant getInstant()
|
||||
ZoneOffset getOffsetAfter()
|
||||
ZoneOffset getOffsetBefore()
|
||||
boolean isGap()
|
||||
boolean isOverlap()
|
||||
boolean isValidOffset(ZoneOffset)
|
||||
ZoneOffsetTransition of(LocalDateTime,ZoneOffset,ZoneOffset)
|
||||
long toEpochSecond()
|
||||
}
|
||||
|
||||
class ZoneOffsetTransitionRule -> java.time.zone.ZoneOffsetTransitionRule extends Object {
|
||||
ZoneOffsetTransition createTransition(int)
|
||||
int getDayOfMonthIndicator()
|
||||
DayOfWeek getDayOfWeek()
|
||||
LocalTime getLocalTime()
|
||||
Month getMonth()
|
||||
ZoneOffset getOffsetAfter()
|
||||
ZoneOffset getOffsetBefore()
|
||||
ZoneOffset getStandardOffset()
|
||||
ZoneOffsetTransitionRule.TimeDefinition getTimeDefinition()
|
||||
boolean isMidnightEndOfDay()
|
||||
ZoneOffsetTransitionRule of(Month,int,DayOfWeek,LocalTime,boolean,ZoneOffsetTransitionRule.TimeDefinition,ZoneOffset,ZoneOffset,ZoneOffset)
|
||||
}
|
||||
|
||||
class ZoneRules -> java.time.zone.ZoneRules extends Object {
|
||||
Duration getDaylightSavings(Instant)
|
||||
ZoneOffset getOffset(Instant)
|
||||
ZoneOffset getStandardOffset(Instant)
|
||||
ZoneOffsetTransition getTransition(LocalDateTime)
|
||||
List getTransitionRules()
|
||||
List getTransitions()
|
||||
List getValidOffsets(LocalDateTime)
|
||||
boolean isDaylightSavings(Instant)
|
||||
boolean isFixedOffset()
|
||||
boolean isValidOffset(LocalDateTime,ZoneOffset)
|
||||
ZoneOffsetTransition nextTransition(Instant)
|
||||
ZoneRules of(ZoneOffset)
|
||||
ZoneRules of(ZoneOffset,ZoneOffset,List,List,List)
|
||||
ZoneOffsetTransition previousTransition(Instant)
|
||||
}
|
||||
|
||||
class ZoneRulesProvider -> java.time.zone.ZoneRulesProvider extends Object {
|
||||
Set getAvailableZoneIds()
|
||||
ZoneRules getRules(String,boolean)
|
||||
NavigableMap getVersions(String)
|
||||
}
|
||||
|
||||
#### Enums
|
||||
|
||||
class ZoneOffsetTransitionRule.TimeDefinition -> java.time.zone.ZoneOffsetTransitionRule$TimeDefinition extends Enum,Comparable,Object {
|
||||
ZoneOffsetTransitionRule.TimeDefinition STANDARD
|
||||
ZoneOffsetTransitionRule.TimeDefinition UTC
|
||||
ZoneOffsetTransitionRule.TimeDefinition WALL
|
||||
LocalDateTime createDateTime(LocalDateTime,ZoneOffset,ZoneOffset)
|
||||
ZoneOffsetTransitionRule.TimeDefinition valueOf(String)
|
||||
ZoneOffsetTransitionRule.TimeDefinition[] values()
|
||||
}
|
||||
|
||||
#### Exceptions
|
||||
|
||||
class ZoneRulesException -> java.time.zone.ZoneRulesException extends DateTimeException,RuntimeException,Exception,Object {
|
||||
ZoneRulesException <init>(String)
|
||||
}
|
@ -491,6 +491,7 @@ class Calendar -> java.util.Calendar extends Comparable,Object {
|
||||
void setTimeInMillis(long)
|
||||
void setTimeZone(TimeZone)
|
||||
void setWeekDate(int,int,int)
|
||||
Instant toInstant()
|
||||
}
|
||||
|
||||
class Calendar.Builder -> java.util.Calendar$Builder extends Object {
|
||||
@ -583,6 +584,7 @@ class Date -> java.util.Date extends Comparable,Object {
|
||||
boolean after(Date)
|
||||
boolean before(Date)
|
||||
def clone()
|
||||
Date from(Instant)
|
||||
long getTime()
|
||||
void setTime(long)
|
||||
}
|
||||
@ -976,6 +978,8 @@ class TimeZone -> java.util.TimeZone extends Object {
|
||||
boolean hasSameRules(TimeZone)
|
||||
boolean inDaylightTime(Date)
|
||||
boolean observesDaylightTime()
|
||||
void setRawOffset(int)
|
||||
ZoneId toZoneId()
|
||||
boolean useDaylightTime()
|
||||
}
|
||||
|
||||
|
@ -23,10 +23,10 @@ import com.carrotsearch.randomizedtesting.annotations.ParametersFactory;
|
||||
import com.google.common.jimfs.Configuration;
|
||||
import com.google.common.jimfs.Jimfs;
|
||||
import org.apache.lucene.util.LuceneTestCase;
|
||||
import org.apache.lucene.util.SuppressForbidden;
|
||||
import org.elasticsearch.Version;
|
||||
import org.elasticsearch.cli.MockTerminal;
|
||||
import org.elasticsearch.cli.UserError;
|
||||
import org.elasticsearch.common.SuppressForbidden;
|
||||
import org.elasticsearch.common.collect.Tuple;
|
||||
import org.elasticsearch.common.io.PathUtils;
|
||||
import org.elasticsearch.common.io.PathUtilsForTesting;
|
||||
@ -63,7 +63,6 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
import java.util.function.Function;
|
||||
import java.util.function.Supplier;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.zip.ZipEntry;
|
||||
import java.util.zip.ZipOutputStream;
|
||||
|
Loading…
x
Reference in New Issue
Block a user