VR-Forces 4.3.1 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions
makVrf::DtOctalValidator Class Reference

Validator which will validate and return octal values that can be used for mode code IFF validation. More...

Inheritance diagram for makVrf::DtOctalValidator:
Inheritance graph
[legend]

Public Member Functions

 DtOctalValidator (QObject *parent)
virtual ~DtOctalValidator ()
virtual State validate (QString &, int &) const
 Makes sure that each digit is b/t 0 and 7 (and an integer)
virtual int pack (const QString &) const
 Packs the given integer value into expected IFF octal representation and returns the packed value.
virtual QString unpack (int, int digits=4) const
 Opposite of pack.

Detailed Description

Validator which will validate and return octal values that can be used for mode code IFF validation.

Constructor & Destructor Documentation

makVrf::DtOctalValidator::DtOctalValidator ( QObject parent)
virtual makVrf::DtOctalValidator::~DtOctalValidator ( )
virtual

Member Function Documentation

virtual State makVrf::DtOctalValidator::validate ( QString &  ,
int  
) const
virtual

Makes sure that each digit is b/t 0 and 7 (and an integer)

virtual int makVrf::DtOctalValidator::pack ( const QString &  ) const
virtual

Packs the given integer value into expected IFF octal representation and returns the packed value.

The packing goes in reverse order according to the spec so, for example, if the number is 2376, it would be packed 6732 using 3 bits for each element

virtual QString makVrf::DtOctalValidator::unpack ( int  ,
int  digits = 4 
) const
virtual

Opposite of pack.

Takes an integer and unpacks it to the correct octal representation as entered above. Since IFF uses (at the most) 4 values (12 bits), this will only decode the first 12 bits. Pass in the number of digits to unpack (default is 4)


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

Document ID: Generated on Wed Jul 29 00:55:00 EDT 2015 from SVN revision 155257
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)