Sat Mar 24 23:51:54 2007

Asterisk developer's documentation


ast_channel Struct Reference

#include <channel.h>

Collaboration diagram for ast_channel:

Collaboration graph
[legend]

Data Fields

ast_channel_bridge
int _softhangup
int _state
char accountcode [AST_MAX_ACCOUNT_CODE]
int adsicpe
int alertpipe [2]
int amaflags
char * appl
pthread_t blocker
const char * blockproc
char call_forward [AST_MAX_EXTENSION]
ast_group_t callgroup
ast_cdrcdr
int cdrflags
ast_callerid cid
char context [AST_MAX_CONTEXT]
char * data
ast_frame dtmff
char dtmfq [AST_MAX_EXTENSION]
char exten [AST_MAX_EXTENSION]
int fdno
int fds [AST_MAX_FDS]
unsigned int fin
unsigned int flags
unsigned int fout
ast_generatorgenerator
void * generatordata
int hangupcause
unsigned long insmpl
char language [MAX_LANGUAGE]
ast_mutex_t lock
char macrocontext [AST_MAX_CONTEXT]
char macroexten [AST_MAX_EXTENSION]
int macropriority
ast_channelmasq
ast_channelmasqr
ast_channel_monitormonitor
void * music_state
char musicclass [MAX_MUSICCLASS]
char name [AST_CHANNEL_NAME]
int nativeformats
ast_channelnext
int oldwriteformat
unsigned long outsmpl
ast_pbxpbx
ast_group_t pickupgroup
int priority
int rawreadformat
int rawwriteformat
int readformat
ast_framereadq
ast_trans_pvt * readtrans
int rings
sched_context * sched
ast_channel_spy_list * spies
ast_filestream * stream
int streamid
ast_channel_techtech
void * tech_pvt
void * timingdata
int timingfd
int(* timingfunc )(void *data)
unsigned short transfercapability
const char * type
char uniqueid [32]
varshead varshead
ast_filestream * vstream
int vstreamid
time_t whentohangup
int writeformat
ast_trans_pvt * writetrans
tone_zonezone

Detailed Description

Main Channel structure associated with a channel. This is the side of it mostly used by the pbx and call management.

Definition at line 252 of file channel.h.


Field Documentation

struct ast_channel* _bridge

Who are we bridged to, if we're bridged. Who is proxying for us, if we are proxied (i.e. chan_agent). Do not access directly, use ast_bridged_channel(chan)

Definition at line 281 of file channel.h.

int _softhangup

Whether or not we have been hung up... Do not set this value directly, use ast_softhangup

Definition at line 290 of file channel.h.

int _state

State of line -- Don't write directly, use ast_setstate

Definition at line 326 of file channel.h.

char accountcode[AST_MAX_ACCOUNT_CODE]

Account code for billing

Definition at line 361 of file channel.h.

int adsicpe

Whether or not ADSI is detected on CPE

Definition at line 365 of file channel.h.

int amaflags

Set BEFORE PBX is started to determine AMA flags

Definition at line 359 of file channel.h.

char* appl

Current application

Definition at line 301 of file channel.h.

pthread_t blocker

If anyone is blocking, this is them

Definition at line 294 of file channel.h.

const char* blockproc

Procedure causing blocking

Definition at line 298 of file channel.h.

char call_forward[AST_MAX_EXTENSION]

Where to forward to if asked to dial on this interface

Definition at line 367 of file channel.h.

struct ast_cdr* cdr

Call Detail Record

Definition at line 363 of file channel.h.

int cdrflags

Call Detail Record Flags

Definition at line 287 of file channel.h.

char context[AST_MAX_CONTEXT]

Current extension context

Definition at line 340 of file channel.h.

char* data

Data passed to current application

Definition at line 303 of file channel.h.

struct ast_frame dtmff

DTMF frame

Definition at line 354 of file channel.h.

char dtmfq[AST_MAX_EXTENSION]

Any/all queued DTMF characters

Definition at line 352 of file channel.h.

char exten[AST_MAX_EXTENSION]

