epoc32/include/tools/coredump/processdata.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
williamr@4
     1
// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@4
     2
// All rights reserved.
williamr@4
     3
// This component and the accompanying materials are made available
williamr@4
     4
// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
williamr@4
     5
// which accompanies this distribution, and is available
williamr@4
     6
// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
williamr@4
     7
//
williamr@4
     8
// Initial Contributors:
williamr@4
     9
// Nokia Corporation - initial contribution.
williamr@4
    10
//
williamr@4
    11
// Contributors:
williamr@4
    12
//
williamr@4
    13
// Description:
williamr@4
    14
//
williamr@4
    15
williamr@4
    16
williamr@4
    17
williamr@4
    18
/**
williamr@4
    19
 @file
williamr@4
    20
 @publishedPartner 
williamr@4
    21
 @released
williamr@4
    22
*/
williamr@4
    23
williamr@4
    24
#ifndef PROCESSDATA_H
williamr@4
    25
#define PROCESSDATA_H
williamr@4
    26
williamr@4
    27
#include <streamelement.h>
williamr@4
    28
williamr@4
    29
williamr@4
    30
/**
williamr@4
    31
@publishedPartner 
williamr@4
    32
@released
williamr@4
    33
williamr@4
    34
Class that represents a process on the target. It is based on CStreamElementBase so
williamr@4
    35
it can be streamed between client and server.
williamr@4
    36
It is used by the Core Dump server, its clients and the plugins.
williamr@4
    37
@see CServerCrashDataSource::GetProcessListL()
williamr@4
    38
*/
williamr@4
    39
class CProcessInfo : public CStreamElementBase
williamr@4
    40
{
williamr@4
    41
williamr@4
    42
public:
williamr@4
    43
williamr@4
    44
	IMPORT_C static CProcessInfo* NewL( const TUint64	  aId,
williamr@4
    45
										const TDesC		& aName );
williamr@4
    46
williamr@4
    47
	IMPORT_C static CProcessInfo* NewL( const TDesC8 & aStreamData );
williamr@4
    48
williamr@4
    49
	IMPORT_C ~CProcessInfo();
williamr@4
    50
williamr@4
    51
public:
williamr@4
    52
	// Methods specific to CProcessInfo
williamr@4
    53
williamr@4
    54
	IMPORT_C const TUint64 & Id( ) const;
williamr@4
    55
williamr@4
    56
	IMPORT_C void NameL( const TDesC & aName );
williamr@4
    57
	IMPORT_C const TDesC & Name() const;
williamr@4
    58
williamr@4
    59
	IMPORT_C TBool Observed( ) const;
williamr@4
    60
	IMPORT_C void  Observed( TBool aFlag );
williamr@4
    61
williamr@4
    62
public:
williamr@4
    63
	// Methods required by streaming interface 
williamr@4
    64
williamr@4
    65
	IMPORT_C TInt static MaxSize();
williamr@4
    66
williamr@4
    67
	IMPORT_C TInt Size() const;
williamr@4
    68
williamr@4
    69
	// Initializes ’this’ from stream
williamr@4
    70
	IMPORT_C void InternalizeL( RReadStream & aStream );
williamr@4
    71
williamr@4
    72
	// Writes ’this’ to the stream
williamr@4
    73
	IMPORT_C void ExternalizeL( RWriteStream & aStream, CBufFlat* buf );
williamr@4
    74
williamr@4
    75
williamr@4
    76
private:
williamr@4
    77
williamr@4
    78
	CProcessInfo(	const TUint64	  aId );
williamr@4
    79
williamr@4
    80
	CProcessInfo();
williamr@4
    81
williamr@4
    82
	void ConstructL( const TDesC & aName );
williamr@4
    83
williamr@4
    84
private:
williamr@4
    85
williamr@4
    86
	/** Symbian kernel process id */
williamr@4
    87
	TUint64				iId;
williamr@4
    88
williamr@4
    89
	/** Symbian kernel process name */
williamr@4
    90
	HBufC  *			iName;
williamr@4
    91
williamr@4
    92
    /** Observed by core dump server */
williamr@4
    93
	TBool				iObserved;
williamr@4
    94
williamr@4
    95
	/** Externalized size */
williamr@4
    96
	TUint				iSize;
williamr@4
    97
williamr@4
    98
	// These are not internalised/externalised since they are spare
williamr@4
    99
	TUint32				iSpare0;
williamr@4
   100
	TUint32				iSpare1;
williamr@4
   101
	TUint32				iSpare2;
williamr@4
   102
williamr@4
   103
	};
williamr@4
   104
williamr@4
   105
williamr@4
   106
/**
williamr@4
   107
@publishedPartner 
williamr@4
   108
@released
williamr@4
   109
williamr@4
   110
List of CProcessInfo object pointers
williamr@4
   111
@see CProcessInfo
williamr@4
   112
@see RPointerArray
williamr@4
   113
*/
williamr@4
   114
typedef RPointerArray<CProcessInfo>	RProcessPointerList;
williamr@4
   115
williamr@4
   116
#endif