Subject | Re: [Firebird-Architect] Error Reporting in New API |
---|---|
Author | Dimitry Sibiryakov |
Post date | 2005-02-16T06:21:04Z |
On 15 Feb 2005 at 10:55, Jim Starkey wrote:
your statement. Application Programming Interface (AKA API) that is
not intended for application use?!? It is the best joke I've read
last year.
will happened in one solid module, no?
discussed.
API. Pseudo-object for managing objects. What kind of hallucinogens
do you use to invent all these things? I'd like to have some. ;-)
The first thing that every error handling pseudo-objects have to do
is copy all useful information from received error object into
something internal because livetime of the error object is
unpredictable. What did you say about data copying?
Because of polymorphism error handling pseudo-object can't know how
many data error object may provide. What did you say about freedom?
programming. Is it possible to use one connection from many threads
without external serialization there? Two racing queries in one
transaction? No?.. `:-|
Currently connection object is an obvious candidate. No need for
thread vars.
big differences, I'd say.
From our previous discussions I got an impression that we agreed
that Application Programming Interface should be a set of plain C
functions...
--
SY, Dimitry Sibiryakov.
>>>Here is a scheme that I think is worth discussing. The firstAnd what way this prebuilt pseudo-object is going to handle errors?
>>>argument of all API functions is the address of a client-defined
>>>error receiving pseudo object.
>>
>> Full mess. Every API user has to implement its own error handling
>>object? Ridiculous! ;-)
>>
>>
>No, Dimitry, that isn't the case. If you had read a little further,
>you would have learned that I also proposed to include a prebuilt
>error handling class that could -- but needn't -- be used.
> Also,Jim, Jim, Jim, didn't I warned you about using right words? Re-read
>you've apparently forgotten that the API is not intended for
>application program use -- again, it could, but needn't --
your statement. Application Programming Interface (AKA API) that is
not intended for application use?!? It is the best joke I've read
last year.
> but as aThen, normal exception throwing-catching may work because all this
>universal underlaying API to support both the existing DSQL/XSQLDA
>interface and the IscDbc binding of JDBC semantics.
will happened in one solid module, no?
>Dimitry, you apparently missed school the day they discussedI can tell you for sure that in my scool functions never were
>functions.
discussed.
>previous paragraph). In my proposal an error object is passed to aCallbacks that receive callbacks as parameters. API which is not
>method on the user supplier error handler object. As long as each
>object is faithful to the respective interface definition, we are free
>to do whatever we wish with the error object(s) and the user with the
>error handler object(s).
API. Pseudo-object for managing objects. What kind of hallucinogens
do you use to invent all these things? I'd like to have some. ;-)
The first thing that every error handling pseudo-objects have to do
is copy all useful information from received error object into
something internal because livetime of the error object is
unpredictable. What did you say about data copying?
Because of polymorphism error handling pseudo-object can't know how
many data error object may provide. What did you say about freedom?
>Ah, Dimitry, Dimitry, Dimitry! Modern programming has threads andOh, really? Let's take a Vulcan as an example of modern
>threads lead to race conditions.
programming. Is it possible to use one connection from many threads
without external serialization there? Two racing queries in one
transaction? No?.. `:-|
> Our friend Nickolay has suggestedRight. Error status information may be kept in a serialized object.
>that we stuff error status information in thread data, which would
>work, but is crude, vulgar, and unnecessary.
Currently connection object is an obvious candidate. No need for
thread vars.
>Which brings us to naming conventions. Since the "get last error" isObject-oriented API? Or pseudo-object-oriented API? They are two
>a method in object oriented API,
big differences, I'd say.
From our previous discussions I got an impression that we agreed
that Application Programming Interface should be a set of plain C
functions...
--
SY, Dimitry Sibiryakov.