FBCallConverter Class Reference

#include <fbcallconverter.h>

List of all members.

Public Slots

void convert (QString *Str, int pageIndex, int from, int to, int option)

Public Member Functions

 FBCallConverter (PageCtrl *pageCtrl)
virtual ~FBCallConverter ()

Private Member Functions

int convertFBCAllAtTo (QStringList *tmpList, int pageIndex, int index, int to, int option)
bool getCallLineItems (QString str, int ioStyle, QString *fbPart, QString *tag, QString *comment, QString *lineEnd)
QString getComment (QString str)
QString getDefaultInputLine (QString str, int ioStyle)
QString getDefaultOutputLine (QString str, int ioStyle)
QString getIECInputLine (QString instance, QString str, int ioStyle, QString prgLng)
QString getIECOutputLine (QString instance, QString str, int ioStyle, QString prgLng)
QString getMoellerILOutputLine (QString str, int ioStyle)
int getNextCALPos (QStringList *tmpList, int pageIndex, int index)

Private Attributes

PageCtrlm_PageCtrl
 instance of PageCtrl class


Constructor & Destructor Documentation

FBCallConverter::FBCallConverter ( PageCtrl pageCtrl  ) 

creating function for FBCallConverter -function block call<CAL> model converter-

Parameters:
PageCtrl class

FBCallConverter::~FBCallConverter (  )  [virtual]

virtual destructor


Member Function Documentation

void FBCallConverter::convert ( QString *  Str,
int  pageIndex,
int  from,
int  to,
int  option 
) [slot]

FB call convert routine

Parameters:
*Str contains the string wich will be worked
pageIndex is the index of the selected page
from contains the current extension of the file/page
to contains the requested extension of the file/page
option contains the information about special conversion options option 0: do nothing option 1: all into selected compatibility call model option 2: outputs into simple IEC call model option 3: all into simple IEC call model

int FBCallConverter::convertFBCAllAtTo ( QStringList *  tmpList,
int  pageIndex,
int  index,
int  to,
int  option 
) [private]

convert default call at index in tmpList into Moeller style

Parameters:
*tmpList temporary list which will be filled with the file content
pageIndex is the index of the selected page
index contains position of the next function block call model
to holds the appointed file extension
option contains the information about special conversion options
supported conversion values:

option 0: do nothing

option 1: all into selected compatibility call model

option 2: outputs into simple IEC call model

option 3: all into simple IEC call model

bool FBCallConverter::getCallLineItems ( QString  str,
int  ioStyle,
QString *  fbPart,
QString *  tag,
QString *  comment,
QString *  lineEnd 
) [private]

get function block part and connected tag by solving str into fbPart and tag

Parameters:
str contains line
ioStyle used to handle standard inputs/outputs (0) and Moeller outputs (1)
*fbPart will filled with function block in/out substring
*tag will filled with connected tag substring
*comment will filled with comment substring
*lineEnd will filled with the line end sign

QString FBCallConverter::getComment ( QString  str  )  [private]

get comment from str

QString FBCallConverter::getDefaultInputLine ( QString  str,
int  ioStyle 
) [private]

get default input line: ' input := tag,'

QString FBCallConverter::getDefaultOutputLine ( QString  str,
int  ioStyle 
) [private]

get default output line: ' output => tag,'

QString FBCallConverter::getIECInputLine ( QString  instance,
QString  str,
int  ioStyle,
QString  prgLng 
) [private]

get IEC intput line according to the programming language IL: 'LD tag ST INSTANCE.input (*...*)
' ST: 'INSTANCE.input := tag; (*...*)
'

QString FBCallConverter::getIECOutputLine ( QString  instance,
QString  str,
int  ioStyle,
QString  prgLng 
) [private]

get IEC output line according to the programming language IL: 'LD INSTANCE.output (*...*)
ST tag
' ST: 'tag := INSTANCE.output; (*...*)
'

QString FBCallConverter::getMoellerILOutputLine ( QString  str,
int  ioStyle 
) [private]

get Moeller output line: ' tag := > output,'

int FBCallConverter::getNextCALPos ( QStringList *  tmpList,
int  pageIndex,
int  index 
) [private]

get position of next FB call 'CAL'/'CALL'/'abcdefg ('


Member Data Documentation

instance of PageCtrl class


The documentation for this class was generated from the following files:

Generated on Sat Jul 10 19:22:03 2010 for PLCEdit by  doxygen 1.5.9