LIEF: Library to Instrument Executable Formats Version 0.17.0
Loading...
Searching...
No Matches
LIEF::PE::ResourceVersion Class Reference

Representation of the data associated with the RT_VERSION entry. More...

#include <ResourceVersion.hpp>

Inheritance diagram for LIEF::PE::ResourceVersion:
Collaboration diagram for LIEF::PE::ResourceVersion:

Classes

struct  fixed_file_info_t
 This structure represents the VS_FIXEDFILEINFO structure defined in verrsrc.h. More...

Public Member Functions

 ResourceVersion (const ResourceVersion &)=default
ResourceVersionoperator= (const ResourceVersion &)=default
 ResourceVersion (ResourceVersion &&)=default
ResourceVersionoperator= (ResourceVersion &&)=default
 ~ResourceVersion () override=default
const fixed_file_info_tfile_info () const
 Return the fixed file info (VS_FIXEDFILEINFO).
fixed_file_info_tfile_info ()
ResourceStringFileInfostring_file_info ()
 Return the StringFileInfo element.
const ResourceStringFileInfostring_file_info () const
ResourceVarFileInfovar_file_info ()
 Return the VarFileInfo element.
uint16_t type () const
 The type of data in the version resource.
const std::u16string & key () const
 The Unicode string L"VS_VERSION_INFO".
std::string key_u8 () const
 The key as an utf8 string.
ResourceVersiontype (uint16_t value)
ResourceVersionkey (std::u16string value)
const ResourceVarFileInfovar_file_info () const
ResourceVersionvar_file_info (ResourceVarFileInfo info)
ResourceVersionstring_file_info (ResourceStringFileInfo info)
void accept (Visitor &visitor) const override
Public Member Functions inherited from LIEF::Object
 Object ()
 Object (const Object &other)
Objectoperator= (const Object &other)
 Object (Object &&other) noexcept=default
Objectoperator= (Object &&other) noexcept=default
template<class T>
output_t< T > as ()
template<class T>
output_const_t< T > as () const
virtual bool operator== (const Object &other) const
virtual bool operator!= (const Object &other) const
virtual ~Object ()

Static Public Member Functions

static result< ResourceVersionparse (const ResourceData &node)
static result< ResourceVersionparse (const uint8_t *p, size_t sz)
static result< ResourceVersionparse (BinaryStream &stream)

Additional Inherited Members

Public Types inherited from LIEF::Object
template<class T>
using output_t = add_pointer_t<decay_t<T>>
template<class T>
using output_const_t = add_pointer_t<add_const_t<decay_t<T>>>

Detailed Description

Representation of the data associated with the RT_VERSION entry.

See: VS_VERSIONINFO at https://learn.microsoft.com/en-us/windows/win32/menurc/vs-versioninfo

Constructor & Destructor Documentation

◆ ResourceVersion() [1/2]

LIEF::PE::ResourceVersion::ResourceVersion ( const ResourceVersion & )
default

◆ ResourceVersion() [2/2]

LIEF::PE::ResourceVersion::ResourceVersion ( ResourceVersion && )
default

References ResourceVersion().

◆ ~ResourceVersion()

LIEF::PE::ResourceVersion::~ResourceVersion ( )
overridedefault

Member Function Documentation

◆ accept()

void LIEF::PE::ResourceVersion::accept ( Visitor & visitor) const
overridevirtual

Implements LIEF::Object.

References LIEF_API.

◆ file_info() [1/2]

fixed_file_info_t & LIEF::PE::ResourceVersion::file_info ( )
inline

◆ file_info() [2/2]

const fixed_file_info_t & LIEF::PE::ResourceVersion::file_info ( ) const
inline

Return the fixed file info (VS_FIXEDFILEINFO).

◆ key() [1/2]

const std::u16string & LIEF::PE::ResourceVersion::key ( ) const
inline

The Unicode string L"VS_VERSION_INFO".

◆ key() [2/2]

ResourceVersion & LIEF::PE::ResourceVersion::key ( std::u16string value)
inline

References ResourceVersion().

◆ key_u8()

std::string LIEF::PE::ResourceVersion::key_u8 ( ) const

The key as an utf8 string.

◆ operator=() [1/2]

ResourceVersion & LIEF::PE::ResourceVersion::operator= ( const ResourceVersion & )
default

References ResourceVersion().

◆ operator=() [2/2]

ResourceVersion & LIEF::PE::ResourceVersion::operator= ( ResourceVersion && )
default

References ResourceVersion().

◆ parse() [1/3]

result< ResourceVersion > LIEF::PE::ResourceVersion::parse ( BinaryStream & stream)
static

◆ parse() [2/3]

result< ResourceVersion > LIEF::PE::ResourceVersion::parse ( const ResourceData & node)
static

◆ parse() [3/3]

result< ResourceVersion > LIEF::PE::ResourceVersion::parse ( const uint8_t * p,
size_t sz )
static

◆ string_file_info() [1/3]

ResourceStringFileInfo * LIEF::PE::ResourceVersion::string_file_info ( )
inline

Return the StringFileInfo element.

Referenced by string_file_info().

◆ string_file_info() [2/3]

const ResourceStringFileInfo * LIEF::PE::ResourceVersion::string_file_info ( ) const
inline

◆ string_file_info() [3/3]

ResourceVersion & LIEF::PE::ResourceVersion::string_file_info ( ResourceStringFileInfo info)
inline

References ResourceVersion().

◆ type() [1/2]

uint16_t LIEF::PE::ResourceVersion::type ( ) const
inline

The type of data in the version resource.

  • 1 if it contains text data
  • 0 if it contains binary data

◆ type() [2/2]

ResourceVersion & LIEF::PE::ResourceVersion::type ( uint16_t value)
inline

References ResourceVersion().

◆ var_file_info() [1/3]

ResourceVarFileInfo * LIEF::PE::ResourceVersion::var_file_info ( )
inline

Return the VarFileInfo element.

Referenced by var_file_info().

◆ var_file_info() [2/3]

const ResourceVarFileInfo * LIEF::PE::ResourceVersion::var_file_info ( ) const
inline

◆ var_file_info() [3/3]

ResourceVersion & LIEF::PE::ResourceVersion::var_file_info ( ResourceVarFileInfo info)
inline

References ResourceVersion().


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