The SWORD Project  1.9.0.svnversion
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vs2osisreftxt.cpp File Reference
#include <iostream>
#include <stdio.h>
#include <versekey.h>
#include <localemgr.h>
+ Include dependency graph for vs2osisreftxt.cpp:

Go to the source code of this file.

Functions

int main (int argc, char **argv)
 

Function Documentation

int main ( int  argc,
char **  argv 
)

Definition at line 38 of file vs2osisreftxt.cpp.

38  {
39  if ((argc < 2) || (argc > 4)) {
40  fprintf(stderr, "usage: %s <\"string to parse\"> [locale_name] [test-in-set-verse]\n", *argv);
41  exit(-1);
42  }
43 
44  if (argc > 2)
46 
47  VerseKey DefaultVSKey;
48 
49  DefaultVSKey = "jas3:1";
50 
51  ListKey verses = DefaultVSKey.parseVerseList(argv[1], DefaultVSKey, true);
52 
53  std::cout << verses.getOSISRefRangeText() << "\n";
54 
55  if (argc > 3) {
56  verses.setText(argv[3]);
57  std::cout << "Verse is" << ((verses.popError()) ? " NOT" : "") << " in set.\n\n";
58  }
59 
60  return 0;
61 }
virtual void setDefaultLocaleName(const char *name)
Definition: localemgr.cpp:251
static LocaleMgr * getSystemLocaleMgr()
Definition: localemgr.cpp:54