ITextOutput Class Reference
[Utility Classes and Functions]

#include <support/ITextStream.h>

Inheritance diagram for ITextOutput:

IInterface SAtom BNullTextOutput BTextOutput BStringIO List of all members.

Detailed Description

Abstract interface for streaming out formatted text.

Todo:
This should probably be changed to not derive from IInterface, so it doesn't depend on the Binder. It has never been clear how to marshal these across processes, anyway.


Public Member Functions

virtual void Flush ()=0
 Request that any pending data be written.
virtual status_t LogV (const log_info &info, const iovec *vector, ssize_t count, uint32_t flags=0)=0
 Write a log line.
virtual void MoveIndent (int32_t delta)=0
 Adjust the current indentation level by delta amount.
virtual status_t Print (const char *debugText, ssize_t len=-1)=0
 level, and possibly other formatting, will be applied to each line.
virtual status_t Sync ()=0
 physical device.

Classes

struct  log_info
 Attributes that can be included in a LogV() call. More...


Member Function Documentation

virtual void Flush  )  [pure virtual]
 

Request that any pending data be written.

This does NOT block until the data has been written; rather, it just ensures that the data will be written at some point in the future.

Implemented in BNullTextOutput, and BTextOutput.

virtual status_t LogV const log_info info,
const iovec *  vector,
ssize_t  count,
uint32_t  flags = 0
[pure virtual]
 

Write a log line.

Metadata about the text is supplied in info. The text itself is supplied in the iovec, which is handled as one atomic unit. You can supply B_WRITE_END for flags to indicate the item being logged has ended.

virtual void MoveIndent int32_t  delta  )  [pure virtual]
 

Adjust the current indentation level by delta amount.

Implemented in BNullTextOutput, and BTextOutput.

virtual status_t Print const char *  debugText,
ssize_t  len = -1
[pure virtual]
 

level, and possibly other formatting, will be applied to each line.

If len is negative, all text up to the first NUL character will be printed. Otherwise, up to len characters will be printed.

Implemented in BNullTextOutput, and BTextOutput.

virtual status_t Sync  )  [pure virtual]
 

physical device.

Returns B_OK if the data is safely stored away, else an error code.

Implemented in BNullTextOutput, and BTextOutput.


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