Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages | Examples

Misc.cpp File Reference


Detailed Description

Miscellaneous utility functions (not hardware utilities).

Author:
Author
rsharo
Version:
Revision
1.3
Date:
Date
2003/11/01 21:00:16

Definition in file Misc.cpp.

#include "Misc.h"
#include <stdlib.h>
#include <string.h>

Include dependency graph for Misc.cpp:

Include dependency graph

Go to the source code of this file.

Functions

int strip (char *dest, char c, int mode)
 Strip leading and/or trailing instances of the specified character from a string.
int crstrip (char *dest)
 Strip possible multiple trailing CR/LF's at EOL.
int allocCpy (char **dest, char *src)
 Allocate and copy in one step.
int getCmdIndex (const char **cmds, const char *myCmd)
 A simple word lookup routine, converts a word to its index index number in the supplied list to make all lookups the same.


Function Documentation

int allocCpy char **  dest,
char *  src
 

Allocate and copy in one step.

Definition at line 54 of file Misc.cpp.

Referenced by CfgParse::go().

int crstrip char *  dest  ) 
 

Strip possible multiple trailing CR/LF's at EOL.

Definition at line 41 of file Misc.cpp.

Referenced by CfgParse::go().

int getCmdIndex const char **  cmds,
const char *  myCmd
 

A simple word lookup routine, converts a word to its index index number in the supplied list to make all lookups the same.

Definition at line 63 of file Misc.cpp.

Referenced by ControlMomentGyro::ControlMomentGyro(), Relay::Relay(), Thruster::Thruster(), and TiltSensor::TiltSensor().

int strip char *  dest,
char  c,
int  mode
 

Strip leading and/or trailing instances of the specified character from a string.

Definition at line 14 of file Misc.cpp.

Referenced by CfgParse::go().


Generated on Wed Sep 5 12:54:32 2007 for DSACSS Operational Code by  doxygen 1.3.9.1