Go to main content

man pages section 3: Library Interfaces and Headers

Exit Print View

Updated: Wednesday, July 27, 2022
 
 

ne_get_status (3)

Name

ne_get_status - retrieve HTTP response status for request

Synopsis

#include <ne_request.h>

const ne_status *ne_get_status(const ne_request *request);

Description

NE_GET_STATUS(3)              neon API reference              NE_GET_STATUS(3)



NAME
       ne_get_status - retrieve HTTP response status for request

SYNOPSIS
       #include <ne_request.h>

       const ne_status *ne_get_status(const ne_request *request);

DESCRIPTION
       The ne_get_status function returns a pointer to the HTTP status object
       giving the result of a request. The object returned only becomes valid
       once the request has been successfully dispatched (the return value of
       ne_request_dispatch or ne_begin_request was zero). The object remains
       valid until the associated request object is destroyed.


ATTRIBUTES
       See attributes(7) for descriptions of the following attributes:


       +---------------+------------------+
       |ATTRIBUTE TYPE | ATTRIBUTE VALUE  |
       +---------------+------------------+
       |Availability   | library/neon     |
       +---------------+------------------+
       |Stability      | Volatile         |
       +---------------+------------------+

SEE ALSO
       ne_status, ne_request_create

EXAMPLE
       Display the response status code of applying the HEAD method to some
       resource.

           ne_request *req = ne_request_create(sess, "HEAD", "/foo/bar");
           if (ne_request_dispatch(req))
              /* handle errors... */
           else
              printf("Response status code was %d\n", ne_get_status(req)->code);
           ne_request_destroy(req);

AUTHOR
       Joe Orton <neon@lists.manyfish.co.uk>
           Author.

COPYRIGHT
NOTES
       Source code for open source software components in Oracle Solaris can
       be found at https://www.oracle.com/downloads/opensource/solaris-source-
       code-downloads.html.

       This software was built from source available at
       https://github.com/oracle/solaris-userland.  The original community
       source was downloaded from
       http://www.webdav.org/neon/neon-0.30.1.tar.gz.

       Further information about this software can be found on the open source
       community website at http://www.webdav.org/neon/.



neon 0.30.1                    23 September 2014              NE_GET_STATUS(3)