source: trunk/include/fortran/RpFortranCommon.h @ 83

Last change on this file since 83 was 83, checked in by dkearney, 19 years ago
  1. More cleaning of RpUnits and RpLibrary? code
  2. added rp_result code to c++/fortran/c code
  3. added rp_children, rp_lib_node[comp,type,id] for fortran code (need to test)
  4. adjusted convert function to recognize statements as follows:

convert("5J","neV")
convert("3.12075e+28neV","J")

  1. made joules a metric unit in RpUnits.cc
  2. tested examples/app-fermi/fortran/fermi.f with new rappture library.

added units conversion.

File size: 846 bytes
Line 
1/*
2 * ----------------------------------------------------------------------
3 *  INTERFACE: Fortran Rappture Common Functions
4 *
5 *    Fortran functions common to all interfaces.
6 *
7 * ======================================================================
8 *  AUTHOR:  Derrick Kearney, Purdue University
9 *  Copyright (c) 2005
10 *  Purdue Research Foundation, West Lafayette, IN
11 * ======================================================================
12 */
13
14#include <stdlib.h>
15#include <ctype.h>
16#include <string.h>
17#include <string>
18
19#ifndef _RpFORTRAN_COMMON_H
20#define _RpFORTRAN_COMMON_H
21
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27char* null_terminate(char* inStr, int len);
28std::string null_terminate_str(const char* inStr, int len);
29void fortranify(const char* inBuff, char* retText, int retTextLen);
30
31#ifdef __cplusplus
32}
33#endif
34   
35#endif
Note: See TracBrowser for help on using the repository browser.