sofia-sip/msg.h File Reference


Detailed Description

Base message interface.

Author:
Pekka Pessi <Pekka.Pessi@nokia-email.address.hidden>
Date:
Created: Fri Feb 18 08:54:48 2000 ppessi

#include <sofia-sip/msg_types.h>

Include dependency graph for msg.h:

Go to the source code of this file.

Defines

#define MSG_FLAGS(f, v)
 Test if all the flags in v are set in f.

Enumerations

enum  msg_streaming_status {
  msg_stop_streaming,
  msg_start_streaming
}
enum  msg_flg_user {
  MSG_FLG_COMPACT,
  MSG_FLG_CANONIC,
  MSG_FLG_EXTRACT_COPY,
  MSG_FLG_COMMA_LISTS,
  MSG_FLG_MAILBOX,
  MSG_FLG_CHUNKING,
  MSG_FLG_STREAMING,
  MSG_FLG_THRDSAFE
}
 Flags controlling parser/printer. More...
enum  msg_flg_parser {
  MSG_FLG_HEADERS,
  MSG_FLG_BODY,
  MSG_FLG_CHUNKS,
  MSG_FLG_TRAILERS,
  MSG_FLG_FRAGS,
  MSG_FLG_COMPLETE,
  MSG_FLG_ERROR,
  MSG_FLG_TOOLARGE,
  MSG_FLG_TRUNC,
  MSG_FLG_TIMEOUT
}
 Flags used by parser. More...

Functions

SOFIAPUBFUN msg_pub_tmsg_object (msg_t const *msg)
 Retrieve public message structure.
SOFIAPUBFUN unsigned msg_extract_errors (msg_t const *msg)
 Get error classification flags.
SOFIAPUBFUN msg_header_t ** msg_chain_head (msg_t const *msg)
 Return head of the fragment chain.
SOFIAPUBFUN void msg_unprepare (msg_t *msg)
 Clear 'prepared' flag.
SOFIAPUBFUN int msg_is_prepared (msg_t const *msg)
 Return true if message is prepared.
SOFIAPUBFUN int msg_is_streaming (msg_t const *msg)
 Test if streaming is in progress.
SOFIAPUBFUN void msg_set_streaming (msg_t *msg, enum msg_streaming_status what)
 Enable/disable streaming.
SOFIAPUBFUN unsigned msg_get_flags (msg_t const *msg, unsigned mask)
 Get message flags.
SOFIAPUBFUN unsigned msg_set_flags (msg_t *msg, unsigned mask)
 Set message flags.
SOFIAPUBFUN unsigned msg_zap_flags (msg_t *msg, unsigned mask)
 Clear message flags.


Enumeration Type Documentation

enum msg_flg_parser

Flags used by parser.

Enumerator:
MSG_FLG_HEADERS  Extract headers for this message.
MSG_FLG_BODY  Extract body for this message.
MSG_FLG_CHUNKS  Extract chunks for this message.
MSG_FLG_TRAILERS  Extract trailers for this message.
MSG_FLG_FRAGS  Extract last component of this message.
MSG_FLG_COMPLETE  This message has been completely extracted.
MSG_FLG_ERROR  This message has parsing errors.
MSG_FLG_TOOLARGE  This message is too large.
MSG_FLG_TRUNC  This message is truncated.
MSG_FLG_TIMEOUT  This message has timeout.

enum msg_flg_user

Flags controlling parser/printer.

Enumerator:
MSG_FLG_COMPACT  Use compact form when printing.
MSG_FLG_CANONIC  Use canonic representation when printing.
MSG_FLG_EXTRACT_COPY  Cache a copy of headers when parsing.
MSG_FLG_COMMA_LISTS  Print comma-separated lists instead of separate headers.
MSG_FLG_MAILBOX  Use mailbox format when parsing - in mailbox format message has no body unless Content-Length header is present.
MSG_FLG_CHUNKING  Use multiple parts for message body.
MSG_FLG_STREAMING  Enable streaming - parser gives completed message fragments when they are ready to upper layers.
MSG_FLG_THRDSAFE  Make messages threadsafe.

enum msg_streaming_status

Enumerator:
msg_stop_streaming  Disable streaming.
msg_start_streaming  Enable streaming.


Function Documentation

SOFIAPUBFUN msg_pub_t* msg_object ( msg_t const *  msg  ) 

Retrieve public message structure.

This function returns a pointer to the public message structure.

Parameters:
msg pointer to msg object
Returns:
A pointer to the public message structure, or NULL if none.


Sofia-SIP 1.12.1 - Copyright (C) 2006 Nokia Corporation. All rights reserved. Licensed under the terms of the GNU Lesser General Public License.