GroupRecordHandler Class Reference

Handles the reading of all line attribute records in the v2 file format. More...

#include <rechgrp.h>

Inheritance diagram for GroupRecordHandler:

CamelotRecordHandler CXaraFileRecordHandler ListItem CCObject SimpleCCObject List of all members.

Public Member Functions

 GroupRecordHandler ()
 ~GroupRecordHandler ()
virtual UINT32GetTagList ()
 Provides the record handler system with a list of records handled by this handler.
virtual BOOL HandleRecord (CXaraFileRecord *pCXaraFileRecord)
 Handles the given record.

Private Member Functions

 CC_DECLARE_DYNAMIC (GroupRecordHandler)
BOOL HandleGroupRecord (CXaraFileRecord *pCXaraFileRecord)
 Handles the given record. The record has to be a Line colour record.

Detailed Description

Handles the reading of all line attribute records in the v2 file format.

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
30/5/96
See also:
-

Definition at line 118 of file rechgrp.h.


Constructor & Destructor Documentation

GroupRecordHandler::GroupRecordHandler  )  [inline]
 

Definition at line 124 of file rechgrp.h.

00124 : CamelotRecordHandler() {}

GroupRecordHandler::~GroupRecordHandler  )  [inline]
 

Definition at line 125 of file rechgrp.h.

00125 {}


Member Function Documentation

GroupRecordHandler::CC_DECLARE_DYNAMIC GroupRecordHandler   )  [private]
 

UINT32 * GroupRecordHandler::GetTagList  )  [virtual]
 

Provides the record handler system with a list of records handled by this handler.

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
17/6/96
Parameters:
- [INPUTS]
Returns:
Ptr to a list of tag values, terminated by CXFRH_TAG_LIST_END
See also:
-

Implements CXaraFileRecordHandler.

Definition at line 1978 of file group.cpp.

01979 {
01980     static UINT32 TagList[] = {TAG_GROUP, TAG_COMPOUNDRENDER, TAG_OBJECTBOUNDS, CXFRH_TAG_LIST_END};
01981 
01982     return (UINT32*)&TagList;
01983 }

BOOL GroupRecordHandler::HandleGroupRecord CXaraFileRecord pCXaraFileRecord  )  [private]
 

Handles the given record. The record has to be a Line colour record.

BOOL GroupRecordHandler::HandleGroupRecord(CXaraFileRecord* pCXaraFileRecord)

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
17/6/96
Parameters:
pCXaraFileRecord = ptr to record to handle [INPUTS]
Returns:
TRUE if handled successfuly FALSE otherwise
See also:
-

Definition at line 2044 of file group.cpp.

02045 {
02046     ERROR2IF(pCXaraFileRecord == NULL,FALSE,"pCXaraFileRecord is NULL");
02047     ERROR2IF(pCXaraFileRecord->GetTag() != TAG_GROUP,FALSE,"I don't handle this tag type");
02048 
02049     NodeGroup* pGroup = new NodeGroup;
02050     BOOL ok = FALSE;
02051 
02052     if (pGroup != NULL)
02053         ok = InsertNode(pGroup);
02054 
02055     return ok;
02056 }

BOOL GroupRecordHandler::HandleRecord CXaraFileRecord pCXaraFileRecord  )  [virtual]
 

Handles the given record.

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
17/6/96
Parameters:
pCXaraFileRecord = ptr to record to handle [INPUTS]
Returns:
TRUE if handled successfuly FALSE otherwise
See also:
-

Implements CXaraFileRecordHandler.

Definition at line 1999 of file group.cpp.

02000 {
02001     ERROR2IF(pCXaraFileRecord == NULL,FALSE,"pCXaraFileRecord is NULL");
02002 
02003     BOOL ok = TRUE;
02004 
02005     switch (pCXaraFileRecord->GetTag())
02006     {
02007         case TAG_GROUP:
02008             ok = HandleGroupRecord(pCXaraFileRecord);
02009             break;
02010 
02011         case TAG_COMPOUNDRENDER:
02012         case TAG_OBJECTBOUNDS:
02013             // Do nothing
02014             // We ignore TAG_COMPOUNDRENDER records because they are really just a hint to
02015             // external XAR stream handlers
02016             ok = TRUE;
02017             break;
02018 
02019         default:
02020             ok = FALSE;
02021             ERROR3_PF(("I don't handle records with the tag (%d)\n",pCXaraFileRecord->GetTag()));
02022             break;
02023     }
02024 
02025     return ok;
02026 }


The documentation for this class was generated from the following files:
Generated on Sat Nov 10 03:55:03 2007 for Camelot by  doxygen 1.4.4