本文整理汇总了C++中ClassList::pop_front方法的典型用法代码示例。如果您正苦于以下问题:C++ ClassList::pop_front方法的具体用法?C++ ClassList::pop_front怎么用?C++ ClassList::pop_front使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ClassList
的用法示例。
在下文中一共展示了ClassList::pop_front方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: __construct
bool
CodeVisitor::visitClassDefStart(const ClassDefPtr& p)
{
string scoped = p->scoped();
string name = getName(p);
string type = getTypeVar(p);
string abs = getAbsolute(p, _ns);
string prxName = getName(p, "Prx");
string prxType = getTypeVar(p, "Prx");
string prxAbs = getAbsolute(p, _ns, "", "Prx");
ClassList bases = p->bases();
ClassDefPtr base;
OperationList ops = p->operations();
OperationList::iterator oli;
DataMemberList members = p->dataMembers();
bool isInterface = p->isInterface();
bool isAbstract = isInterface || p->allOperations().size() > 0; // Don't use isAbstract() - see bug 3739
startNamespace(p);
//
// Define the class.
//
if(isInterface)
{
_out << sp << nl << "if(!interface_exists('" << escapeName(abs) << "'))";
_out << sb;
_out << nl << "interface " << name;
if(!bases.empty())
{
_out << " extends ";
for(ClassList::const_iterator q = bases.begin(); q != bases.end(); ++q)
{
if(q != bases.begin())
{
_out << ", ";
}
_out << getAbsolute(*q, _ns);
}
}
_out << sb;
for(oli = ops.begin(); oli != ops.end(); ++oli)
{
_out << nl << "public function " << fixIdent((*oli)->name()) << '(';
ParamDeclList params = (*oli)->parameters();
for(ParamDeclList::iterator q = params.begin(); q != params.end(); ++q)
{
if(q != params.begin())
{
_out << ", ";
}
_out << '$' << fixIdent((*q)->name());
}
_out << ");";
}
_out << eb;
}
else
{
_out << sp << nl << "if(!class_exists('" << escapeName(abs) << "'))";
_out << sb;
_out << nl;
if(isAbstract)
{
_out << "abstract ";
}
_out << "class " << name;
if(!bases.empty() && !bases.front()->isInterface())
{
base = bases.front();
bases.pop_front();
}
if(base)
{
_out << " extends " << getAbsolute(base, _ns);
}
else
{
if(!p->isLocal())
{
_out << " extends " << scopedToName("::Ice::ObjectImpl", _ns);
}
}
if(!bases.empty())
{
_out << " implements ";
for(ClassList::const_iterator q = bases.begin(); q != bases.end(); ++q)
{
if(q != bases.begin())
{
_out << ", ";
}
_out << getAbsolute(*q, _ns);
}
}
_out << sb;
//
// __construct
//.........这里部分代码省略.........