In general, SST seamlessly loads local representations of IDL interface definitions when required. However, in some circumstances, you might want to pre-load the cache with particular interface and module definitions. There are three mechanisms for doing this, defined as SstIdlRepository class methods:
For example, to create a cache pre-loaded with the ping-pong IDL
which has been loaded into a third-party interface repository whose IOR
is in the file
ifr.ior, you use this method as follows:
SstIdlRepository buildOn: 'sstidlic.swp' into: 'sstpingpong.swp' with: #(#'IDL:PingPong:1.0') from: 'ifr.ior'Note that to use this cache, your IIOP application context must be established to use it with the idlRepository:cache: instance method of SstApplicationContext. If you have existing examples which use an alternative cache name, you can change the name of the destination cache to match your examples.
| context cache | context := SstApplicationContext contextNamed: '<your context name>'. cache := SstIdlRepository minimal. SstIdlRepository load: cache with: (Array with: #'IDL:omg.org/CORBA:1.0') context: context. ^cacheWhen starting with a minimal cache, you must always download at least the CORBA module. If the CORBA interface respository you are using does not provide access to the CORBA module definitions, you should make a copy of the Swapper file sstidlic.swp, set the context's repository cache location to the new file name, and use it as the cache to load with the loadCacheWith: context: operation instead.
Once the cache is primed, the Swapper can then be used as per normal to dump the new cache to a file for future use. The IOP, GIOP, and IIOP modules are always pre-loaded into every cache since SST relies on their exact definitions. These definitions cannot be overwritten.