SObjectizer Priority Definition (so_5/priority.hpp)

sobjectizer · dev/so_5/priority.hpp · cpp · BSD-2-Clause
dev-tools, automation, lang:cpp, tag:concurrency, tag:framework

Defines priority levels for message processing within the SObjectizer framework. Use this to manage task scheduling and execution order in actor-based systems.

// Source: https://github.com/Stiffstream/sobjectizer | License: BSD-2-Clause | Copyright 2002-2013, JSC Intervale
// Provided via justclaw.it.com; keep this notice with the code.
/*
 * SObjectizer-5
 */

/*!
 * \file
 * \since
 * v.5.5.8
 *
 * \brief Definition of priority type.
 */

#if !defined( SO_5_PRIORITY_HPP )
#define SO_5_PRIORITY_HPP

#include <type_traits>
#include <stdexcept>
#include <string>

namespace so_5 {

/*!
 * \since
 * v.5.5.8
 *
 * \brief Definition of supported priorities.
 */
enum class priority_t : unsigned char
	{
		p_min = 0,
		p0 = p_min,
		p1,
		p2,
		p3,
		p4,
		p5,
		p6,
		p7,
		p_max = p7
	};

/*!
 * \since
 * v.5.5.8
 *
 * \brief Helper function for conversion from priority to size_t.
 */
inline std::size_t
to_size_t( priority_t priority )
	{
		return stat

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key