01584             // found one, search through again
    01585             search = true;
    01586             delete (*iter);
    01587             this->[wrench_body_jobs](classGazeboROSNode.html#ade2831b1970d2ceed871e82a9140c2bb).erase(iter);
    01588             break;
    01589           }
    01590         }
    01591       }
    01592       this->[lock_](classGazeboROSNode.html#a3895043c9355e3e2a23f84efe0060736 "A mutex to lock access to fields that are used in ROS message callbacks.").unlock();
    01593       return true;
    01594     }
    01595 
    [01598](classGazeboROSNode.html#aeec9ad42d7c0628cc49d6d886b8a377d)     bool [setModelConfiguration](classGazeboROSNode.html#aeec9ad42d7c0628cc49d6d886b8a377d)([gazebo_msgs::SetModelConfiguration::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationRequest__.html) &req,[gazebo_msgs::SetModelConfiguration::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationResponse__.html) &res)
    01599     {
    01600       std::string gazebo_model_name = req.[model_name](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationRequest__.html#a0ee5962a9eb9e10922d0371b7025b1ee);
    01601 
    01602       // search for model with name
    01603       gazebo::Model* gazebo_model = dynamic_cast<gazebo::Model*>(gazebo::World::Instance()->GetEntityByName(gazebo_model_name));
    01604       if (gazebo_model == NULL)
    01605       {
    01606         [ROS_ERROR](../../../api/rosconsole/html/macros__generated_8h.html#a7fb635b03cc608284eadecd2f8becd9a)("SetModelConfiguration: model [%s] does not exist",gazebo_model_name.c_str());
    01607         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationResponse__.html#a8c206095119a86b72a7de6b3ab740cdc) = false;
    01608         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationResponse__.html#a2fdb8a5a8cf73b4b360782c4e7dfbf38) = "SetModelConfiguration: model does not exist";
    01609         return false;
    01610       }
    01611 
    01612       // make the service call to pause gazebo
    01613       bool is_paused = gazebo::Simulator::Instance()->IsPaused();
    01614       if (!is_paused) gazebo::Simulator::Instance()->SetPaused(true);
    01615 
    01616       [setModelJointPositions](classGazeboROSNode.html#a131c45793b70f3fa421701a96ddaa84b)(gazebo_model,req.[joint_names](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationRequest__.html#a974d7f7fa3f97c132c47bf9fa54e82a1),req.[joint_positions](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationRequest__.html#a4a6ed8cc19d958c191729f7e9eb4eaaf));
    01617 
    01618       // resume paused state before this call
    01619       gazebo::Simulator::Instance()->SetPaused(is_paused);
    01620 
    01621       res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationResponse__.html#a8c206095119a86b72a7de6b3ab740cdc) = true;
    01622       res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1SetModelConfigurationResponse__.html#a2fdb8a5a8cf73b4b360782c4e7dfbf38) = "SetModelConfiguration: success";
    01623       return true;
    01624     }
    01625