5 /*! the argument list is documented if one of its
6 * arguments is documented
8 bool ArgumentList::hasDocumentation() const
11 ArgumentListIterator ali(*this);
13 for (ali.toFirst();!hasDocs && (a=ali.current());++ali)
15 hasDocs = a->hasDocumentation();
20 ArgumentList *ArgumentList::deepCopy() const
22 ArgumentList *argList = new ArgumentList;
23 argList->setAutoDelete(TRUE);
25 QListIterator<Argument> ali(*this);
27 for (;(a=ali.current());++ali)
29 argList->append(new Argument(*a));
31 argList->constSpecifier = constSpecifier;
32 argList->volatileSpecifier = volatileSpecifier;
33 argList->pureSpecifier = pureSpecifier;
34 argList->trailingReturnType = trailingReturnType;
39 ArgumentList *ArgumentList::unmarshal(StorageIntf *s)
42 uint count = unmarshalUInt(s);
43 if (count==NULL_LIST) return 0; // null list
44 ArgumentList *result = new ArgumentList;
45 assert(count<1000000);
46 //printf("unmarshalArgumentList: %d\n",count);
49 Argument *a = new Argument;
50 a->attrib = unmarshalQCString(s);
51 a->type = unmarshalQCString(s);
52 a->canType = unmarshalQCString(s);
53 a->name = unmarshalQCString(s);
54 a->array = unmarshalQCString(s);
55 a->defval = unmarshalQCString(s);
56 a->docs = unmarshalQCString(s);
59 result->constSpecifier = unmarshalBool(s);
60 result->volatileSpecifier = unmarshalBool(s);
61 result->pureSpecifier = unmarshalBool(s);
62 result->trailingReturnType = unmarshalQCString(s);
66 void ArgumentList::marshal(StorageIntf *s,ArgumentList *argList)
70 marshalUInt(s,NULL_LIST); // null pointer representation
74 marshalUInt(s,argList->count());
75 if (argList->count()>0)
77 ArgumentListIterator ali(*argList);
79 for (ali.toFirst();(a=ali.current());++ali)
81 marshalQCString(s,a->attrib);
82 marshalQCString(s,a->type);
83 marshalQCString(s,a->canType);
84 marshalQCString(s,a->name);
85 marshalQCString(s,a->array);
86 marshalQCString(s,a->defval);
87 marshalQCString(s,a->docs);
90 marshalBool(s,argList->constSpecifier);
91 marshalBool(s,argList->volatileSpecifier);
92 marshalBool(s,argList->pureSpecifier);
93 marshalQCString(s,argList->trailingReturnType);