title: Best practices: extra methods in c++
body: <p>So, I'm doing a project where I have a class named Window, and the goal of the class is storing the state of the window (whether the window is open or closed) and having a method Toggle, which toggles the window.</p>
  <pre><code>class Window {
   public:
    explicit Window(bool is_open);
  
    Window(const Window&amp;) = default;
    Window&amp; operator=(const Window&amp;) = default;
  
    ~Window() {}
  
    // Returns if the window is open.
    bool is_open();
  
    // Toggles the window. Returns if the window is now open.
    bool Toggle();
  
   private:
    bool is_open_;
  };
  </code></pre>
  <p>However, I've been thinking if the class should also have two methods called Open and Close, which do exactly what the names suggest. This methods would give me more control over the window's state, even that, for the purpose of the task, they are useless.</p>
  <p>So, what is the best thing to do here? Should I give the extra methods to the class or shouldn't I?</p>