IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 8794


Ignore:
Timestamp:
Sep 11, 2006, 6:18:56 PM (20 years ago)
Author:
jhoblitt
Message:

add psMetadataConfigPrint()

Location:
trunk/psLib/src/types
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/types/psMetadataConfig.c

    r8779 r8794  
    1010*  @author Eric Van Alst, MHPCC
    1111*
    12 *  @version $Revision: 1.83 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2006-09-08 03:46:24 $
     12*  @version $Revision: 1.84 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2006-09-12 04:18:56 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    15661566}
    15671567
     1568bool psMetadataConfigPrint(FILE *stream,
     1569                           psMetadata *md)
     1570{
     1571    PS_ASSERT_PTR_NON_NULL(md, false);
     1572
     1573    psString str = psMetadataConfigFormat(md);
     1574    if (!str) {
     1575        psError(PS_ERR_UNKNOWN, false,
     1576                _("failed to format metadata into a string."));
     1577        return false;
     1578    }
     1579
     1580    fprintf(stream, "%s", str);
     1581    psFree(str);
     1582
     1583    return true;
     1584}
  • trunk/psLib/src/types/psMetadataConfig.h

    r8774 r8794  
    1010 *  @author Robert DeSonia, MHPCC
    1111 *
    12  *  @version $Revision: 1.22 $ $Name: not supported by cvs2svn $
    13  *  @date $Date: 2006-09-08 02:13:20 $
     12 *  @version $Revision: 1.23 $ $Name: not supported by cvs2svn $
     13 *  @date $Date: 2006-09-12 04:18:56 $
    1414 *
    1515 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    105105);
    106106
     107/** Converts a psMetadata structure (including any nested psMetadata) into a
     108 *  configuration file formatted string that is written a file stream.
     109 *
     110 *  @return bool:       True if successful, otherwise false.
     111 */
     112bool psMetadataConfigPrint(
     113    FILE *stream,                       ///< file stream to write to
     114    psMetadata *md                      ///< The metadata to convert
     115);
     116
    107117/// @}
    108118
Note: See TracChangeset for help on using the changeset viewer.