Before choosing Batch Task as template to build your plugin you should ask yourself if this template is suitable for your needs. Take your time and respond to this questions:
When you create a project using Batch Task template the following files will be generated:
1. Depending on the name of your solution you'll a class which has the following annotation [AutomaticTask].This class is the entry point of your plugin. By default it has two methods:
- ConfigureConverter() method will be called when user clicks on "Finish" button. From here the logic of your application will begin.
- OnInitializeTask() ,is the method from where you can get your Batch Task settings saved on the project.
To get the setting use following method GetSetting<CustomSettings>(). Where CustomSettings is a class which inherits from SettingsGroup class.
- If your batch task plugin should process sdlxliff files OnFileComplete() method should be added!. Just paste the following code on your class. This allows your application to override the xliff. If you don't add this your changes on the file will not be saved.
public override bool OnFileComplete(ProjectFile projectFile, IMultiFileConverter multiFileConverter)
{
return true;
}