Download Wordfast Server User Manual
Transcript
Wordfast Server manual
Version 1
Parameters: Error number in ASCII (e.g. "12")
Details: WfServer returns the meaning of the error message in text format.
Java code:
string ErrorStr;
TMServerTCPConnector Connector = new TMServerTCPConnector();
Connector.PostCommand(Consts.cmdGetErrorMsg, "54");
ErrorStr = Connector.WaitResultString();
// ErrorStr = « Invalid command »
cmdCreateGlos = 33
Remotely creates a new glossary. ~ Restricted to Administrators
Parameters:
Each parameter is separated from the previous one with a Tab character (# 9)
1: Name of the glossary
2: Name of file relative to the default directory for glossaries as defined in the
"Setup/Glossaries" tab.
3: Glossary password.
4: Glossary LangID
5: Write authorization ("1" = yes, "0" = no)
6: Write authorization for the public zone ("1" = yes, "0" = no)
Details:
WfServer creates a glossary and automatically indexes it. This command
returns msgEndJob, but the process runs in the background.
Java code:
string Params, Line ;
int ErrorNumber ;
TMServerTCPConnector Connector = new TMServerTCPConnector();
Connector.PostCommand(Consts.cmdSetParam, "IsAdmin=" + AdminPassword);
Line = Connector.WaitResultString();
If (Line.equal("IsAdmin=1")) {
Params = "GloName" + #9 + "GloFileName.txt" + #9 + "GloPassword" + "EN>FR-CA" + #9 +
"1" + #9 + "1";
Connector.PostCommandWaitTicket(Consts.cmdCreateGlos, Params);
ErrorNumber = Connector.Status.Msg;
}
cmdDeleteGlos = 34
Remotely deletes a glossary. ~ Restricted to Administrators
Parameters: Parameters are separated with a Tab character (# 9)
1: Name of the glossary
2: Glossary password.
3: Delete the files (glossary file and index). ("1" = yes, "0" = no)
Details:
WfServer send the user a confirmation string (10 random alphanumeric
characters) before executing the command. The distant user will have to
return this confirmation string before the maximum time of the execution
of a command. If the response time exceeds "MaxTimeJob"
37