Current extension number

Definition at line 348 of file channel.h.

int fdno

Which fd had an event detected on

Definition at line 306 of file channel.h.

int fds[AST_MAX_FDS]

File descriptor for channel -- Drivers will poll on these file descriptors, so at least one must be non -1.

Definition at line 267 of file channel.h.

unsigned int flags

channel flags of AST_FLAG_ type

Definition at line 396 of file channel.h.

struct ast_generator* generator

Current active data generator

Definition at line 276 of file channel.h.

void* generatordata

Current generator data if there is any

Definition at line 274 of file channel.h.

unsigned long insmpl

Track the read/written samples for monitor use

Definition at line 376 of file channel.h.

char language[MAX_LANGUAGE]

Language requested for voice prompts

Definition at line 263 of file channel.h.

ast_mutex_t lock

Lock, can be used to lock a channel for some operations

Definition at line 296 of file channel.h.

char macrocontext[AST_MAX_CONTEXT]

Current non-macro context

Definition at line 342 of file channel.h.

char macroexten[AST_MAX_EXTENSION]

Current non-macro extension

Definition at line 344 of file channel.h.

int macropriority

Current non-macro priority

Definition at line 346 of file channel.h.

struct ast_channel* masq

Channel that will masquerade as us

Definition at line 283 of file channel.h.

struct ast_channel* masqr

Who we are masquerading as

Definition at line 285 of file channel.h.

void* music_state

Music State

Definition at line 272 of file channel.h.

char musicclass[MAX_MUSICCLASS]

Default music class

Definition at line 270 of file channel.h.

char name[AST_CHANNEL_NAME]

ASCII unique channel name

Definition at line 254 of file channel.h.

int nativeformats

Kinds of data this channel can natively handle

Definition at line 331 of file channel.h.

struct ast_channel* next

For easy linking

Definition at line 416 of file channel.h.

int oldwriteformat

Original writer format

Definition at line 318 of file channel.h.

struct ast_pbx* pbx

PBX private structure

Definition at line 357 of file channel.h.

int rawreadformat

Raw read format

Definition at line 408 of file channel.h.

int rawwriteformat

Raw write format

Definition at line 410 of file channel.h.

int readformat

Requested read format

Definition at line 333 of file channel.h.

struct ast_trans_pvt* readtrans

Read translation path

Definition at line 406 of file channel.h.

int rings

Number of rings so far

Definition at line 328 of file channel.h.

struct sched_context* sched

Schedule context

Definition at line 308 of file channel.h.

struct ast_channel_spy_list* spies

Chan Spy stuff

Definition at line 413 of file channel.h.

struct ast_filestream* stream

Stream itself.

Definition at line 312 of file channel.h.

int streamid

For streaming playback, the schedule ID

Definition at line 310 of file channel.h.

struct ast_channel_tech* tech

Technology (point to channel driver)

Definition at line 257 of file channel.h.

void* tech_pvt

Private data used by the technology driver

Definition at line 260 of file channel.h.

int timingfd

Timing fd

Definition at line 321 of file channel.h.

unsigned short transfercapability

ISDN Transfer Capbility - AST_FLAG_DIGITAL is not enough

Definition at line 399 of file channel.h.

const char* type

Type of channel

Definition at line 265 of file channel.h.

struct ast_filestream* vstream

Video Stream itself.

Definition at line 316 of file channel.h.

int vstreamid

For streaming video playback, the schedule ID

Definition at line 314 of file channel.h.

time_t whentohangup

Non-zero, set to actual time when channel is to be hung up

Definition at line 292 of file channel.h.

int writeformat

Requested write format

Definition at line 335 of file channel.h.

struct ast_trans_pvt* writetrans

Write translation path

Definition at line 404 of file channel.h.

struct tone_zone* zone

Tone zone as set in indications.conf

Definition at line 370 of file channel.h.


The documentation for this struct was generated from the following file:
Generated on Sat Mar 24 23:51:55 2007 for Asterisk - the Open Source PBX by  doxygen 1.5.1