![]() |
![]() |
![]() |
GMime 2.6 Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy |
GMimePart; GMimePart * g_mime_part_new (void
); GMimePart * g_mime_part_new_with_type (const char *type
,const char *subtype
); void g_mime_part_set_content_description (GMimePart *mime_part
,const char *description
); const char * g_mime_part_get_content_description (GMimePart *mime_part
); void g_mime_part_set_content_id (GMimePart *mime_part
,const char *content_id
); const char * g_mime_part_get_content_id (GMimePart *mime_part
); void g_mime_part_set_content_md5 (GMimePart *mime_part
,const char *content_md5
); const char * g_mime_part_get_content_md5 (GMimePart *mime_part
); gboolean g_mime_part_verify_content_md5 (GMimePart *mime_part
); void g_mime_part_set_content_location (GMimePart *mime_part
,const char *content_location
); const char * g_mime_part_get_content_location (GMimePart *mime_part
); void g_mime_part_set_content_encoding (GMimePart *mime_part
,GMimeContentEncoding encoding
); GMimeContentEncoding g_mime_part_get_content_encoding (GMimePart *mime_part
); GMimeContentEncoding g_mime_part_get_best_content_encoding (GMimePart *mime_part
,GMimeEncodingConstraint constraint
); void g_mime_part_set_filename (GMimePart *mime_part
,const char *filename
); const char * g_mime_part_get_filename (GMimePart *mime_part
); GMimeDataWrapper * g_mime_part_get_content_object (GMimePart *mime_part
); void g_mime_part_set_content_object (GMimePart *mime_part
,GMimeDataWrapper *content
);
GMimePart * g_mime_part_new (void
);
Creates a new MIME Part object with a default content-type of text/plain.
Returns : | an empty MIME Part object with a default content-type of text/plain. |
GMimePart * g_mime_part_new_with_type (const char *type
,const char *subtype
);
Creates a new MIME Part with a sepcified type.
type : |
content-type string |
subtype : |
content-subtype string |
Returns : | an empty MIME Part object with the specified content-type. |
void g_mime_part_set_content_description (GMimePart *mime_part
,const char *description
);
Set the content description for the specified mime part.
mime_part : |
a GMimePart object |
description : |
content description |
const char * g_mime_part_get_content_description (GMimePart *mime_part
);
Gets the value of the Content-Description for the specified mime
part if it exists or NULL
otherwise.
mime_part : |
a GMimePart object |
Returns : | the content description for the specified mime part. |
void g_mime_part_set_content_id (GMimePart *mime_part
,const char *content_id
);
Set the content id for the specified mime part.
mime_part : |
a GMimePart object |
content_id : |
content id |
const char * g_mime_part_get_content_id (GMimePart *mime_part
);
Gets the content-id of the specified mime part if it exists, or
NULL
otherwise.
mime_part : |
a GMimePart object |
Returns : | the content id for the specified mime part. |
void g_mime_part_set_content_md5 (GMimePart *mime_part
,const char *content_md5
);
Set the content md5 for the specified mime part.
const char * g_mime_part_get_content_md5 (GMimePart *mime_part
);
Gets the md5sum contained in the Content-Md5 header of the
specified mime part if it exists, or NULL
otherwise.
mime_part : |
a GMimePart object |
Returns : | the content md5 for the specified mime part. |
gboolean g_mime_part_verify_content_md5 (GMimePart *mime_part
);
Verify the content md5 for the specified mime part.
void g_mime_part_set_content_location (GMimePart *mime_part
,const char *content_location
);
Set the content location for the specified mime part.
mime_part : |
a GMimePart object |
content_location : |
content location |
const char * g_mime_part_get_content_location (GMimePart *mime_part
);
Gets the value of the Content-Location header if it exists, or
NULL
otherwise.
mime_part : |
a GMimePart object |
Returns : | the content location for the specified mime part. |
void g_mime_part_set_content_encoding (GMimePart *mime_part
,GMimeContentEncoding encoding
);
Set the content encoding for the specified mime part.
mime_part : |
a GMimePart object |
encoding : |
a GMimeContentEncoding |
GMimeContentEncoding g_mime_part_get_content_encoding (GMimePart *mime_part
);
Gets the content encoding of the mime part.
mime_part : |
a GMimePart object |
Returns : | the content encoding for the specified mime part. |
GMimeContentEncoding g_mime_part_get_best_content_encoding (GMimePart *mime_part
,GMimeEncodingConstraint constraint
);
Calculates the most efficient content encoding for the mime_part
given the constraint
.
mime_part : |
a GMimePart object |
constraint : |
a GMimeEncodingConstraint |
Returns : | the best content encoding for the specified mime part. |
void g_mime_part_set_filename (GMimePart *mime_part
,const char *filename
);
Sets the "filename" parameter on the Content-Disposition and also sets the "name" parameter on the Content-Type.
mime_part : |
a GMimePart object |
filename : |
the filename of the Mime Part's content |
const char * g_mime_part_get_filename (GMimePart *mime_part
);
Gets the filename of the specificed mime part, or NULL
if the mime
part does not have the filename or name parameter set.
mime_part : |
a GMimePart object |
Returns : | the filename of the specified MIME Part. It first checks to see if the "filename" parameter was set on the Content-Disposition and if not then checks the "name" parameter in the Content-Type. |
GMimeDataWrapper * g_mime_part_get_content_object (GMimePart *mime_part
);
Gets the internal data-wrapper of the specified mime part, or NULL
on error.
mime_part : |
a GMimePart object |
Returns : | the data-wrapper for the mime part's contents. |
void g_mime_part_set_content_object (GMimePart *mime_part
,GMimeDataWrapper *content
);
Sets the content object on the mime part.
mime_part : |
a GMimePart object |
content : |
a GMimeDataWrapper content object |