GMime.StreamFilter

g GMime.Stream GMime.Stream GMime.StreamFilter GMime.StreamFilter GMime.Stream->GMime.StreamFilter GObject.Object GObject.Object GObject.Object->GMime.Stream

Subclasses:

None

Methods

Inherited:

GMime.Stream (17), GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

new (stream)

add (filter)

get_owner ()

remove (id)

set_owner (owner)

Virtual Methods

Inherited:

GMime.Stream (10), GObject.Object (7)

Properties

None

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

owner

bool

r

parent_object

GMime.Stream

r

parent GMime.Stream

priv

object

r

private state data

source

GMime.Stream

r

source stream

Class Details

class GMime.StreamFilter(**kwargs)
Bases:

GMime.Stream

Abstract:

No

Structure:

GMime.StreamFilterClass

A GMime.Stream which passes data through any GMime.Filter objects.

classmethod new(stream)
Parameters:

stream (GMime.Stream) – source stream

Returns:

a new filter stream with stream as its source.

Return type:

GMime.Stream

Creates a new GMime.StreamFilter object using stream as the source stream.

add(filter)
Parameters:

filter (GMime.Filter) – a GMime.Filter

Returns:

an id for the filter.

Return type:

int

Adds filter to self. Filters are applied in the same order in which they are added.

get_owner()
Returns:

True if self owns the source stream or False otherwise.

Return type:

bool

Gets whether or not self owns the source stream.

remove(id)
Parameters:

id (int) – filter id

Removed a filter from the stream based on the id (as returned from filter_add).

set_owner(owner)
Parameters:

owner (bool) – True if this stream should own the source stream or False otherwise

Sets whether or not self owns the source stream..

Note: owner should be True if the stream should close() the backend source stream when destroyed or False otherwise.