Record Class MongoColumnHandle
java.lang.Object
java.lang.Record
io.trino.plugin.mongodb.MongoColumnHandle
- Record Components:
dbRefField- Represent if the field is inside a DBRef type. The getter may return a wrong value when row type use the same field names and types as dbref.
- All Implemented Interfaces:
ColumnHandle
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbaseName()Returns the value of thebaseNamerecord component.comment()Returns the value of thecommentrecord component.booleanReturns the value of thedbRefFieldrecord component.Returns the value of thedereferenceNamesrecord component.final booleanIndicates whether some other object is "equal to" this one.org.bson.Documentfinal inthashCode()Returns a hash code value for this object.booleanhidden()Returns the value of thehiddenrecord component.booleantoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
MongoColumnHandle
public MongoColumnHandle(String baseName, List<String> dereferenceNames, Type type, boolean hidden, boolean dbRefField, Optional<String> comment) Creates an instance of aMongoColumnHandlerecord class.- Parameters:
baseName- the value for thebaseNamerecord componentdereferenceNames- the value for thedereferenceNamesrecord componenttype- the value for thetyperecord componenthidden- the value for thehiddenrecord componentdbRefField- the value for thedbRefFieldrecord componentcomment- the value for thecommentrecord component
-
-
Method Details
-
toColumnMetadata
-
getQualifiedName
-
isBaseColumn
public boolean isBaseColumn() -
getDocument
public org.bson.Document getDocument() -
toString
-
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.- Specified by:
hashCodein interfaceColumnHandle- Specified by:
hashCodein classRecord- Returns:
- a hash code value for this object
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes.- Specified by:
equalsin interfaceColumnHandle- Specified by:
equalsin classRecord- Parameters:
o- the object with which to compare- Returns:
trueif this object is the same as theoargument;falseotherwise.
-
baseName
Returns the value of thebaseNamerecord component.- Returns:
- the value of the
baseNamerecord component
-
dereferenceNames
-
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-
dbRefField
public boolean dbRefField()Returns the value of thedbRefFieldrecord component.- Returns:
- the value of the
dbRefFieldrecord component
-
comment
-