TrustedQSL Library API
Classes | Macros | Typedefs | Enumerations | Functions
Cabrillo API

Classes

struct  tqsl_cabrilloField
 

Macros

#define TQSL_CABRILLO_MAX_FIELDS   12
 Max field count.
 
#define TQSL_CABRILLO_FIELD_NAME_LENGTH_MAX   64
 Max field name length.
 
#define TQSL_CABRILLO_FIELD_VALUE_LENGTH_MAX   40
 Max field value length.
 
#define TQSL_MIN_CABRILLO_MAP_FIELD   5
 First possible call-worked field.
 
#define TQSL_DEF_CABRILLO_MAP_FIELD   8
 Default call-worked field.
 

Typedefs

typedef void * tQSL_Cabrillo
 Opaque cabrillo log type.
 

Enumerations

enum  TQSL_CABRILLO_ERROR_TYPE {
  TQSL_CABRILLO_NO_ERROR , TQSL_CABRILLO_EOF , TQSL_CABRILLO_NO_START_RECORD , TQSL_CABRILLO_NO_CONTEST_RECORD ,
  TQSL_CABRILLO_UNKNOWN_CONTEST , TQSL_CABRILLO_BAD_FIELD_DATA , TQSL_CABRILLO_EOR
}
 Cabrillo status values.
 
enum  TQSL_CABRILLO_FREQ_TYPE { TQSL_CABRILLO_HF , TQSL_CABRILLO_VHF , TQSL_CABRILLO_UNKNOWN }
 

Functions

DLLEXPORT const char *CALLCONVENTION tqsl_cabrilloGetError (TQSL_CABRILLO_ERROR_TYPE err)
 
DLLEXPORT int CALLCONVENTION tqsl_beginCabrillo (tQSL_Cabrillo *cabp, const char *filename)
 
DLLEXPORT int CALLCONVENTION tqsl_getCabrilloContest (tQSL_Cabrillo cab, char *buf, int bufsiz)
 
DLLEXPORT int CALLCONVENTION tqsl_getCabrilloFreqType (tQSL_Cabrillo cab, TQSL_CABRILLO_FREQ_TYPE *type)
 
DLLEXPORT int CALLCONVENTION tqsl_getCabrilloLine (tQSL_Cabrillo cab, int *lineno)
 
DLLEXPORT const char *CALLCONVENTION tqsl_getCabrilloRecordText (tQSL_Cabrillo cab)
 
DLLEXPORT int CALLCONVENTION tqsl_getCabrilloField (tQSL_Cabrillo cab, tqsl_cabrilloField *field, TQSL_CABRILLO_ERROR_TYPE *err)
 
DLLEXPORT int CALLCONVENTION tqsl_endCabrillo (tQSL_Cabrillo *cabp)
 

Detailed Description

These functions and data structures provide a means of parsing a Cabrillo file into its component fields.

For convenience, the returned fields are identified using field names from the ADIF specification.

Enumeration Type Documentation

◆ TQSL_CABRILLO_FREQ_TYPE

Frequency type: HF, VHF, or UNKNOWN

Function Documentation

◆ tqsl_beginCabrillo()

DLLEXPORT int CALLCONVENTION tqsl_beginCabrillo ( tQSL_Cabrillo cabp,
const char *  filename 
)

Initialize a Cabrillo file for reading

◆ tqsl_cabrilloGetError()

DLLEXPORT const char *CALLCONVENTION tqsl_cabrilloGetError ( TQSL_CABRILLO_ERROR_TYPE  err)

Get the Cabrillo error message that corresponds to a particular error value

◆ tqsl_endCabrillo()

DLLEXPORT int CALLCONVENTION tqsl_endCabrillo ( tQSL_Cabrillo cabp)

Finish reading a Cabrillo file and release its resources

◆ tqsl_getCabrilloContest()

DLLEXPORT int CALLCONVENTION tqsl_getCabrilloContest ( tQSL_Cabrillo  cab,
char *  buf,
int  bufsiz 
)

Get the Contest name as specified in the Cabrillo CONTEST line

◆ tqsl_getCabrilloField()

DLLEXPORT int CALLCONVENTION tqsl_getCabrilloField ( tQSL_Cabrillo  cab,
tqsl_cabrilloField field,
TQSL_CABRILLO_ERROR_TYPE err 
)

Get the next field of the Cabrillo record

err is set to TQSL_CABRILLO_NO_ERROR or TQSL_CABRILLO_EOR (end-of-record) if field was populated with data. If err == TQSL_CABRILLO_EOR, this is the last field of the record.

err == TQSL_CABRILLO_EOF when there is no more data available.

◆ tqsl_getCabrilloFreqType()

DLLEXPORT int CALLCONVENTION tqsl_getCabrilloFreqType ( tQSL_Cabrillo  cab,
TQSL_CABRILLO_FREQ_TYPE type 
)

Get the Frequency type (HF or VHF) as determined by the contest

◆ tqsl_getCabrilloLine()

DLLEXPORT int CALLCONVENTION tqsl_getCabrilloLine ( tQSL_Cabrillo  cab,
int *  lineno 
)

Get the current line number (starting from 1) of the input file

◆ tqsl_getCabrilloRecordText()

DLLEXPORT const char *CALLCONVENTION tqsl_getCabrilloRecordText ( tQSL_Cabrillo  cab)

Get the text of the current Cabrillo record