# Spec GenericShape
A variable gapped shape.

Extends | Shape
All Extended | Shape
Defined in | <seqan/index.h>
Signature | `template <typename TValue> class Shape<TValue, GenericShape>;`

## Template Parameters

`TValue` | The Value type of the string the shape is applied to (e.g. `Dna`).

## Member Function Overview

- `Shape::Shape();, Shape::Shape(q);, Shape::Shape(shape);, Shape::Shape(bitmap);, Shape::Shape(predefined);`
  Constructor

## Interface Function Overview

### Interface Functions Inherited From Shape

- `hash`
- `hash2`
- `hash2Next`
- `hash2Upper`
- `hashInit`
- `hashNext`
- `hashUpper`
- `length`
- `resize`
- `shapeToString`
- `stringToShape`
- `unhash`
- `value`
- `weight`

## Interface Metafunction Overview

### Interface Metafunctions Inherited From Shape

- `Host`
- `LENGTH`
- `Size`
- `Value`
- `ValueSize`
- `WEIGHT`

## Detailed Description

A GenericShape must be initialized first with a valid shape. To do so, call stringToShape.

## See Also

- GappedShape
- OneGappedShape

## Member Functions Detail

### `Shape::Shape(); Shape::Shape(q); Shape::Shape(shape); Shape::Shape(bitmap); Shape::Shape(predefined);`

Constructor

#### Parameters

`predefined` | Any instance of a predefined shape spec (e.g. `ShapePatternHunter`).
`q` | Creates an ungapped q-gram.
`shape` | Any other gapped/ungapped shape.
`bitmap` | Bitmap string. Sequence of '0's and '1's. See stringToShape

#### Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

#### See Also

- HardwiredShape

#### Dox Sources

    /*!
     * @class GenericShape
     *
     * @extends Shape
     *
     * @headerfile <seqan/index.h>
     *
     * @brief A variable gapped shape.
     *
     * @signature template <typename TValue> class Shape<TValue, GenericShape>;
     *
     * @tparam TValue The @link Value @endlink type of the string the shape is
     *                applied to (e.g. <tt>Dna</tt>).
     *
     * A GenericShape must be initialized first with a valid shape. To do so, call
     * @link Shape#stringToShape @endlink.
     *
     * @see GappedShape
     * @see OneGappedShape
     *
     * @fn GenericShape::Shape
     *
     * @brief Constructor
     *
     * @signature Shape::Shape();
     * @signature Shape::Shape(q);
     * @signature Shape::Shape(shape);
     * @signature Shape::Shape(bitmap);
     * @signature Shape::Shape(predefined);
     *
     * @param predefined Any instance of a predefined shape spec (e.g.
     *                   <tt>ShapePatternHunter</tt>).
     * @param q Creates an ungapped q-gram.
     * @param shape Any other gapped/ungapped shape.
     * @param bitmap Bitmap string. Sequence of '0's and '1's. See @link
     *               Shape#stringToShape @endlink
     *
     * @see HardwiredShape
     */