1   /**
2    * Distribution License:
3    * JSword is free software; you can redistribute it and/or modify it under
4    * the terms of the GNU Lesser General Public License, version 2.1 or later
5    * as published by the Free Software Foundation. This program is distributed
6    * in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
7    * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
8    * See the GNU Lesser General Public License for more details.
9    *
10   * The License is available on the internet at:
11   *       http://www.gnu.org/copyleft/lgpl.html
12   * or by writing to:
13   *      Free Software Foundation, Inc.
14   *      59 Temple Place - Suite 330
15   *      Boston, MA 02111-1307, USA
16   *
17   * Copyright: 2012
18   *     The copyright to this program is held by it's authors.
19   *
20   */
21  package org.crosswire.jsword.versification.system;
22  
23  import org.crosswire.jsword.versification.BibleBook;
24  import org.crosswire.jsword.versification.Versification;
25  
26  /**
27   * The Masoretic Text (MT) versification differs from the Leningrad Codex
28   * versification only in the placement of 1 and 2 Chronicles.
29   * The Masoretic Text puts it after Nehemiah at the end of the
30   * Old Testament, while the Leningrad Codex places them between
31   * Malachi and Psalms.
32   *
33   * @see gnu.lgpl.License for license details.<br>
34   *      The copyright to this program is held by it's authors.
35   * @author DM Smith
36   */
37  public class SystemMT extends Versification {
38      /**
39       * Build the "MT" Versification.
40       */
41      /* protected */ SystemMT() {
42          super(V11N_NAME, BOOKS_OT, BOOKS_NT, LAST_VERSE_OT, LAST_VERSE_NT);
43      }
44  
45      public static final String V11N_NAME = "MT";
46  
47      /* protected */ static final BibleBook[] BOOKS_NT = SystemDefault.BOOKS_NONE;
48      /* protected */ static final int[][] LAST_VERSE_NT = SystemDefault.LAST_VERSE_NONE;
49  
50      // Different ordering of SystemDefault.booksOT
51      /* protected */ static final BibleBook[] BOOKS_OT =
52      {
53          BibleBook.GEN,
54          BibleBook.EXOD,
55          BibleBook.LEV,
56          BibleBook.NUM,
57          BibleBook.DEUT,
58          BibleBook.JOSH,
59          BibleBook.JUDG,
60          BibleBook.SAM1,
61          BibleBook.SAM2,
62          BibleBook.KGS1,
63          BibleBook.KGS2,
64          BibleBook.ISA,
65          BibleBook.JER,
66          BibleBook.EZEK,
67          BibleBook.HOS,
68          BibleBook.JOEL,
69          BibleBook.AMOS,
70          BibleBook.OBAD,
71          BibleBook.JONAH,
72          BibleBook.MIC,
73          BibleBook.NAH,
74          BibleBook.HAB,
75          BibleBook.ZEPH,
76          BibleBook.HAG,
77          BibleBook.ZECH,
78          BibleBook.MAL,
79          BibleBook.PS,
80          BibleBook.JOB,
81          BibleBook.PROV,
82          BibleBook.RUTH,
83          BibleBook.SONG,
84          BibleBook.ECCL,
85          BibleBook.LAM,
86          BibleBook.ESTH,
87          BibleBook.DAN,
88          BibleBook.EZRA,
89          BibleBook.NEH,
90          BibleBook.CHR1,
91          BibleBook.CHR2,
92      };
93  
94      /* protected */ static final int[][] LAST_VERSE_OT =
95      {
96          // Genesis
97          {
98                 31,    25,    24,    26,    32,    22,    24,    22,    29,
99                 32,    32,    20,    18,    24,    21,    16,    27,    33,    38,
100                18,    34,    24,    20,    67,    34,    35,    46,    22,    35,
101                43,    54,    33,    20,    31,    29,    43,    36,    30,    23,
102                23,    57,    38,    34,    34,    28,    34,    31,    22,    33,
103                26,
104         },
105         // Exodus
106         {
107                22,    25,    22,    31,    23,    30,    29,    28,    35,
108                29,    10,    51,    22,    31,    27,    36,    16,    27,    25,
109                26,    37,    30,    33,    18,    40,    37,    21,    43,    46,
110                38,    18,    35,    23,    35,    35,    38,    29,    31,    43,
111                38,
112         },
113         // Leviticus
114         {
115                17,    16,    17,    35,    26,    23,    38,    36,    24,
116                20,    47,     8,    59,    57,    33,    34,    16,    30,    37,
117                27,    24,    33,    44,    23,    55,    46,    34,
118         },
119         // Numbers
120         {
121                54,    34,    51,    49,    31,    27,    89,    26,    23,
122                36,    35,    16,    33,    45,    41,    35,    28,    32,    22,
123                29,    35,    41,    30,    25,    19,    65,    23,    31,    39,
124                17,    54,    42,    56,    29,    34,    13,
125         },
126         // Deuteronomy
127         {
128                46,    37,    29,    49,    33,    25,    26,    20,    29,
129                22,    32,    31,    19,    29,    23,    22,    20,    22,    21,
130                20,    23,    29,    26,    22,    19,    19,    26,    69,    28,
131                20,    30,    52,    29,    12,
132         },
133         // Joshua
134         {
135                18,    24,    17,    24,    15,    27,    26,    35,    27,
136                43,    23,    24,    33,    15,    63,    10,    18,    28,    51,
137                 9,    45,    34,    16,    33,
138         },
139         // Judges
140         {
141                36,    23,    31,    24,    31,    40,    25,    35,    57,
142                18,    40,    15,    25,    20,    20,    31,    13,    31,    30,
143                48,    25,
144         },
145         // I Samuel
146         {
147                28,    36,    21,    22,    12,    21,    17,    22,    27,
148                27,    15,    25,    23,    52,    35,    23,    58,    30,    24,
149                42,    16,    23,    28,    23,    44,    25,    12,    25,    11,
150                31,    13,
151         },
152         // II Samuel
153         {
154                27,    32,    39,    12,    25,    23,    29,    18,    13,
155                19,    27,    31,    39,    33,    37,    23,    29,    32,    44,
156                26,    22,    51,    39,    25,
157         },
158         // I Kings
159         {
160                53,    46,    28,    20,    32,    38,    51,    66,    28,
161                29,    43,    33,    34,    31,    34,    34,    24,    46,    21,
162                43,    29,    54,
163         },
164         // II Kings
165         {
166                18,    25,    27,    44,    27,    33,    20,    29,    37,
167                36,    20,    22,    25,    29,    38,    20,    41,    37,    37,
168                21,    26,    20,    37,    20,    30,
169         },
170         // Isaiah
171         {
172                31,    22,    26,     6,    30,    13,    25,    23,    20,
173                34,    16,     6,    22,    32,     9,    14,    14,     7,    25,
174                 6,    17,    25,    18,    23,    12,    21,    13,    29,    24,
175                33,     9,    20,    24,    17,    10,    22,    38,    22,     8,
176                31,    29,    25,    28,    28,    25,    13,    15,    22,    26,
177                11,    23,    15,    12,    17,    13,    12,    21,    14,    21,
178                22,    11,    12,    19,    11,    25,    24,
179         },
180         // Jeremiah
181         {
182                19,    37,    25,    31,    31,    30,    34,    23,    25,
183                25,    23,    17,    27,    22,    21,    21,    27,    23,    15,
184                18,    14,    30,    40,    10,    38,    24,    22,    17,    32,
185                24,    40,    44,    26,    22,    19,    32,    21,    28,    18,
186                16,    18,    22,    13,    30,     5,    28,     7,    47,    39,
187                46,    64,    34,
188         },
189         // Ezekiel
190         {
191                28,    10,    27,    17,    17,    14,    27,    18,    11,
192                22,    25,    28,    23,    23,     8,    63,    24,    32,    14,
193                44,    37,    31,    49,    27,    17,    21,    36,    26,    21,
194                26,    18,    32,    33,    31,    15,    38,    28,    23,    29,
195                49,    26,    20,    27,    31,    25,    24,    23,    35,
196         },
197         // Hosea
198         {
199                 9,    25,     5,    19,    15,    11,    16,    14,    17,
200                15,    11,    15,    15,    10,
201         },
202         // Joel
203         {
204                20,    27,     5,    21,
205         },
206         // Amos
207         {
208                15,    16,    15,    13,    27,    14,    17,    14,    15,
209         },
210         // Obadiah
211         {
212                21,
213         },
214         // Jonah
215         {
216                16,    11,    10,    11,
217         },
218         // Micah
219         {
220                16,    13,    12,    14,    14,    16,    20,
221         },
222         // Nahum
223         {
224                14,    14,    19,
225         },
226         // Habakkuk
227         {
228                17,    20,    19,
229         },
230         // Zephaniah
231         {
232                18,    15,    20,
233         },
234         // Haggai
235         {
236                15,    23,
237         },
238         // Zechariah
239         {
240                17,    17,    10,    14,    11,    15,    14,    23,    17,
241                12,    17,    14,     9,    21,
242         },
243         // Malachi
244         {
245                14,    17,    24,
246         },
247         // Psalms
248         {
249                 6,    12,     9,     9,    13,    11,    18,    10,    21,
250                18,     7,     9,     6,     7,     5,    11,    15,    51,    15,
251                10,    14,    32,     6,    10,    22,    12,    14,     9,    11,
252                13,    25,    11,    22,    23,    28,    13,    40,    23,    14,
253                18,    14,    12,     5,    27,    18,    12,    10,    15,    21,
254                23,    21,    11,     7,     9,    24,    14,    12,    12,    18,
255                14,     9,    13,    12,    11,    14,    20,     8,    36,    37,
256                 6,    24,    20,    28,    23,    11,    13,    21,    72,    13,
257                20,    17,     8,    19,    13,    14,    17,     7,    19,    53,
258                17,    16,    16,     5,    23,    11,    13,    12,     9,     9,
259                 5,     8,    29,    22,    35,    45,    48,    43,    14,    31,
260                 7,    10,    10,     9,     8,    18,    19,     2,    29,   176,
261                 7,     8,     9,     4,     8,     5,     6,     5,     6,     8,
262                 8,     3,    18,     3,     3,    21,    26,     9,     8,    24,
263                14,    10,     8,    12,    15,    21,    10,    20,    14,     9,
264                 6,
265         },
266         // Job
267         {
268                22,    13,    26,    21,    27,    30,    21,    22,    35,
269                22,    20,    25,    28,    22,    35,    22,    16,    21,    29,
270                29,    34,    30,    17,    25,     6,    14,    23,    28,    25,
271                31,    40,    22,    33,    37,    16,    33,    24,    41,    30,
272                32,    26,    17,
273         },
274         // Proverbs
275         {
276                33,    22,    35,    27,    23,    35,    27,    36,    18,
277                32,    31,    28,    25,    35,    33,    33,    28,    24,    29,
278                30,    31,    29,    35,    34,    28,    28,    27,    28,    27,
279                33,    31,
280         },
281         // Ruth
282         {
283                22,    23,    18,    22,
284         },
285         // Song of Solomon
286         {
287                17,    17,    11,    16,    16,    12,    14,    14,
288         },
289         // Ecclesiastes
290         {
291                18,    26,    22,    17,    19,    12,    29,    17,    18,
292                20,    10,    14,
293         },
294         // Lamentations
295         {
296                22,    22,    66,    22,    22,
297         },
298         // Esther
299         {
300                22,    23,    15,    17,    14,    14,    10,    17,    32,
301                 3,
302         },
303         // Daniel
304         {
305                21,    49,    33,    34,    30,    29,    28,    27,    27,
306                21,    45,    13,
307         },
308         // Ezra
309         {
310                11,    70,    13,    24,    17,    22,    28,    36,    15,
311                44,
312         },
313         // Nehemiah
314         {
315                11,    20,    38,    17,    19,    19,    72,    18,    37,
316                40,    36,    47,    31,
317         },
318         // I Chronicles
319         {
320                54,    55,    24,    43,    41,    66,    40,    40,    44,
321                14,    47,    41,    14,    17,    29,    43,    27,    17,    19,
322                 8,    30,    19,    32,    31,    31,    32,    34,    21,    30,
323         },
324         // II Chronicles
325         {
326                18,    17,    17,    22,    14,    42,    22,    18,    31,
327                19,    23,    16,    23,    14,    19,    14,    19,    34,    11,
328                37,    20,    12,    21,    27,    28,    23,     9,    27,    36,
329                27,    21,    33,    25,    33,    27,    23,
330         },
331     };
332 
333     /**
334      * Serialization ID
335      */
336     private static final long serialVersionUID = -3679238882055120660L;
337 }
338