A State represents a situation where some invariant condition holds; this condition can be static (waiting for an event) or dynamic (performing a set of activities). State modeling is usually related to Classes, and describes the enable-able states a Class or element can be in and the transitions that enable the element to move there. There are two types of State: Simple States and Composite States, both created from the 'State' icon from the Toolbox.
Furthermore, there are pseudostates, resembling some aspect of a State but with a pre-defined implication. Pseudostates model complex transitional paths, and classify common StateMachine behavior.
You can define entry, internal and exit actions for a State using operations. State elements can have three operations (entry, do and exit) that are created and defined through the 'Behavior' tab of the Features window (Start > All Windows > Design > Element Features > Features). The tab displays only when the selected element is a State. It automatically lists the three operations, and you can either type a text value in the 'Name/Comment' field, or assign a behavior element of code using the 'Behavior' page of the Properties window (see the Operation Behavior Help topic).
If a State element has features such as operations, internal triggers or inherited operations and attributes, the depiction of the element in a diagram has a line under the element name. This line persists if the features are hidden. The line also displays if the 'Show State Compartment' checkbox is selected on the 'Objects' page of the 'Preferences' dialog (select the 'Start > Appearance > Preferences > Preferences' ribbon option and the 'Objects' page).
OMG UML Specification:
The OMG Unified Modeling Language specification, (v2.5.1, p.308) states:
A State models a situation in the execution of a StateMachine Behavior during which some invariant condition holds. In most cases this condition is not explicitly defined, but is implied, usually through the name associated with the State.