字符 - 'pub' 在 std::streambuf::p ubsetbuf() 方法中是什么意思?

What do the characters - 'pub' mean in std::streambuf::pubsetbuf() method?

本文关键字:方法 意思 是什么 streambuf pub std 字符 ubsetbuf      更新时间:2023-10-16

我知道这个方法是用来设置std::streambuf缓冲区的,我只是不明白pub部分的意思std::streambuf::pubseekoff

pub用于publicstd::streambuf::pubseekoff是受保护的虚拟功能seekoff的公共面孔。

由于您不能基于函数是虚拟的来重载函数,因此必须为其中一个函数指定不同的名称。