MBDyn-1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
mbdynFMI_config.h File Reference
#include "mbdynFMI.h"
Include dependency graph for mbdynFMI_config.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define BUFFER   1000
 

Functions

void importlogger (jm_callbacks *c, jm_string module, jm_log_level_enu_t log_level, jm_string message)
 
void setup_callbacks (jm_callbacks *callbacks)
 
int error (const char *test, int value)
 
int sumde (int x, int y)
 
std::string UncompressLocation (const char *location)
 

Macro Definition Documentation

#define BUFFER   1000

Definition at line 44 of file mbdynFMI_config.h.

Function Documentation

int error ( const char *  test,
int  value 
)

Referenced by getopt(), and if().

void importlogger ( jm_callbacks *  c,
jm_string  module,
jm_log_level_enu_t  log_level,
jm_string  message 
)

Definition at line 46 of file mbdynFMI_config.cc.

Referenced by setup_callbacks().

47 {
48 
49  printf("module = %s, log level = %d: %s\n", module, log_level, message);
50 
51 }
void setup_callbacks ( jm_callbacks *  callbacks)

Definition at line 53 of file mbdynFMI_config.cc.

References importlogger().

Referenced by ModuleFMU::ModuleFMU().

53  {
54  callbacks->malloc = malloc;
55  callbacks->calloc = calloc;
56  callbacks->realloc = realloc;
57  callbacks->free = free;
58  callbacks->logger = importlogger;
59  callbacks->log_level = jm_log_level_debug;
60  callbacks->context = 0;
61  printf("Callback Setup Done! \n");
62 }
void importlogger(jm_callbacks *c, jm_string module, jm_log_level_enu_t log_level, jm_string message)

Here is the call graph for this function:

int sumde ( int  x,
int  y 
)
std::string UncompressLocation ( const char *  location)

Definition at line 64 of file mbdynFMI_config.cc.

Referenced by ModuleFMU::ModuleFMU().

64  {
65  int length = strlen(location);
66  int i;
67 
68  for (i=length; i>0; i--){
69  if(location[i]==47){
70  break;
71  }
72  }
73 
74  std::string destination(location);
75 // char* destination = (char*) malloc(length*sizeof(char) );
76  destination.resize(i+1);
77  return destination.c_str();
78 }