str 構造体テンプレート

struct op::str

str は、sub_match を等価な std::string に変換する PolymorphicFunctionObject である。

概要

// ヘッダ:<boost/xpressive/regex_actions.hpp>

struct str {
  // メンバクラス、構造体、共用体
  template<typename Sig>
  struct result {
  };
  template<typename This, typename Sub>
  struct result<This(Sub)> {
    // 型
    typedef remove_reference< Sub >::type::string_type type;
  };

  // 公開メンバ関数
  template<typename Sub> Sub::string_type operator()(Sub const &) const;
};

説明

str 公開メンバ関数

template<typename Sub>
Sub::string_type operator()(Sub const &sub) const
パラメータ

sub -- sub_match オブジェクト。

戻り値

sub.str()