CExDocument Class Reference

#include <ExDocument.h>

Inheritance diagram for CExDocument:
Inheritance graph
[legend]
Collaboration diagram for CExDocument:
Collaboration graph
[legend]

List of all members.

Public Member Functions

CExViewGetView ()
virtual BOOL ReadDataFile (LPCTSTR)
virtual BOOL WriteDataFile (LPCTSTR)
virtual BOOL MakeViewData ()
virtual void Serialize (CArchive &ar)
virtual BOOL OnNewDocument ()
virtual BOOL OnOpenDocument (LPCTSTR lpszPathName)
virtual ~CExDocument ()
virtual void AssertValid () const
virtual void Dump (CDumpContext &dc) const

Public Attributes

CmnHead infHead
ExMSGraph< sWord > msGraph
ExCmnHead cmnHead
CExViewpView
CExFramepFrame
CAppCallBackpApp
void * anyData
CString Title
CString preTitle
CString pstTitle
int vMax
int vMin
int cMax
int cMin
int base
int colorMode
int startNo
int endNo
BOOL multiSliceData
BOOL hasReadData
BOOL hasViewData
BOOL ctrlCntrst
BOOL notFreeMSGraph
BOOL notFreeCmnHead

Protected Member Functions

 CExDocument ()

Detailed Description

Definition at line 43 of file ExDocument.h.


Constructor & Destructor Documentation

CExDocument (  )  [protected]

Definition at line 25 of file ExDocument.cpp.

00026 {
00027     //DEBUG_WARN("CExDocument::CExDocument Start\n");
00028 
00029     init_CmnHead(&infHead);
00030     msGraph.init();
00031     cmnHead.init();
00032 
00033     hasReadData    = FALSE; // データを正常に読み込み,保持しているか.
00034     hasViewData    = FALSE; // 読み込んだデータから表示用データを作成したか.
00035     ctrlCntrst     = FALSE; // 表示用データ作成時に(画素値が255以下でも)強制的にコントラストを調整を行う.
00036     multiSliceData = FALSE; // TRUE ならマルチスライス読み込みモード
00037     notFreeMSGraph = FALSE; // メモリ管理無しの場合,このオブジェクトが msGraph のメモリを開放するのは禁止.
00038     notFreeCmnHead = FALSE; // メモリ管理無しの場合,このオブジェクトが cmnHead のメモリを開放するのは禁止.
00039     
00040     pView       = NULL;
00041     pFrame      = NULL;
00042     pApp        = NULL;
00043     anyData     = NULL;
00044 
00045     Title       = _T("");
00046     preTitle    = _T("");
00047     pstTitle    = _T("");
00048 
00049     startNo     = 0;
00050     endNo       = 0;
00051     vMax        = 0;
00052     vMin        = 0;
00053     colorMode   = GRAPH_COLOR_MONO;
00054     base        = 0;
00055 
00056     //DEBUG_WARN("CExDocument::CExDocument End\n");
00057 }

~CExDocument (  )  [virtual]

Definition at line 61 of file ExDocument.cpp.

References CExDocument::cmnHead, CAppCallBack::DocumentDestructor(), CExDocument::msGraph, CExDocument::notFreeCmnHead, CExDocument::notFreeMSGraph, CExDocument::pApp, CExFrame::pDoc, CExView::pDoc, CExDocument::pFrame, and CExDocument::pView.

00062 {
00063     DEBUG_INFO("DESTRUCTOR: CExDocument\n");
00064 
00065     if (pApp!=NULL) pApp->DocumentDestructor(this);         // 上位アプリケーションに通知
00066 
00067     if (notFreeCmnHead) cmnHead.mfree();
00068     else                cmnHead.free();
00069     if (notFreeMSGraph) msGraph.mfree();
00070     else                msGraph.free();
00071     
00072     if (!isNull(pView))  pView->pDoc  = NULL;
00073     if (!isNull(pFrame)) pFrame->pDoc = NULL;
00074     pView  = NULL;
00075     pFrame = NULL;
00076 }

Here is the call graph for this function:


Member Function Documentation

void AssertValid (  )  const [virtual]

Reimplemented in CDxGraphDoc, CRwGRDoc, and CvThumbNailDoc.

Definition at line 92 of file ExDocument.cpp.

00093 {
00094     CDocument::AssertValid();
00095 }

void Dump ( CDumpContext &  dc  )  const [virtual]

Reimplemented in CDxGraphDoc, CRwGRDoc, and CvThumbNailDoc.

Definition at line 99 of file ExDocument.cpp.

00100 {
00101     CDocument::Dump(dc);
00102 }

CExView * GetView (  ) 

Definition at line 159 of file ExDocument.cpp.

References CExDocument::pView.

Referenced by jbxwl::CreateDocFrmView().

