CERN -> IPT Group -> FrameMaker at CERN
Information Service User's Guide

15.6 ISInfoAny

ISInfo, ISistream


Synopsis
#include <is/infoany.h>
ISInfoAny isa;


Description

This class is used to read the information whose type is unknown at compilation time. The access to the information attributes is organized in a stream like manner. Single-value attributes can be read using input member operators of this class (>>). Multi-value attributes can be read using one of the get methods. Every call to either one of the the input operators or get methods advances the current stream position to the next attribute. The reset method can be used to reset the current stream position to the beginning.


Example
1: #include "is/infoany.h"
2:
3: IPCPartition partition( "MyPartition" );
4: ISInfoIterator ii( partition, "MyServer" );
5: ISInfoAny isa;
6: while ( ii() ) {
7: ii.value( isa );
8: cout << isa;
9: }


Public Member Functions
ISType::Basic
getAttributeType ( ) const;
Returns type of the attribute at the current stream position. For the definition of the ISType::Basic enumeration see Chapter 15.19.
bool
isAttributeArray ( ) const;
Returns true if the attribute at the current stream position is an array, otherwise returns false.
size_t
countAttributes  ( ) const;
Returns a number of attributes for the information object.
void
reset ( );
Set stream position to the beginning of the stream.

The public >> operators and get member functions are inherited from the ISistream class. For their description see Chapter 15.20.


Related Global Operator
std::ostream  & operator<< ( std::ostream & out, ISInfoAny & isa );
Print out value of the isa to the standard output stream out.


2 July 1998 - WebMaster
Copyright © CERN 1998