Update to ARC 4.1.0
[gp-arc-client-c.git] / ext / arcclientc.cpp
1 /*
2  *  arcclientc.cpp
3  *  arcclientc
4  *
5  *  Created by Tamas Jung on 4/7/10.
6  *
7  */
8
9 #include <iostream>
10 #include "arcclientc.h"
11 #include "logger.h"
12 #include "arc_libs.h"
13 #include "common_utils.h"
14
15
16 bool log_initialized = false;
17 char* initialize(){
18         
19         
20                 
21         if (! log_initialized) {
22                 log_initialized = true;
23                 setlocale(LC_ALL, "");//TBD: do we need this?
24                 static Arc::LogStream  logcerr(std::cerr);
25                 
26                 logcerr.setFormat(Arc::ShortFormat);
27                 Arc::Logger::getRootLogger().addDestination(logcerr);
28                 Arc::Logger::getRootLogger().setThreshold(Arc::DEBUG);
29                 
30         }       
31         return new_str(ARCCLIENTC_VERSION);
32 }
33
34
35