A state diagram is a type of diagram used in computer science and related fields to describe the behavior of systems. State diagrams require that the system described is composed of a finite number of states; sometimes, this is indeed the case, while at other times this is a reasonable abstraction.
Statecharts are made from the basic design of the following components:
• an initial state in which the object is created.
• finite set of different states that describe the object / system at a given time
• finite set of events, which in a particular state, or for example, occur after a certain time
• a finite number of transitions / state transitions which describe due to the arrival of events to transition the object from one to the next state
• one or more final states in which the object ceases to exist
States: A state is regarded as the time between two events. States are defined by a unique name for it. If two states within a state diagram with the same name, they describe the same state of an object. However, it also collects anonymous states are defined. If you have two unnamed states in a diagram, so describe these two basic states of an object. Start and end state of an object can be regarded as a special condition types as a start state take place and no transition may follow the final state of an object no state change. A state can connect with the event conditions that must be met in order to reach the next state, or to decide which subsequent state assumed by the object. Through events actions can be triggered within a state of an object.
Events / transitions: A transition is a state transition of an object, which is triggered by an event. An event can occur if one or more conditions are met or an object has received an event-triggered message.
Sub-states: States can be split into several sequential or parallel sub-states. Sub-states are embedded in the actual states. The notation of sub-states is the same as those of states.