SASC
DVBSoftCAM

cOverrideTunnel Class Reference

Inheritance diagram for cOverrideTunnel:

List of all members.

Public Member Functions

 cOverrideTunnel (void)
virtual bool Parse (char *str)
int GetTunnel (int *id, bool log)
 cOverrideTunnel (void)
virtual bool Parse (char *str)
int GetTunnel (int *id, bool log)

Detailed Description

Definition at line 404 of file override.c.


Constructor & Destructor Documentation

cOverrideTunnel::cOverrideTunnel ( void  ) [inline]

Definition at line 408 of file override.c.

References OV_TUNNEL, and cOverride::type.

cOverrideTunnel::cOverrideTunnel ( void  ) [inline]

Definition at line 408 of file override.c.

References OV_TUNNEL, and cOverride::type.


Member Function Documentation

int cOverrideTunnel::GetTunnel ( int *  id,
bool  log 
)

Definition at line 442 of file override.c.

References L_CORE_OVER, and PRINTF.

Referenced by cOverrides::UpdateEcm().

{
  if(log) PRINTF(L_CORE_OVER,"tunnel: to %04x (%d)",caid,rewriterId);
  if(id) *id=rewriterId;
  return caid;
}
int cOverrideTunnel::GetTunnel ( int *  id,
bool  log 
)
virtual bool cOverrideTunnel::Parse ( char *  str) [virtual]

Implements cOverride.

bool cOverrideTunnel::Parse ( char *  str) [virtual]

Implements cOverride.

Definition at line 413 of file override.c.

References free, cRewriters::GetIdByName(), L_CORE_LOAD, L_CORE_OVER, cValidityRange::Parse3(), cValidityRange::Print(), and PRINTF.

{
  bool res=false;
  if((str=Parse3(str))) {
    char *name=0;
    if(sscanf(str,"%x:%a[^:]",&caid,&name)>=1) {
      char rw[48];
      if(name) {
        if((rewriterId=cRewriters::GetIdByName(name))>0) {
          snprintf(rw,sizeof(rw),"%s(%d)",name,rewriterId);
          res=true;
          }
        else PRINTF(L_CORE_LOAD,"override: REWRITER name error");
        }
      else {
        strcpy(rw,"<none>");
        rewriterId=0;
        res=true;
        }
      if(res) {
        PRINTF(L_CORE_OVER,"tunnel: %s - to %04x, rewriter %s",*Print(),caid,rw);
        }
      }
    else PRINTF(L_CORE_LOAD,"override: TUNNEL format error");
    free(name);
    }
  return res;
}

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines