Suggestions
Suggestions for all tools.
Consider:
- Platform independence: Java and Perl scripts should use PCMAPIMgr
- Directories: Do not use hard-wired directories in your code, use the registry settings (available on both platforms) and the standardcheckout, encaps, and temp directories if required.
- Environment Variables: Get the directory locations from ENV variable for UNIX, and registry settings on Windows.
It is recommended that you use the Environment variables on both Windows and Unix, or on both platforms use the API PCMutils interface for portable code that accesses registry settings. These portable registry methods work in both the COM and CORBA API's. SDL delivers a special file on Unix, /pdm/clients/setup/unixuser.dat, which simulates the registry for Contenta Explorer and the tools on the Unix platform. The API registry interface works with this file.
- Avoid platform-specific commands: Use programming language functions. For example, in Perl don't use system('ls'); use the readdir function.