Configuring Content Manager OnDemand instance parameters
Configure the Content Manager OnDemand instance parameters by using the ODConfig Java object.
About this task
You must set several Content Manager OnDemand instance
parameters to create a working ODServer instance. To create an ODServer
instance with the default values for those parameters, add code that
calls the ODConfig constructor similar to the following example:
try{
ODConfig cfg = new ODConfig();
ODServer srvr = new ODServer(cfg);
srvr.initialize("MyCustomApp");
cfg.printConfig();
}
catch(ODException e){
System.out.println("Exception " + e);
}
This following list describes the default values
for the Content Manager OnDemand instance
parameters: - AfpViewOpt
- PLUGIN
- LineViewOpt
- APPLET
- MaxHits
- 200
- MetaViewOpt
- NATIVE
- AppletDir
- /applets
- Language
- ENU
- TempDir
- The temp path as defined by the Java System.getProperty("java.io.tmpdir") method.
- TraceDir
- The temp path as defined by the Java System.getProperty("java.io.tmpdir") method.
- TraceLevel
- 0
To create an ODServer instance with values
other than the default values, add code that calls the ODConfig constructor
similar to the following example:
try{
ODConfig cfg = new ODConfig(ODConstant.PLUGIN, //AfpViewer
ODConstant.APPLET, //LineViewer
null, //MetaViewer
500, //MaxHits
"c:\\applets", //AppletDir
"ENU", //Language
"c:\\temp", //TempDir
"c:\\temp\\trace", //TraceDir
1); //TraceLevel
ODServer srvr = new ODServer(cfg);
srvr.initialize("MyCustomApp");
cfg.printConfig();
}
catch(ODException e){
System.out.println("Exception " + e);
}
Important: This object has no methods to set parameters except during
construction. You cannot modify the object after constructing it.