IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Opened 22 years ago

Closed 22 years ago

Last modified 21 years ago

#247 closed defect (fixed)

Return Value for New psMetadataLookup Functions

Reported by: calvin.harman@… Owned by: eugene
Priority: high Milestone:
Component: PSLib SDRS Version: unspecified
Severity: normal Keywords:
Cc:

Description

Section 5.3.3 adds new functions:
psS32 psMetadataLookupS32(const psMetadata *md, const char *key);
psF64 psMetadataLookupF64(const psMetadata *md, const char *key);

If the key is not found, 0.0 is to be returned. What if the key is found and
its value really is 0.0? Perhaps a third argument for status should be added to
these functions, which could be checked to determine if the key was found? I'm
not sure that you'd want to put an error statement directly in these functions,
since there may be times when you don't care if the item was found.

Change History (1)

comment:1 by eugene, 22 years ago

Resolution: fixed
Status: newclosed

this solution sounds good to me.
I have modified the SDRS to reflect the suggestion:

void *psMetadataLookupPtr(bool *status, const psMetadata *md, const char *key);
psS32 psMetadataLookupS32(bool *status, const psMetadata *md, const char *key);
psF64 psMetadataLookupF64(bool *status, const psMetadata *md, const char *key);

Note: See TracTickets for help on using tickets.