Browse Prior Art Database

Handle Determinants: An instrument for partially overriding handle based c-runtime services.

IP.com Disclosure Number: IPCOM000029961D
Original Publication Date: 2004-Jul-20
Included in the Prior Art Database: 2004-Jul-20
Document File: 5 page(s) / 33K

Publishing Venue

IBM

Abstract

Handle determinants are a management instrument for dealing with programs needing to partially override c-runtime supplied handle based services. A service could be, for example, file input/output, communications, or references to operating system objects (e.g. bitmaps). "Partially overridden" means that there exists the potential for a program to need to reference both the overridden service and original service simultaneously using distinctive handles. Handle A, for example may reference a communication channel provided by the overridden service, and handle B might reference a file on the local file-system for which the original service is responsible. "Partially overridden" is the significant problem that Handle Determinants attempt to solve. In contrast to "partially overridden", a complete function override might be implemented by completely bypassing c-runtime function calls using preprocessor macro definitions to replace standard calls with an overridden variety.

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 40% of the total text.

Page 1 of 5

Handle Determinants :

c
c-
--runtime servicesruntime services .

1. Abstract:

Handle determinants are a management instrument for dealing with programs needing to partially override c-runtime supplied handle based services. A service could be, for example, file input/output, communications, or references to operating system objects (e.g. bitmaps).

    "Partially overridden" means that there exists the potential for a program to need to reference both the overridden service and original service simultaneously using distinctive handles. Handle A, for example may reference a communication channel provided by the overridden service, and handle B might reference a file on the local file-system for which the original service is responsible. "Partially overridden" is the significant problem that Handle Determinants attempt to solve. In contrast to "partially overridden", a complete function override might be implemented by completely bypassing c-runtime function calls using preprocessor macro definitions to replace standard calls with an overridden variety.

2. Summary and Advantages Handle Determinants

1. Handle co-existence: Handles to original service remain intact; allowing these handles to be transferred to third-party code library providers without translation. A specific example; assume the provider for the c-runtime standard I/O FILE* were overridden. The c-runtime supplied standard in, out and error handles would not be overridden. This characteristic allows these native handles to be used in the target program and also passed to third party functions directly .
2. Self contained Service section ("routing") information: Because the routing information to which service a handle references is encoded in the handle itself, no central management infrastructure needs to be in place. This is critical when the handles are passed amongst independent shared libraries. To be able to identify the type of stream before the stream handle is redirected to one of two API sets - one OS/400, the other PASE. The identification needed to be based solely on the file handle itself as it is the only consistent information available.
3. Implementation simplicity: Any existing source code using the service for which an override is desired need not be rewritten; just recompiled.

3. Comparison to other possible methods:

    Other possible methods for a program needing to partially override a service (having the characteristics described above) might fall into one of two categories. 1. Service exposure where additional information about the service is explicitly propagated by the program. 2. Handle lookup where a cross-reference provides a mapping from a handle to associated service provider.

    Service exposure: Design the application program code to propagate information about additional service offerings throughout the target program . Perhaps a new structure might be defined containing information about the original service or overridden service. A pointer to the new...