|
For some IDL generated classes, it is desirable to differentiate between the field names in BSON and the names in the generated C++ code. A good example of this is oplog entries which use one and two letter field names to keep the BSON small but may desire for the code to have a more verbose description of a field.
Example:
demo_struct:
|
fields:
|
o:
|
type: int
|
cpp_name: operation
|
Instead of generating:
std::int32_t getO() const;
|
void setO(std::int32_t value) const;
|
more descriptive names will be used instead.
std::int32_t getOperation() const;
|
void setOperation(std::int32_t value) const;
|
Reported by judah.schvimer
|