Пример #1
0
void Definition::loadFromDisk() const
{
  //printf("%p: Definition::loadFromDisk()\n",this);
  Definition *that = (Definition *)this;
  assert(m_impl==0);
  that->m_impl = new DefinitionImpl;
  uint marker = unmarshalUInt(Doxygen::symbolStorage);
  assert(marker==START_MARKER);
  m_impl->sectionDict     = unmarshalSectionDict  (Doxygen::symbolStorage);
  m_impl->sourceRefByDict = unmarshalMemberSDict  (Doxygen::symbolStorage);
  m_impl->sourceRefsDict  = unmarshalMemberSDict  (Doxygen::symbolStorage);
  m_impl->xrefListItems   = unmarshalItemInfoList (Doxygen::symbolStorage);
  m_impl->partOfGroups    = unmarshalGroupList    (Doxygen::symbolStorage);
  m_impl->details         = unmarshalDocInfo      (Doxygen::symbolStorage);
  m_impl->inbodyDocs      = unmarshalDocInfo      (Doxygen::symbolStorage);
  m_impl->brief           = unmarshalBriefInfo    (Doxygen::symbolStorage);
  m_impl->body            = unmarshalBodyInfo     (Doxygen::symbolStorage);
  m_impl->docSignatures   = unmarshalQCString     (Doxygen::symbolStorage);
  m_impl->localName       = unmarshalQCString     (Doxygen::symbolStorage);
  m_impl->qualifiedName   = unmarshalQCString     (Doxygen::symbolStorage);
  m_impl->ref             = unmarshalQCString     (Doxygen::symbolStorage);
  m_impl->hidden          = unmarshalBool         (Doxygen::symbolStorage);
  m_impl->isArtificial    = unmarshalBool         (Doxygen::symbolStorage);
  m_impl->outerScope      = (Definition *)unmarshalObjPointer   (Doxygen::symbolStorage);
  m_impl->defFileName     = unmarshalQCString     (Doxygen::symbolStorage);
  m_impl->defLine         = unmarshalInt          (Doxygen::symbolStorage);
  m_impl->defFileExt      = unmarshalQCString     (Doxygen::symbolStorage);
  marker = unmarshalUInt(Doxygen::symbolStorage);
  assert(marker==END_MARKER);
}
Пример #2
0
ArgumentList *unmarshalArgumentList(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  if (count==NULL_LIST) return 0; // null list
  ArgumentList *result = new ArgumentList;
  assert(count<1000000);
  //printf("unmarshalArgumentList: %d\n",count);
  for (i=0;i<count;i++)
  {
    Argument *a = new Argument;
    a->attrib  = unmarshalQCString(s);
    a->type    = unmarshalQCString(s);
    a->canType = unmarshalQCString(s);
    a->name    = unmarshalQCString(s);
    a->array   = unmarshalQCString(s);
    a->defval  = unmarshalQCString(s);
    a->docs    = unmarshalQCString(s);
    result->append(a);
  }
  result->constSpecifier    = unmarshalBool(s);
  result->volatileSpecifier = unmarshalBool(s);
  result->pureSpecifier     = unmarshalBool(s);
  return result;
}
Пример #3
0
MemberSDict *unmarshalMemberSDict(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  //printf("--- unmarshalMemberSDict count=%d\n",count);
  if (count==NULL_LIST) 
  {
    //printf("--- end unmarshalMemberSDict\n");
    return 0; // null list
  }
  MemberSDict *result = new MemberSDict;
  assert(count<1000000);
  //printf("Reading %d key-value pairs\n",count);
  for (i=0;i<count;i++)
  {
    //printf("  unmarshaling pair %d\n",i);
    QCString key    = unmarshalQCString(s);
    //printf("  unmarshaling key %s\n",key.data());
    MemberDef *md = (MemberDef *)unmarshalObjPointer(s);
    //printf("  unmarshalMemberSDict i=%d key=%s md=%p\n",i,key.data(),md);
    result->append(key,md); 
  }

  //printf("--- end unmarshalMemberSDict\n");
  return result;
}
Пример #4
0
void MemberList::unmarshal(StorageIntf *s)
{
  m_listType       = (MemberListType)unmarshalInt(s);
  m_varCnt         = unmarshalInt(s);
  m_funcCnt        = unmarshalInt(s);
  m_enumCnt        = unmarshalInt(s);
  m_enumValCnt     = unmarshalInt(s);
  m_typeCnt        = unmarshalInt(s);
  m_protoCnt       = unmarshalInt(s);
  m_defCnt         = unmarshalInt(s);
  m_friendCnt      = unmarshalInt(s); 
  m_numDecMembers  = unmarshalInt(s);
  m_numDocMembers  = unmarshalInt(s);
  m_inGroup        = unmarshalBool(s);
  m_inFile         = unmarshalBool(s);
  m_needsSorting   = unmarshalBool(s);
  uint i,count     = unmarshalUInt(s); 
  if (count==NULL_LIST) // empty list
  {
    memberGroupList = 0;
  }
  else // add member groups
  {
    memberGroupList = new MemberGroupList;
    for (i=0;i<count;i++)
    {
      MemberGroup *mg = new MemberGroup;
      mg->unmarshal(s);
      memberGroupList->append(mg);
    }
  }
}
Пример #5
0
BodyInfo *unmarshalBodyInfo(StorageIntf *s)
{
  uint count = unmarshalUInt(s); 
  if (count==NULL_LIST) return 0;
  BodyInfo *result = new BodyInfo;
  result->startLine = unmarshalInt(s);
  result->endLine   = unmarshalInt(s);
  result->fileDef   = (FileDef*)unmarshalObjPointer(s);
  return result;
}
Пример #6
0
DocInfo *unmarshalDocInfo(StorageIntf *s)
{
  uint count = unmarshalUInt(s); 
  if (count==NULL_LIST) return 0;
  DocInfo *result = new DocInfo;
  result->doc  = unmarshalQCString(s);
  result->line = unmarshalInt(s);
  result->file = unmarshalQCString(s);
  return result;
}
Пример #7
0
Entry * unmarshalEntryTree(StorageIntf *s)
{
  Entry *e = unmarshalEntry(s);
  uint count = unmarshalUInt(s);
  uint i;
  for (i=0;i<count;i++)
  {
    e->addSubEntry(unmarshalEntryTree(s));
  }
  return e;
}
Пример #8
0
QGString unmarshalQGString(StorageIntf *s)
{
  uint len = unmarshalUInt(s);
  //printf("unmarshalQCString: len=%d offset=%llx\n",len,f.pos());
  QGString result(len+1);
  result.at(len)='\0';
  if (len>0)
  {
    s->read(result.data(),len);
  }
  //printf("unmarshalQCString: result=%s\n",result.data());
  return result;
}
Пример #9
0
GroupList *unmarshalGroupList(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  if (count==NULL_LIST) return 0; // null list
  assert(count<1000000);
  GroupList *result = new GroupList;
  for (i=0;i<count;i++)
  {
    GroupDef *gd = (GroupDef *)unmarshalObjPointer(s);
    result->append(gd);
  }
  return result;
}
Пример #10
0
SDict<MemberList> *unmarshalMemberLists(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s); 
  if (count==NULL_LIST) return 0;
  SDict<MemberList> *result = new SDict<MemberList>(7);
  assert(count<1000000);
  for (i=0;i<count;i++)
  {
    QCString key = unmarshalQCString(s);
    MemberList *ml = (MemberList *)unmarshalObjPointer(s);
    result->append(key,ml);
  }
  return result;
}
Пример #11
0
MemberList *unmarshalMemberList(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s); 
  if (count==NULL_LIST) return 0;
  MemberList *result = new MemberList;
  assert(count<1000000);
  for (i=0;i<count;i++)
  {
    MemberDef *md = (MemberDef*)unmarshalObjPointer(s);
    result->append(md);
  }
  result->unmarshal(s);
  return result;
}
Пример #12
0
QList<ArgumentList> *unmarshalArgumentLists(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  if (count==NULL_LIST) return 0; // null list
  QList<ArgumentList> *result = new QList<ArgumentList>;
  result->setAutoDelete(TRUE);
  assert(count<1000000);
  //printf("unmarshalArgumentLists: %d\n",count);
  for (i=0;i<count;i++)
  {
    result->append(unmarshalArgumentList(s));
  }
  return result;
}
Пример #13
0
QList<Grouping> *unmarshalGroupingList(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  if (count==NULL_LIST) return 0; // null list
  QList<Grouping> *result = new QList<Grouping>;
  result->setAutoDelete(TRUE);
  assert(count<1000000);
  for (i=0;i<count;i++)
  {
    QCString name = unmarshalQCString(s);
    Grouping::GroupPri_t prio = (Grouping::GroupPri_t)unmarshalInt(s);
    result->append(new Grouping(name,prio));
  }
  return result;
}
Пример #14
0
SectionDict *unmarshalSectionDict(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  //printf("unmarshalSectionDict count=%d\n",count);
  if (count==NULL_LIST) return 0; // null list
  SectionDict *result = new SectionDict(17);
  assert(count<1000000);
  for (i=0;i<count;i++)
  {
    QCString key    = unmarshalQCString(s);
    SectionInfo *si = (SectionInfo *)unmarshalObjPointer(s);
    //printf("  unmarshalSectionDict i=%d key=%s si=%s\n",count,key.data(),si->label.data());
    result->append(key,si);
  }
  return result;
}
Пример #15
0
QList<ListItemInfo> *unmarshalItemInfoList(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  if (count==NULL_LIST) return 0; // null list
  QList<ListItemInfo> *result = new QList<ListItemInfo>;
  result->setAutoDelete(TRUE);
  assert(count<1000000);
  for (i=0;i<count;i++)
  { 
    ListItemInfo *lii = new ListItemInfo;
    lii->type   = unmarshalQCString(s);
    lii->itemId = unmarshalInt(s);
    result->append(lii);
  }
  return result;
}
Пример #16
0
QList<BaseInfo> *unmarshalBaseInfoList(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s);
  if (count==NULL_LIST) return 0; // null list
  QList<BaseInfo> *result = new QList<BaseInfo>;
  result->setAutoDelete(TRUE);
  assert(count<1000000);
  for (i=0;i<count;i++)
  {
    QCString name   = unmarshalQCString(s);
    Protection prot = (Protection)unmarshalInt(s);
    Specifier virt  = (Specifier)unmarshalInt(s);
    result->append(new BaseInfo(name,prot,virt));
  }
  return result;
}
Пример #17
0
ExampleSDict *unmarshalExampleSDict(StorageIntf *s)
{
  uint i;
  uint count = unmarshalUInt(s); 
  if (count==NULL_LIST) return 0;
  ExampleSDict *result = new ExampleSDict;
  assert(count<1000000);
  for (i=0;i<count;i++)
  {
    QCString key = unmarshalQCString(s);
    Example *e = new Example;
    e->anchor = unmarshalQCString(s);
    e->name   = unmarshalQCString(s);
    e->file   = unmarshalQCString(s);
    result->inSort(key,e);
  }
  return result;
}
Пример #18
0
QList<SectionInfo> *unmarshalSectionInfoList(StorageIntf *s)
{
    uint i;
    uint count = unmarshalUInt(s);
    if (count==NULL_LIST) return 0; // null list
    QList<SectionInfo> *result = new QList<SectionInfo>;
    result->setAutoDelete(TRUE);
    assert(count<1000000);
    for (i=0; i<count; i++)
    {
        QCString label = unmarshalQCString(s);
        QCString title = unmarshalQCString(s);
        QCString ref   = unmarshalQCString(s);
        SectionInfo::SectionType type = (SectionInfo::SectionType)unmarshalInt(s);
        QCString fileName = unmarshalQCString(s);
        result->append(new SectionInfo(fileName,label,title,type,ref));
    }
    return result;
}
Пример #19
0
Entry * unmarshalEntry(StorageIntf *s)
{
  Entry *e = new Entry;
  uint header=unmarshalUInt(s);
  ASSERT(header==HEADER);
  e->name             = unmarshalQCString(s);
  e->type             = unmarshalQCString(s);
  e->section          = unmarshalInt(s);
  e->protection       = (Protection)unmarshalInt(s);
  e->mtype            = (MethodTypes)unmarshalInt(s);
  e->spec             = unmarshalInt(s);
  e->propSpec         = unmarshalInt(s);
  e->initLines        = unmarshalInt(s);
  e->stat             = unmarshalBool(s);
  e->explicitExternal = unmarshalBool(s);
  e->proto            = unmarshalBool(s);
  e->subGrouping      = unmarshalBool(s);
  e->callGraph        = unmarshalBool(s);
  e->callerGraph      = unmarshalBool(s);
  e->virt             = (Specifier)unmarshalInt(s);
  e->args             = unmarshalQCString(s);
  e->bitfields        = unmarshalQCString(s);
  delete e->argList;
  e->argList          = unmarshalArgumentList(s);
  e->tArgLists        = unmarshalArgumentLists(s);
  e->program          = unmarshalQGString(s);
  e->initializer      = unmarshalQGString(s);
  e->includeFile      = unmarshalQCString(s);
  e->includeName      = unmarshalQCString(s);
  e->doc              = unmarshalQCString(s);
  e->docLine          = unmarshalInt(s);
  e->docFile          = unmarshalQCString(s);
  e->brief            = unmarshalQCString(s);
  e->briefLine        = unmarshalInt(s);
  e->briefFile        = unmarshalQCString(s);
  e->inbodyDocs       = unmarshalQCString(s);
  e->inbodyLine       = unmarshalInt(s);
  e->inbodyFile       = unmarshalQCString(s);
  e->relates          = unmarshalQCString(s);
  e->relatesType      = (RelatesType)unmarshalInt(s);
  e->read             = unmarshalQCString(s);
  e->write            = unmarshalQCString(s);
  e->inside           = unmarshalQCString(s);
  e->exception        = unmarshalQCString(s);
  e->typeConstr       = unmarshalArgumentList(s);
  e->bodyLine         = unmarshalInt(s);
  e->endBodyLine      = unmarshalInt(s);
  e->mGrpId           = unmarshalInt(s);
  delete e->extends;
  e->extends          = unmarshalBaseInfoList(s);
  delete e->groups;
  e->groups           = unmarshalGroupingList(s);
  delete e->anchors;
  e->anchors          = unmarshalSectionInfoList(s);
  e->fileName         = unmarshalQCString(s);
  e->startLine        = unmarshalInt(s);
  e->sli              = unmarshalItemInfoList(s);
  e->lang             = (SrcLangExt)unmarshalInt(s);
  e->hidden           = unmarshalBool(s);
  e->artificial       = unmarshalBool(s);
  e->groupDocType     = (Entry::GroupDocType)unmarshalInt(s);
  return e;
}