#include "iochannel.hxx"
-using std::string;
-
/**
* A serial I/O class based on SGIOChannel.
*/
class SGSerial : public SGIOChannel {
- string device;
- string baud;
+ std::string device;
+ std::string baud;
SGSerialPort port;
char save_buf[ 2 * SG_IO_MAX_MSG_SIZE ];
* @param device_name name of serial device
* @param baud_rate speed of communication
*/
- SGSerial( const string& device_name, const string& baud_rate );
+ SGSerial( const std::string& device_name, const std::string& baud_rate );
/** Destructor */
~SGSerial();
#include <simgear/structure/SGReferenced.hxx>
#include <map>
-
#include <string>
-using std::string;
class SGPropertyNode;
* Constructor. Loads the interpolation table from the specified file.
* @param file name of interpolation file
*/
- SGInterpTable( const string& file );
+ SGInterpTable( const std::string& file );
/**
using std::istream;
using std::ostream;
+using std::string;
+
/**
* Condition for a single property.
*
{
public:
ExtensionSupportedExpression() {}
- ExtensionSupportedExpression(const string& extString)
+ ExtensionSupportedExpression(const std::string& extString)
: _extString(extString)
{
}
- const string& getExtensionString() { return _extString; }
- void setExtensionString(const string& extString) { _extString = extString; }
+ const std::string& getExtensionString() { return _extString; }
+ void setExtensionString(const std::string& extString) { _extString = extString; }
void eval(bool&value, const expression::Binding* b) const
{
int contextId = getOperand(0)->getValue(b);
value = isGLExtensionSupported((unsigned)contextId, _extString.c_str());
}
protected:
- string _extString;
+ std::string _extString;
};
Expression* extensionSupportedParser(const SGPropertyNode* exp,
#include <boost/scoped_array.hpp>
#include <boost/foreach.hpp>
-typedef std::map<string, osg::observer_ptr<simgear::Effect> > EffectMap;
+typedef std::map<std::string, osg::observer_ptr<simgear::Effect> > EffectMap;
static EffectMap lightEffectMap;
#define GET_COLOR_VALUE(n) \
SGLightAnimation::SGLightAnimation(const SGPropertyNode* configNode,
SGPropertyNode* modelRoot,
const osgDB::Options* options,
- const string &path, int i) :
+ const std::string &path, int i) :
SGAnimation(configNode, modelRoot),
_options(options)
{
_cutoff = getConfig()->getDoubleValue("cutoff");
_near = getConfig()->getDoubleValue("near-m");
_far = getConfig()->getDoubleValue("far-m");
- _key = path + ";" + boost::lexical_cast<string>( i );
+ _key = path + ";" + boost::lexical_cast<std::string>( i );
SGConstPropertyNode_ptr dim_factor = configNode->getChild("dim-factor");
if (dim_factor.valid()) {
public:
SGMaterialAnimation(const SGPropertyNode* configNode,
SGPropertyNode* modelRoot,
- const osgDB::Options* options,const string &path);
+ const osgDB::Options* options,const std::string &path);
virtual osg::Group* createAnimationGroup(osg::Group& parent);
virtual void install(osg::Node& node);
static SGPropertyNode_ptr makeEffectProperties(const SGPropertyNode* animProp);
if (!_found)
{
std::list<std::string>::const_iterator i;
- string info;
+ std::string info;
for (i = _objectNames.begin(); i != _objectNames.end(); ++i)
{
if (!info.empty())
SGAnimation::animate(osg::Node* node, const SGPropertyNode* configNode,
SGPropertyNode* modelRoot,
const osgDB::Options* options,
- const string &path, int i)
+ const std::string &path, int i)
{
std::string type = configNode->getStringValue("type", "none");
if (type == "alpha-test") {
static bool animate(osg::Node* node, const SGPropertyNode* configNode,
SGPropertyNode* modelRoot,
const osgDB::Options* options,
- const string &path, int i);
+ const std::string &path, int i);
protected:
void apply(osg::Node* node);
SGLightAnimation(const SGPropertyNode* configNode,
SGPropertyNode* modelRoot,
const osgDB::Options* options,
- const string &path, int i);
+ const std::string &path, int i);
virtual osg::Group* createAnimationGroup(osg::Group& parent);
virtual void install(osg::Node& node);
private:
- string _light_type;
+ std::string _light_type;
SGVec3d _position;
SGVec3d _direction;
SGVec4d _ambient;
double _cutoff;
double _near;
double _far;
- string _key;
+ std::string _key;
class UpdateCallback;
friend class UpdateCallback;
SGSharedPtr<SGExpressiond> _animationValue;
#include <vector>
#include <functional>
#include <set>
-
+#include <string>
+
#include <simgear/props/condition.hxx>
#include <simgear/props/props.hxx>
#include <simgear/math/interpolater.hxx>
{
struct ParseError : public sg_exception
{
- ParseError(const string& message = std::string())
+ ParseError(const std::string& message = std::string())
: sg_exception(message) {}
};
{
public:
size_t addBinding(const std::string& name, expression::Type type);
- bool findBinding(const string& name, VariableBinding& result) const;
+ bool findBinding(const std::string& name, VariableBinding& result) const;
std::vector<VariableBinding> bindings;
};
ParserMap& map = getParserMap();
ParserMap::iterator itr = map.find(exp->getName());
if (itr == map.end())
- throw ParseError(string("unknown expression ") + exp->getName());
+ throw ParseError(std::string("unknown expression ") + exp->getName());
exp_parser parser = itr->second;
return (*parser)(exp, this);
}