Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Joost's c++ utilitiesNew to Visual Studio Code? Get it now.
Joost's c++ utilities

Joost's c++ utilities

New House Internet Services BV

|
591 installs
| (0) | Free
Just a few simple transformations to speed up c++ coding in VS Code.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Joost's C++ utilities

Just a few simple transformations to speed up c++ coding in VS Code.

Given a set of property declarations, eg:

class T
{
private:
    size_t m_Size;
    std::array<std::string,3> m_TheStrings;
};

Select the two lines containing the properties m_Size and m_TheStrings and run the commands:

create getters and setters

Outputs the following:

const size_t& Size() const { return m_Size; }
void SetSize(const size_t& v) { m_Size = v; }
void SetSize(size_t&& v) { m_Size = std::move(v); }
const std::array<std::string,3>& TheStrings() const { return m_TheStrings; }
void SetTheStrings(const std::array<std::string,3>& v) { m_TheStrings = v; }
void SetTheStrings(std::array<std::string,3>&& v) { m_TheStrings = std::move(v); }

create constructor

Outputs the following:

CONSTRUCTORNAME(const size_t& size, const std::array<std::string,3>& theStrings) : m_Size(size), m_TheStrings(theStrings) {}

create property list

Outputs the following:

m_Size, m_TheStrings
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft