Skip to content
FoolRunning edited this page Jul 26, 2022 · 12 revisions

Description

An instance of a verse reference. Most often, this is a single verse, but it can also represent a verse bridge (i.e., a range indicated using dash) or a list (indicated using commas).

Properties

AllVerses

IReadOnlyList<IVerseRef> AllVerses

If RepresentsMultipleVerses is true, this gets an individual IVerseRef object for each verse number represented. Otherwise, it gets a single IVerseRef object which is identical to this object.


BBBCCCVVV

int BBBCCCVVV

An integer representing the first verse of this reference, with 3 digits for the book, 3 digits for the chapter, and 3 digits for the verse.


BookCode

string BookCode

The standard 3-letter book code


BookNum

int BookNum

The one-based book number based on the "standard" canonical order.


ChapterNum

int ChapterNum

The one-based chapter number.

NOTE: A verse reference cannot represent a range that crosses a chapter break.


RepresentsMultipleVerses

bool RepresentsMultipleVerses

Gets whether this reference is a bridge (range, specified with a dash) or list (specified with a comma) of verses.


VerseNum

int VerseNum

The verse number. If RepresentsMultipleVerses is true, this is the number of the first verse.


Versification

IVersification Versification

The versification system to which this reference pertains.


Methods

ChangeVersification

IVerseRef ChangeVersification(IVersification newVersification)

Gets a new IVerseRef object representing this verse reference mapped into the specified new versification.

NOTE: In the (unusual) case where a verse reference represents multiple verses and these verses are not all in the same chapter when mapped to the new versification, the object returned will be undefined. To be safe, check RepresentsMultipleVerses and call this method individually on each reference returned by AllVerses.
Plugins typically will not need to implement own version of IVersification and are generally discouraged from doing so.

Exception Condition
ParatextPluginException newVersification is null or is an an implementation of IVersification that did not come from Paratext whose IVersification.IsCustomized property returns true.

GetNextBook

IVerseRef GetNextBook(IProject project)

Gets the next book as defined in the versification of this verse reference skipping over any books not available in the specified project. Returns null if there is no next book.

NOTE: Chapter number will be one and verse number will be zero.


GetNextChapter

IVerseRef GetNextChapter(IProject project)

Gets the next chapter as defined in the versification of this verse reference skipping over any books not available in the specified project. Returns null if there is no next chapter.

NOTE: Verse number will be verse one unless it moves to the following book - in which case it will be zero.


GetNextVerse

IVerseRef GetNextVerse(IProject project)

Gets the next verse as defined in the versification of this verse reference skipping over any books not available in the specified project. Returns null if there is no next verse.

NOTE: If this verse is at the end of a book, this returns a reference representing the book introduction (1:0) of the following book.


GetPreviousBook

IVerseRef GetPreviousBook(IProject project)

Gets the previous book as defined in the versification of this verse reference skipping over any books not available in the specified project. Returns null if there is no previous book.

NOTE: Chapter and verse number will both be one.


GetPreviousChapter

IVerseRef GetPreviousChapter(IProject project)

Gets the previous chapter as defined in the versification of this verse reference skipping over any books not available in the specified project. Returns null if there is no previous chapter.

NOTE: Verse number will be verse one.


GetPreviousVerse

IVerseRef GetPreviousVerse(IProject project)

Gets the previous verse as defined in the versification of this verse reference skipping over any books not available in the specified project. Returns null if there is no previous verse.

NOTE: If this verse is at 1:1, this returns a reference representing the book introduction (i.e., any material before v. 1 of chapter 1) if you are at verse 1:1


This page is auto-generated. User edits will be lost when regenerated.

Clone this wiki locally