Utility Classes :: Length

Overview

The Length() class is used when you don't care about the type of a sequence, or its contents, only its length.

The Length() constructor takes a single argument, the desired sequence length. If the object being checked is not a sequence, or of the wrong length, things will blow up.

The following signature asserts that the sole parameter is a sequence -- regardless of type -- containing eight elements:

@accepts(Length(8))

Details

Valid XHTML 1.0 Transitional