#ifndef MKT_PLUGINS_LIMITED_ACCEL_GENERATOR_H_INCLUDED_
#define MKT_PLUGINS_LIMITED_ACCEL_GENERATOR_H_INCLUDED_

#include <mkt_plugins/standard_traj_generator.h>

namespace mkt_plugins
{
/**
 * @class LimitedAccelGenerator
 * @brief Limits the acceleration in the generated trajectories to a fraction of the simulated time.
 */
class LimitedAccelGenerator : public StandardTrajectoryGenerator
{
public:
  /**
   * @brief Constructor
   */
  LimitedAccelGenerator();
  /**
   * @brief Destructor
   */
  virtual ~LimitedAccelGenerator();
  
  /**
   * @brief Initialize the generator with parameters from NodeHandle
   * @param nh NodeHandle for loading acceleration_time parameter
   * 
   * Loads the acceleration_time parameter which limits acceleration to a fraction
   * of the simulated time.
   */
  void initialize(const robot::NodeHandle& nh) override;
  
  /**
   * @brief Start a new iteration with current velocity
   * @param current_velocity Current velocity of the robot
   * 
   * Overrides the base class to apply acceleration limits based on acceleration_time.
   */
  void startNewIteration(const robot_nav_2d_msgs::Twist2D& current_velocity) override;
  
  /**
   * @brief Factory function to create a LimitedAccelGenerator instance
   * @return Shared pointer to a new LimitedAccelGenerator instance
   */
  static score_algorithm::TrajectoryGenerator::Ptr create();
protected:
  double acceleration_time_;
};
}  // namespace mkt_plugins

#endif  // MKT_PLUGINS_LIMITED_ACCEL_GENERATOR_H_INCLUDED_
