22 code = int(Source) << 24;
34 if (2 == sscanf(s,
"%m[^ ] %m[^\n]", &codeBuf, &
description))
44 return Code1 == Code2;
58 q += snprintf(q,
sizeof(buffer) - 2,
"%u.%u", abs(n) / 10, abs(n) % 10);
59 *q++ = (n < 0) ?
'W' :
'E';
68 if (
'A' <= *s && *s <=
'Z') {
69 int code = int(*s) << 24;
76 case '0' ...
'9': pos *= 10;
85 default:
esyslog(
"ERROR: unknown source character '%c'", *s);
96 esyslog(
"ERROR: unknown source key '%c'", *s);
103 int code = SourceType;
104 if (SourceType ==
stSat) {
119 if (p->Code() == Code)
const cSource * First(void) const
const cSource * Next(const cSource *Object) const
bool Parse(const char *s)
static int FromString(const char *s)
static cString ToString(int Code)
static char ToChar(int Code)
const char * Description(void) const
int Position(void)
Returns the orbital position of the satellite in case this is a DVB-S source (zero otherwise).
static bool IsSat(int Code)
static int FromData(eSourceType SourceType, int Position=0, bool East=false)
static bool Matches(int Code1, int Code2)
Returns true if Code2 matches Code1.
bool ContainsSourceType(char SourceType)