Package org.elasticsearch.index.mapper
Record Class MapperTestCase.SyntheticSourceExample
java.lang.Object
java.lang.Record
org.elasticsearch.index.mapper.MapperTestCase.SyntheticSourceExample
- Enclosing class:
MapperTestCase
public static record MapperTestCase.SyntheticSourceExample(org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> inputValue, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> expectedForSyntheticSource, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> expectedForBlockLoader, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> mapping)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionSyntheticSourceExample(Object inputValue, Object result, Object blockLoaderResults, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping) Create an example that returns different results from doc values than from synthetic source.SyntheticSourceExample(Object inputValue, Object result, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping) SyntheticSourceExample(org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> inputValue, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> expectedForSyntheticSource, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> expectedForBlockLoader, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping) Creates an instance of aSyntheticSourceExamplerecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidbuildInput(org.elasticsearch.xcontent.XContentBuilder b) voidbuildInputArray(org.elasticsearch.xcontent.XContentBuilder b, int elementCount) final booleanIndicates whether some other object is "equal to" this one.org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> Returns the value of theexpectedForBlockLoaderrecord component.org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> Returns the value of theexpectedForSyntheticSourcerecord component.final inthashCode()Returns a hash code value for this object.org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> Returns the value of theinputValuerecord component.org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping()Returns the value of themappingrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SyntheticSourceExample
public SyntheticSourceExample(Object inputValue, Object result, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping) -
SyntheticSourceExample
public SyntheticSourceExample(Object inputValue, Object result, Object blockLoaderResults, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping) Create an example that returns different results from doc values than from synthetic source. -
SyntheticSourceExample
public SyntheticSourceExample(org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> inputValue, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> expectedForSyntheticSource, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> expectedForBlockLoader, org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder, IOException> mapping) Creates an instance of aSyntheticSourceExamplerecord class.- Parameters:
inputValue- the value for theinputValuerecord componentexpectedForSyntheticSource- the value for theexpectedForSyntheticSourcerecord componentexpectedForBlockLoader- the value for theexpectedForBlockLoaderrecord componentmapping- the value for themappingrecord component
-
-
Method Details
-
buildInput
- Throws:
IOException
-
buildInputArray
public void buildInputArray(org.elasticsearch.xcontent.XContentBuilder b, int elementCount) throws IOException - Throws:
IOException
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
inputValue
public org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> inputValue()Returns the value of theinputValuerecord component.- Returns:
- the value of the
inputValuerecord component
-
expectedForSyntheticSource
public org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> expectedForSyntheticSource()Returns the value of theexpectedForSyntheticSourcerecord component.- Returns:
- the value of the
expectedForSyntheticSourcerecord component
-
expectedForBlockLoader
public org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> expectedForBlockLoader()Returns the value of theexpectedForBlockLoaderrecord component.- Returns:
- the value of the
expectedForBlockLoaderrecord component
-
mapping
public org.elasticsearch.core.CheckedConsumer<org.elasticsearch.xcontent.XContentBuilder,IOException> mapping()Returns the value of themappingrecord component.- Returns:
- the value of the
mappingrecord component
-