Example #1
0
void _Stg_ObjectAdaptor_Print( void* objectAdaptor, struct Stream* stream ) {
	Stg_ObjectAdaptor*	self = (Stg_ObjectAdaptor*)objectAdaptor;
	
	/* General info */
	Journal_Printf( stream, "Stg_ObjectAdaptor (ptr): %p\n", self );
	Stream_Indent( stream );
	
	_Stg_Object_Print( self, stream );
	
	Journal_Printf( stream, "iOwn: %s\n", self->iOwn ? "Yes" : "No" );
	Journal_Printf( stream, "isGlobal: %s\n", self->isGlobal ? "Yes" : "No" );
	Journal_Printf( stream, "isStgClass: %s\n", self->isStgClass ? "Yes" : "No" );
	
	if( self->isStgClass ) {
		Stg_Class_Print( self->dataPtr, stream );
	}
	else {
		if( self->ptrPrint ) {
			self->ptrPrint( self->dataPtr, stream );
		}
		else {
			Journal_Printf( stream, "Don't know how to print the pointer (it is not to a StGermain class)\n" );
		}
	}
	
	Stream_UnIndent( stream );
}
Example #2
0
void _JournalFile_Print( void* journalFile, Stream* stream )
{
	JournalFile* self = (JournalFile*)journalFile;
                                                                                
        Journal_Printf( stream, "JournalFile (ptr): %p\n", self );
         
        _Stg_Object_Print( self, stream );
         
        Journal_Printf( stream, "\tfileHandle (ptr): %p\n", self->fileHandle );
}
Example #3
0
void _File_Print( void* file, Stream* stream )
{
	File* self = (File*)file;
                                                                                
        Journal_Printf( stream, "File (ptr): %p\n", self );
         
        _Stg_Object_Print( self, stream );
         
        Journal_Printf( stream, "\tfileHandle (ptr): %p\n", self->fileHandle );
}
void _ExtensionInfo_Print( void* extensionInfo, Stream* stream ) {
	ExtensionInfo* self = (ExtensionInfo*)extensionInfo;
		
	Journal_DFirewall( 
			self != NULL,  
			Journal_Register( ErrorStream_Type, ExtensionInfo_Type ), 
			"Attempting to \"%s\" print a pointer of value NULL\n", ExtensionInfo_Type );
	
	/* General info */
	Journal_Printf( (void*)stream, "ExtensionInfo (%p):\n", self );
	_Stg_Object_Print( self, stream );
	Journal_Printf( (void*)stream, "\toriginalSize: %u\n", (unsigned int)self->originalSize );
	Journal_Printf( (void*)stream, "\tsize: %u\n", (unsigned int)self->size );
	Journal_Printf( (void*)stream, "\tisRegistered: %s\n", self->isRegistered ? "Yes" : "No" );
	Journal_Printf( (void*)stream, "\toffset: %u\n", (unsigned int)self->offset );
	Journal_Printf( (void*)stream, "\textensionManager: %p (ptr)\n", self->extensionManager );
	Journal_Printf( (void*)stream, "\thandle: %u\n", self->handle );
}