http_errors.h

00001 
00002 /*
00003   Return Codes for Libwww Protocol Modules and Streams.
00004   Success codes are (>=0) and failure are (<0)
00005 */
00006 
00007 /* we disable the constant definitions for standard HTTP errors inside the XSB
00008    libwww code, because these defs are included from Libwww itself */
00009 #ifndef XSB_LIBWWW_PACKAGE
00010 
00011 #define HT_OK                   0       /* Generic success */
00012 #define HT_ALL                  1       /* Used by Net Manager */
00013 
00014 #define HT_CONTINUE             100     /* Continue an operation */
00015 #define HT_UPGRADE              101     /* Switching protocols */
00016 
00017 #define HT_LOADED               200     /* Everything's OK */
00018 #define HT_CREATED              201     /* New object is created */
00019 #define HT_ACCEPTED             202     /* Accepted */
00020 #define HT_NON_AUTHORITATIVE    203     /* Non-authoritative Information */
00021 #define HT_NO_DATA              204     /* OK but no data was loaded */
00022 #define HT_RESET_CONTENT        205     /* Reset content */
00023 #define HT_PARTIAL_CONTENT      206     /* Partial Content */
00024 #define HT_PARTIAL_OK           207     /* Partial Update OK */
00025 
00026 #define HT_MULTIPLE_CHOICES     300     /* Multiple choices */
00027 #define HT_PERM_REDIRECT        301     /* Permanent redirection */
00028 #define HT_FOUND                302     /* Found */
00029 #define HT_SEE_OTHER            303     /* See other */
00030 #define HT_NOT_MODIFIED         304     /* Not Modified */
00031 #define HT_USE_PROXY            305     /* Use Proxy */
00032 #define HT_PROXY_REDIRECT       306     /* Proxy Redirect */
00033 #define HT_TEMP_REDIRECT        307     /* Temporary redirect */
00034 
00035 
00036 #define HT_IGNORE               900     /* Ignore this in the Net manager */
00037 #define HT_CLOSED               901     /* The socket was closed */
00038 #define HT_PENDING              902     /* Wait for connection */
00039 #define HT_RELOAD               903     /* If we must reload the document */
00040 
00041 #define HT_ERROR                -1      /* Generic failure */
00042 
00043 #define HT_BAD_REQUEST          -400    /* Bad request */
00044 #define HT_NO_ACCESS            -401    /* Unauthorized */
00045 #define HT_FORBIDDEN            -403    /* Access forbidden */
00046 #define HT_NOT_FOUND            -404    /* Not found */
00047 #define HT_NOT_ALLOWED          -405    /* Method Not Allowed */
00048 #define HT_NOT_ACCEPTABLE       -406    /* Not Acceptable */
00049 #define HT_NO_PROXY_ACCESS      -407    /* Proxy Authentication Failed */
00050 #define HT_CONFLICT             -409    /* Conflict */
00051 #define HT_LENGTH_REQUIRED      -411    /* Length required */
00052 #define HT_PRECONDITION_FAILED  -412    /* Precondition failed */
00053 #define HT_TOO_BIG              -413    /* Request entity too large */
00054 #define HT_URI_TOO_BIG          -414    /* Request-URI too long */
00055 #define HT_UNSUPPORTED          -415    /* Unsupported */
00056 #define HT_BAD_RANGE            -416    /* Request Range not satisfiable */
00057 #define HT_EXPECTATION_FAILED   -417    /* Expectation Failed */
00058 #define HT_REAUTH               -418    /* Reauthentication required */
00059 #define HT_PROXY_REAUTH         -419    /* Proxy Reauthentication required */
00060 
00061 #define HT_SERVER_ERROR         -500    /* Internal server error */
00062 #define HT_NOT_IMPLEMENTED      -501    /* Not implemented */
00063 #define HT_BAD_GATEWAY          -502    /* Bad gateway */
00064 #define HT_RETRY                -503    /* If service isn't available */
00065 #define HT_GATEWAY_TIMEOUT      -504    /* Gateway timeout */
00066 #define HT_BAD_VERSION          -505    /* Bad protocol version */
00067 #define HT_PARTIAL_NOT_IMPLEMENTED -506
00068 
00069 #define HT_INTERNAL             -900    /* Weird -- should never happen. */
00070 #define HT_WOULD_BLOCK          -901    /* If we are in a select */
00071 #define HT_INTERRUPTED          -902    /* Note the negative value! */
00072 #define HT_PAUSE                -903    /* If we want to pause a stream */
00073 #define HT_RECOVER_PIPE         -904    /* Recover pipe line */
00074 #define HT_TIMEOUT              -905    /* Connection timeout */
00075 #define HT_NO_HOST              -906    /* Can't locate host */
00076 
00077 #endif /* XSB_LIBWWW_PACKAGE */
00078 
00079 
00080 /* ERROR CODES SPECIFIC TO THE XSB LIBWWW PACKAGE  -- NOT http errors */
00081 #define WWW_DOC_SYNTAX          -2001   /* Bad document syntax or nesting
00082                                            limit exceeded. */
00083 #define WWW_EXTERNAL_ENTITY     -2002   /* XML external entity not found */
00084 #define WWW_EXPIRED_DOC         -2003   /* when document's last modified time
00085                                            is older than user-specified time */
00086 #define WWW_URI_SYNTAX          -2004   /* when uri has bad syntax */
00087 

Generated on Wed Jul 26 13:30:47 2006 for XSB by  doxygen 1.4.5