Record Class PagedTextExtraction
java.lang.Object
java.lang.Record
org.exoplatform.documents.storage.jcr.model.PagedTextExtraction
- Record Components:
file- the cache file holding the text as UTF-16BE, null without texttotalChars- the length of the texttruncated- true when the text was cut at the most characters readoutline- the file's headingsstatus-DocumentTextContent.Status.EXTRACTED, else why there is no text
public record PagedTextExtraction(Path file, long totalChars, boolean truncated, List<org.exoplatform.documents.model.DocumentOutlineEntry> outline, org.exoplatform.documents.model.DocumentTextContent.Status status)
extends Record
The text of one version of a file, as extracted to be read part by part.
-
Constructor Summary
ConstructorsConstructorDescriptionPagedTextExtraction(Path file, long totalChars, boolean truncated, List<org.exoplatform.documents.model.DocumentOutlineEntry> outline, org.exoplatform.documents.model.DocumentTextContent.Status status) Creates an instance of aPagedTextExtractionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.file()Returns the value of thefilerecord component.final inthashCode()Returns a hash code value for this object.static PagedTextExtractionnone(org.exoplatform.documents.model.DocumentTextContent.Status status) Builds the extraction of a file that gave no text.List<org.exoplatform.documents.model.DocumentOutlineEntry> outline()Returns the value of theoutlinerecord component.org.exoplatform.documents.model.DocumentTextContent.Statusstatus()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.longReturns the value of thetotalCharsrecord component.booleanReturns the value of thetruncatedrecord component.
-
Constructor Details
-
PagedTextExtraction
public PagedTextExtraction(Path file, long totalChars, boolean truncated, List<org.exoplatform.documents.model.DocumentOutlineEntry> outline, org.exoplatform.documents.model.DocumentTextContent.Status status) Creates an instance of aPagedTextExtractionrecord class.- Parameters:
file- the value for thefilerecord componenttotalChars- the value for thetotalCharsrecord componenttruncated- the value for thetruncatedrecord componentoutline- the value for theoutlinerecord componentstatus- the value for thestatusrecord component
-
-
Method Details
-
none
public static PagedTextExtraction none(org.exoplatform.documents.model.DocumentTextContent.Status status) Builds the extraction of a file that gave no text.- Parameters:
status- why- Returns:
- the extraction
-
toString
-
hashCode
-
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. -
file
-
totalChars
public long totalChars()Returns the value of thetotalCharsrecord component.- Returns:
- the value of the
totalCharsrecord component
-
truncated
-
outline
-
status
-