Objectively 1.0.0
Ultra-lightweight object oriented framework for GNU C.
Data Structures | Typedefs | Functions
Operation.h File Reference

An abstraction for discrete units of work, or tasks. More...

#include <Objectively/Condition.h>
#include <Objectively/Object.h>
#include <Objectively/MutableArray.h>

Go to the source code of this file.

Data Structures

struct  Operation
 An abstraction for discrete units of work, or tasks. More...
 

Typedefs

typedef void(* OperationFunction) (Operation *operation)
 The function type for Operation execution. More...
 

Functions

OBJECTIVELY_EXPORT Class_Operation (void)
 

Detailed Description

An abstraction for discrete units of work, or tasks.

Definition in file Operation.h.

Typedef Documentation

◆ OperationFunction

typedef void(* OperationFunction) (Operation *operation)

The function type for Operation execution.

Parameters
operationThe executing Operation.

Definition at line 42 of file Operation.h.

Function Documentation

◆ _Operation()

OBJECTIVELY_EXPORT Class * _Operation ( void  )

Definition at line 233 of file Operation.c.

233 {
234 static Class *clazz;
235 static Once once;
236
237 do_once(&once, {
238 clazz = _initialize(&(const ClassDef) {
239 .name = "Operation",
240 .superclass = _Object(),
241 .instanceSize = sizeof(Operation),
242 .interfaceOffset = offsetof(Operation, interface),
243 .interfaceSize = sizeof(OperationInterface),
245 });
246 });
247
248 return clazz;
249}
Class * _initialize(const ClassDef *def)
Initializes the given Class.
Definition: Class.c:91
static void initialize(Class *clazz)
Definition: Operation.c:213
long Once
The Once type.
Definition: Once.h:37
#define do_once(once, block)
Executes the given block at most one time.
Definition: Once.h:43
ClassDefs are passed to _initialize via an archetype to initialize a Class.
Definition: Class.h:41
The runtime representation of a Class.
Definition: Class.h:95
Class * _Object(void)
The Object archetype.
Definition: Object.c:136
An abstraction for discrete units of work, or tasks.
Definition: Operation.h:50