NAME

App::Wubot::Reactor::CaptureData - capture data from a field using a regexp

VERSION

version 0.4.0

SYNOPSIS

- name: capture data from 'title' field and store captured data in 'size' field
  plugin: CaptureData
  config:
    source_field: title
    regexp: '^M ([\d\.]+),'
    target_field: size

- name: capture data from 'title' field, get there regexp from 'somefield', and store results in 'foo'
  plugin: CaptureData
  config:
    source_field: abc
    regexp_field: somefield
    target_field: foo

- name: get first group of digits from field 'x' and replace contents of 'x' field with captured digits
  plugin: CaptureData
  config:
    field: x
    regexp: '([\d\.]+),'

SUBROUTINES/METHODS

react( $message, $config )

The standard reactor plugin react() method.