public static function hasMany($attr, $options=null)
    {
        $cls = get_called_class();

        if (!array_key_exists($cls, self::$_has_many)) {
            self::$_has_many[$cls] = array();
        }

        self::$_has_many[$cls][$attr] = $options ? $options : false;

        $klass = self::hasManyClass($attr);
        $ids   = strtolower($klass)."_ids";
        self::$_has_many_maps[$cls][$ids] = $attr;
    }