Class MsgBruteForce::In

Nested Relationships

This class is a nested type of Class MsgBruteForce.

Nested Types

Class Documentation

class MsgBruteForce::In

This class is accessible via DeviceAPI.message_in if MsgBruteForce is specified in FLAMEGPU_AGENT_FUNCTION It gives access to functionality for reading brute force messages

Public Functions

__device__ inline In(Curve::NamespaceHash agentfn_hash, Curve::NamespaceHash msg_hash, const void *metadata)

Constructer Initialises member variables

  • agentfn_hash – Added to msg_hash to produce combined_hash

  • msg_hash – Added to agentfn_hash to produce combined_hash

  • metadata – Reinterpreted as type MsgBruteForce::MetaData to extract length

__device__ inline size_type size(void) const

Returns the number of elements in the message list.

__device__ inline iterator begin(void) const

Returns an iterator to the start of the message list

__device__ inline iterator end(void) const

Returns an iterator to the position beyond the end of the message list

class iterator

Stock iterator for iterating MsgBruteForce::In::Message objects

Public Functions

__device__ inline iterator(const In &parent, size_type index)

Constructor This iterator is constructed by MsgBruteForce::begin()



__device__ inline iterator &operator++()

Moves to the next message

__device__ inline bool operator==(const iterator &rhs) const

Equality operator Compares message

__device__ inline bool operator!=(const iterator &rhs) const

Inequality operator Compares message

__device__ inline Message &operator*()

Dereferences the iterator to return the message object, for accessing variables

class Message

Provides access to a specific message Returned by the iterator



Public Functions

__device__ inline Message(const MsgBruteForce::In &parent)

Constructs a message and directly initialises all of it’s member variables index is always init to 0


See member variable documentation for their purposes

__device__ inline Message(const MsgBruteForce::In &parent, size_type index)

Alternate constructor, allows index to be manually set


I think this is unused

__host__ __device__ inline bool operator==(const Message &rhs) const

Equality operator Compares all internal member vars for equality


Does not compare _parent

__host__ __device__ inline bool operator!=(const Message &rhs) const

Inequality operator Returns inverse of equality operator


operator==(const Message&)

__host__ __device__ inline Message &operator++()

Updates the message to return variables from the next message in the message list


Returns itself

__host__ __device__ inline size_type getIndex() const

Returns the index of the message within the full message list

template<typename T, size_type N>
__device__ T getVariable(const char (&variable_name)[N]) const

Returns the value for the current message attached to the named variable


variable_name – Name of the variable

Template Parameters
  • T – type of the variable

  • N – Length of variable name (this should be implicit if a string literal is passed to variable name)


The specified variable, else 0x0 if an error occurs