Record Class Metadata
java.lang.Object
java.lang.Record
org.jweaver.crawler.internal.result.Metadata
- Record Components:
source
- the uri of the documentdepth
- the crawling depthretrievedOn
- timestamp of retrieval datetimecharacters
- a count of document characters
The Metadata record represents metadata associated with a web page. It includes information such
as the source of the page, its depth in the crawling hierarchy, the timestamp when it was
retrieved, and the number of characters in the content.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
Returns the value of thecharacters
record component.int
depth()
Returns the value of thedepth
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of theretrievedOn
record component.source()
Returns the value of thesource
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
Metadata
Creates an instance of aMetadata
record class.- Parameters:
source
- the value for thesource
record componentdepth
- the value for thedepth
record componentretrievedOn
- the value for theretrievedOn
record componentcharacters
- the value for thecharacters
record component
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
source
Returns the value of thesource
record component.- Returns:
- the value of the
source
record component
-
depth
public int depth()Returns the value of thedepth
record component.- Returns:
- the value of the
depth
record component
-
retrievedOn
Returns the value of theretrievedOn
record component.- Returns:
- the value of the
retrievedOn
record component
-
characters
public int characters()Returns the value of thecharacters
record component.- Returns:
- the value of the
characters
record component
-