Class CitationLocation

    • Method Detail

      • web

        public final WebLocation web()

        The web URL that was cited for this reference.

        Returns:
        The web URL that was cited for this reference.
      • documentChar

        public final DocumentCharLocation documentChar()

        The character-level location within the document where the cited content is found.

        Returns:
        The character-level location within the document where the cited content is found.
      • documentPage

        public final DocumentPageLocation documentPage()

        The page-level location within the document where the cited content is found.

        Returns:
        The page-level location within the document where the cited content is found.
      • documentChunk

        public final DocumentChunkLocation documentChunk()

        The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.

        Returns:
        The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.
      • searchResultLocation

        public final SearchResultLocation searchResultLocation()

        The search result location where the cited content is found, including the search result index and block positions within the content array.

        Returns:
        The search result location where the cited content is found, including the search result index and block positions within the content array.
      • hashCode

        public final int hashCode()
        Overrides:
        hashCode in class Object
      • equals

        public final boolean equals​(Object obj)
        Overrides:
        equals in class Object
      • toString

        public final String toString()
        Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
        Overrides:
        toString in class Object
      • getValueForField

        public final <T> Optional<T> getValueForField​(String fieldName,
                                                      Class<T> clazz)
      • fromWeb

        public static CitationLocation fromWeb​(WebLocation web)
        Create an instance of this class with web() initialized to the given value.

        The web URL that was cited for this reference.

        Parameters:
        web - The web URL that was cited for this reference.
      • fromWeb

        public static CitationLocation fromWeb​(Consumer<WebLocation.Builder> web)
        Create an instance of this class with web() initialized to the given value.

        The web URL that was cited for this reference.

        Parameters:
        web - The web URL that was cited for this reference.
      • fromDocumentChar

        public static CitationLocation fromDocumentChar​(DocumentCharLocation documentChar)
        Create an instance of this class with documentChar() initialized to the given value.

        The character-level location within the document where the cited content is found.

        Parameters:
        documentChar - The character-level location within the document where the cited content is found.
      • fromDocumentChar

        public static CitationLocation fromDocumentChar​(Consumer<DocumentCharLocation.Builder> documentChar)
        Create an instance of this class with documentChar() initialized to the given value.

        The character-level location within the document where the cited content is found.

        Parameters:
        documentChar - The character-level location within the document where the cited content is found.
      • fromDocumentPage

        public static CitationLocation fromDocumentPage​(DocumentPageLocation documentPage)
        Create an instance of this class with documentPage() initialized to the given value.

        The page-level location within the document where the cited content is found.

        Parameters:
        documentPage - The page-level location within the document where the cited content is found.
      • fromDocumentPage

        public static CitationLocation fromDocumentPage​(Consumer<DocumentPageLocation.Builder> documentPage)
        Create an instance of this class with documentPage() initialized to the given value.

        The page-level location within the document where the cited content is found.

        Parameters:
        documentPage - The page-level location within the document where the cited content is found.
      • fromDocumentChunk

        public static CitationLocation fromDocumentChunk​(DocumentChunkLocation documentChunk)
        Create an instance of this class with documentChunk() initialized to the given value.

        The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.

        Parameters:
        documentChunk - The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.
      • fromDocumentChunk

        public static CitationLocation fromDocumentChunk​(Consumer<DocumentChunkLocation.Builder> documentChunk)
        Create an instance of this class with documentChunk() initialized to the given value.

        The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.

        Parameters:
        documentChunk - The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.
      • fromSearchResultLocation

        public static CitationLocation fromSearchResultLocation​(SearchResultLocation searchResultLocation)
        Create an instance of this class with searchResultLocation() initialized to the given value.

        The search result location where the cited content is found, including the search result index and block positions within the content array.

        Parameters:
        searchResultLocation - The search result location where the cited content is found, including the search result index and block positions within the content array.
      • fromSearchResultLocation

        public static CitationLocation fromSearchResultLocation​(Consumer<SearchResultLocation.Builder> searchResultLocation)
        Create an instance of this class with searchResultLocation() initialized to the given value.

        The search result location where the cited content is found, including the search result index and block positions within the content array.

        Parameters:
        searchResultLocation - The search result location where the cited content is found, including the search result index and block positions within the content array.