Back to index

enigmail  1.4.3
Public Member Functions | Static Public Member Functions | Static Public Attributes
Elf_Rela Class Reference

#include <elfxx.h>

Inheritance diagram for Elf_Rela:
Inheritance graph
[legend]
Collaboration diagram for Elf_Rela:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 Elf_Rela (std::ifstream &file, char ei_class, char ei_data)
void serialize (std::ofstream &file, char ei_class, char ei_data)

Static Public Member Functions

static unsigned int size (char ei_class)

Static Public Attributes

static const unsigned int sh_type = SHT_RELA
static const unsigned int d_tag = DT_RELA
static const unsigned int d_tag_count = DT_RELACOUNT

Detailed Description

Definition at line 564 of file elfxx.h.


Constructor & Destructor Documentation

Elf_Rela::Elf_Rela ( std::ifstream &  file,
char  ei_class,
char  ei_data 
) [inline]

Definition at line 566 of file elfxx.h.

    : serializable<Elf_Rela_Traits>(file, ei_class, ei_data) {};

Member Function Documentation

void serializable< Elf_Rela_Traits >::serialize ( std::ofstream &  file,
char  ei_class,
char  ei_data 
) [inline, inherited]

Definition at line 251 of file elfxx.h.

    {
        if (ei_class == ELFCLASS32) {
            typename T::Type32 e;
            if (ei_data == ELFDATA2LSB) {
                T::template swap<little_endian>(*this, e);
                file.write((char *)&e, sizeof(e));
                return;
            } else if (ei_data == ELFDATA2MSB) {
                T::template swap<big_endian>(*this, e);
                file.write((char *)&e, sizeof(e));
                return;
            }
        } else if (ei_class == ELFCLASS64) {
            typename T::Type64 e;
            if (ei_data == ELFDATA2LSB) {
                T::template swap<little_endian>(*this, e);
                file.write((char *)&e, sizeof(e));
                return;
            } else if (ei_data == ELFDATA2MSB) {
                T::template swap<big_endian>(*this, e);
                file.write((char *)&e, sizeof(e));
                return;
            }
        }
        throw std::runtime_error("Unsupported ELF class or data encoding");
    }
static unsigned int serializable< Elf_Rela_Traits >::size ( char  ei_class) [inline, static, inherited]

Definition at line 279 of file elfxx.h.

    {
        if (ei_class == ELFCLASS32)
            return sizeof(typename T::Type32);
        else if (ei_class == ELFCLASS64)
            return sizeof(typename T::Type64);
        return 0;
    }

Member Data Documentation

const unsigned int Elf_Rela::d_tag = DT_RELA [static]

Definition at line 570 of file elfxx.h.

const unsigned int Elf_Rela::d_tag_count = DT_RELACOUNT [static]

Definition at line 571 of file elfxx.h.

const unsigned int Elf_Rela::sh_type = SHT_RELA [static]

Definition at line 569 of file elfxx.h.


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