cmd_helper.h File Reference

Helper functions to extract data from command parameters. More...

#include "core/enum_type.hpp"
#include "core/bitmath_func.hpp"

Go to the source code of this file.

Functions

template<typename T , uint S, uint N, typename U >
static T Extract (U v)
 Extracts a given type from a value.

Detailed Description

Helper functions to extract data from command parameters.

Definition in file cmd_helper.h.


Function Documentation

template<typename T , uint S, uint N, typename U >
static T Extract ( v  )  [inline, static]

Extracts a given type from a value.

Template Parameters:
T The type of data we're looking for.
S The offset in the data.
N The amount of bits to read.
U The type of data passed to us.
Parameters:
v The data to extract the value from.

Definition at line 26 of file cmd_helper.h.

References GB(), and IsInsideMM().


Generated on Fri May 27 04:19:53 2011 for OpenTTD by  doxygen 1.6.1