Ferrous API Reference

All Types / Ferrous

class TypestateAttribute

public sealed class TypestateAttribute : Attribute

Marks a type as a state in a linear typestate protocol enforced by Ferrous.States and Ferrous.Ownership.

Properties

public bool IsInitial

Gets or sets a value indicating whether this state is an entry (initial) state that may be constructed directly by callers. Non-initial states (false) may only be produced by ConsumesSelfAttribute transition methods.

public bool IsTerminal

Gets or sets a value indicating whether this state is a terminal (end-of-lifecycle) state that is allowed to fall out of scope without transitioning or being consumed (enforced by Ferrous.States FE0303).