00160 {
00161     if (pView==NULL) {
00162         POSITION pos = GetFirstViewPosition();
00163         while (pos!=NULL) {
00164             CExView* pview = (CExView*)GetNextView(pos);
00165             if (this==pview->GetDocument()) return pview;
00166         }
00167         return NULL;
00168     }
00169     return pView;
00170 }

Here is the caller graph for this function:

BOOL MakeViewData (  )  [virtual]

Reimplemented in CDxGraphDoc, and CRwGRDoc.

Definition at line 190 of file ExDocument.cpp.

Referenced by CExDocument::OnNewDocument(), and CExDocument::OnOpenDocument().

00191 {
00192     return TRUE;
00193 }

Here is the caller graph for this function:

BOOL OnNewDocument (  )  [virtual]

Definition at line 128 of file ExDocument.cpp.

References CExDocument::hasReadData, CExDocument::hasViewData, and CExDocument::MakeViewData().

Referenced by jbxwl::InitialDocView().

00129 {
00130     //DEBUG_INFO("CExDocument::OnNewDocument(): START\n");
00131 
00132     if (!hasReadData) return FALSE;
00133 
00134     if (!hasViewData) hasViewData = MakeViewData();
00135     if (!hasViewData) return FALSE;
00136 
00137     //DEBUG_INFO("CExDocument::OnNewDocument(): END\n");
00138     return  TRUE;
00139 }

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL OnOpenDocument ( LPCTSTR  lpszPathName  )  [virtual]

Definition at line 143 of file ExDocument.cpp.

References CExDocument::hasReadData, CExDocument::hasViewData, CExDocument::MakeViewData(), and CExDocument::ReadDataFile().

Referenced by jbxwl::InitialDocView().

00144 {
00145     //DEBUG_INFO("CExDocument::OnOpenDocument(): START\n");
00146 
00147     if (!hasReadData) hasReadData = ReadDataFile(lpszPathName);
00148     if (!hasReadData) return FALSE;
00149 
00150     if (!hasViewData) hasViewData = MakeViewData();
00151     if (!hasViewData) return FALSE;
00152 
00153     //DEBUG_INFO("CExDocument::OnOpenDocument(): END\n");
00154     return TRUE;
00155 }

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL ReadDataFile ( LPCTSTR  str  )  [virtual]

機能: 画像データを読み込む. 引数: ファイル名 戻値: TRUE: 成功,FALSE: 失敗 説明: 読み込んだグラフィックデータ(msGraphメンバ)

Reimplemented in CDxGraphDoc, and CRwGRDoc.

Definition at line 180 of file ExDocument.cpp.

Referenced by CExDocument::OnOpenDocument().

00181 {
00182     return  TRUE;
00183 }

Here is the caller graph for this function:

void Serialize ( CArchive &  ar  )  [virtual]

Reimplemented in CDxGraphDoc, CRwGRDoc, and CvThumbNailDoc.

Definition at line 110 of file ExDocument.cpp.

00111 {
00112     if (ar.IsStoring())
00113     {
00114         // TODO: この位置に保存用のコードを追加してください
00115     }
00116     else
00117     {
00118         // TODO: この位置に読み込み用のコードを追加してください
00119     }
00120 }

BOOL WriteDataFile ( LPCTSTR  fname  )  [virtual]

Definition at line 200 of file ExDocument.cpp.

00201 {
00202     return TRUE;
00203 }


Member Data Documentation

void* anyData

Definition at line 58 of file ExDocument.h.

int base

Definition at line 69 of file ExDocument.h.

Referenced by CContrastDLG::CContrastDLG(), and CRwGRDoc::TranslateData().

int cMax
int cMin
ExCmnHead cmnHead
int colorMode
BOOL ctrlCntrst
int endNo

Definition at line 73 of file ExDocument.h.

Referenced by CDxMGRView::MakeSetTitle(), and CRwGRDoc::ReadDataFile().

CmnHead infHead

Definition at line 51 of file ExDocument.h.

Referenced by CRwGRDoc::ReadDataFile(), and CDxGraphDoc::ReadDataFile().

ExMSGraph<sWord> msGraph

Definition at line 75 of file ExDocument.h.

Referenced by jbxwl::ExecTemplate(), and CRwGRDoc::ReadDataFile().

Definition at line 81 of file ExDocument.h.

Referenced by CExDocument::~CExDocument().

Definition at line 80 of file ExDocument.h.

Referenced by CExDocument::~CExDocument().

Definition at line 57 of file ExDocument.h.

Referenced by jbxwl::SetExLink(), and CExDocument::~CExDocument().

CString preTitle
CString pstTitle
int startNo

Definition at line 72 of file ExDocument.h.

Referenced by CDxMGRView::MakeSetTitle(), and CRwGRDoc::ReadDataFile().

CString Title
int vMax
int vMin

The documentation for this class was generated from the following files:

Generated on 15 Nov 2023 for JunkBox_Win_Lib by  doxygen 1.6.1