本文整理汇总了C++中Strings::front方法的典型用法代码示例。如果您正苦于以下问题:C++ Strings::front方法的具体用法?C++ Strings::front怎么用?C++ Strings::front使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Strings
的用法示例。
在下文中一共展示了Strings::front方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: writeConfig
void ConfigTool::writeConfig() const
{
Global* global = Global::instance();
global->setConfigFAttribute( Config::FATTR_VERSION, 1.2f );
global->setWindowIAttribute( eq::server::Window::IATTR_HINT_FULLSCREEN,
eq::fabric::ON );
if( _mode != MODE_WALL )
{
global->setWindowIAttribute(eq::server::Window::IATTR_HINT_DOUBLEBUFFER,
eq::fabric::OFF );
global->setWindowIAttribute( eq::server::Window::IATTR_HINT_DRAWABLE,
eq::fabric::PBUFFER );
}
if( _mode >= MODE_DB && _mode <= MODE_DB_STREAM )
global->setWindowIAttribute( eq::server::Window::IATTR_PLANES_STENCIL,
eq::fabric::ON );
ServerPtr server = new eq::server::Server;
const Strings nodeNames = readNodenames( _nodesFile );
co::ConnectionDescriptionPtr desc = new ConnectionDescription;
if( !nodeNames.empty( ))
desc->setHostname( nodeNames.front( ));
server->addConnectionDescription( desc );
Config* config = new Config( server );
_writeResources( config, nodeNames );
_writeCompound( config );
lunchbox::Log::instance( "", 0 )
<< lunchbox::disableHeader << global << *server << std::endl
<< lunchbox::enableHeader << lunchbox::disableFlush;
}
示例2: align_seqs_impl
void DummyAligner::align_seqs_impl(Strings& seqs) const {
int max_length = seqs.front().length();
BOOST_FOREACH (const std::string& seq, seqs) {
max_length = std::max(max_length, int(seq.length()));
}