hpux man page for dtdtsfiletoattributevalue

Query: dtdtsfiletoattributevalue

OS: hpux

Section: 3

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

DtDtsFileToAttributeValue(library call) 								   DtDtsFileToAttributeValue(library call)

NAME
DtDtsFileToAttributeValue -- get a specified attribute value for a file
SYNOPSIS
#include <Dt/Dts.h> char *DtDtsFileToAttributeValue( const char *filepath, const char *attr_name);
DESCRIPTION
The DtDtsFileToAttributeValue function returns a data attribute value for the specified file. The filepath argument is the pathname of the file. The attr_name argument is a pointer to an attribute name string.
RETURN VALUE
Upon successful completion, the DtDtsFileToAttributeValue function returns a pointer to a data attribute value string, or NULL if no value could be determined.
APPLICATION USAGE
The application should use the DtDtsFreeAttributeValue(3) function to release the memory for the returned value.
EXAMPLES
The following takes a list of files as arguments and determines the description of the data type for each file: #include <Dt/Dts.h> #define ATTRIBUTE "DESCRIPTION" main (int argc, char **argv) { char *attribute; /* load data types database */ DtDtsLoadDataTypes(); argv++; while (*argv) { /* get attribute for file */ attribute = DtDtsFileToAttributeValue(*argv, ATTRIBUTE); if (attribute) printf("%s: %s ", *argv, attribute); argv++; } DtDtsRelease(); exit(0); }
SEE ALSO
Dt/Dts.h, DtDtsLoadDataTypes(3), DtDtsRelease(3), DtDtsFreeAttributeValue(3). DtDtsFileToAttributeValue(library call)
Related Man Pages
genders_testattr(3) - debian
dtdtsbuffertoattributevalue(3) - hpux
dtdtsdatatypetoattributelist(3) - hpux
dtdtsdatatypetoattributevalue(3) - hpux
libaf(3) - osf1
Similar Topics in the Unix Linux Community
Converting a hostname argv into an IP
Length of a Unix filepath max length
How to turn argv[1] into a string in C?
How do I copy or rewind *argv[]
O argv, argv, wherefore art thou argv?