Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

CommandSetFrame Class Reference

#include <command.h>

Inheritance diagram for CommandSetFrame:

Inheritance graph
Collaboration diagram for CommandSetFrame:

Collaboration graph
List of all members.

Public Member Functions

 CommandSetFrame (astro::CoordinateSystem, const std::string &, const std::string &)
void process (ExecutionEnvironment &)

Private Attributes

astro::CoordinateSystem coordSys
std::string refObjectName
std::string targetObjectName

Constructor & Destructor Documentation

CommandSetFrame::CommandSetFrame astro::CoordinateSystem  ,
const std::string ,
const std::string
 

Definition at line 234 of file command.cpp.

00236                                                            :
00237     coordSys(_coordSys), refObjectName(refName), targetObjectName(targetName)
00238 {
00239 }


Member Function Documentation

void CommandSetFrame::process ExecutionEnvironment  )  [virtual]
 

Implements InstantaneousCommand.

Definition at line 241 of file command.cpp.

References coordSys, refObjectName, and targetObjectName.

00242 {
00243     Selection ref = env.getSimulation()->findObjectFromPath(refObjectName);
00244     Selection target;
00245     if (coordSys == astro::PhaseLock)
00246         target = env.getSimulation()->findObjectFromPath(targetObjectName);
00247     env.getSimulation()->setFrame(FrameOfReference(coordSys, ref, target));
00248 }


Member Data Documentation

astro::CoordinateSystem CommandSetFrame::coordSys [private]
 

Definition at line 213 of file command.h.

Referenced by process().

std::string CommandSetFrame::refObjectName [private]
 

Definition at line 214 of file command.h.

Referenced by process().

std::string CommandSetFrame::targetObjectName [private]
 

Definition at line 215 of file command.h.

Referenced by process().


The documentation for this class was generated from the following files:
Generated on Sat Jan 14 22:33:14 2006 for Celestia by  doxygen 1.4.1