DOKK / manpages / debian 12 / sympa / Sympa::Request.3sympa.en
Sympa::Request(3Sympa) sympa 6.2.70 Sympa::Request(3Sympa)

Sympa::Request - Requests for operation

  use Sympa::Request;
  my $request = Sympa::Request->new($serialized, context => $list);
  my $request = Sympa::Request->new(context => $list, action => 'last');

Sympa::Request implements serializable object representing requests by users.

Constructor. Creates a new Sympa::Request object.

Parameters:

$serialized
Serialized request.
Context. Sympa::List object, Robot or '*'.
Name of requested action.
Metadata and attributes.

Returns:

A new instance of Sympa::Request, or undef, if something went wrong.

Constructor. OBSOLETED. Creates Sympa::Request object from paired options.
Copy constructor. Gets deep copy of instance.
Serializer. Returns serialized data of object.
Instance method. TBD.
Instance method. Name of a subclass of Sympa::Request::Handler to process request.
Instance method. Gets unique identifier of instance.

Context and metadata given to constructor are accessible as hash elements of object. They are given by request spool. See "Context and metadata" in Sympa::Spool::Auth for details.

These are accessible as hash elements of objects. There are attributes including:

{custom_attribute}
Custom attribute connected to requested action.
{gecos}
Display name of user sending request.
{sender}
E-mail of user who sent the request.

Sympa::Request object includes number of slots as hash items: metadata, context and attributes. Metadata including context are given by spool: See "Marshaling and unmarshaling metadata" in Sympa::Spool.

Logically, objects are stored into physical spool as serialized form and deserialized when they are fetched from spool. Attributes are encoded in "X-Sympa-*:" pseudo-header fields.

See also "Serialization" in Sympa::Message for example.

Sympa::Request::Collection, Sympa::Request::Handler, Sympa::Request::Message, Sympa::Spool::Auth.

Sympa::Request appeared on Sympa 6.2.10.

2023-01-26 6.2.70