Annotation of embedaddon/php/ext/xmlrpc/libxmlrpc/simplestring.h, revision 1.1

1.1     ! misho       1: /*
        !             2:   This file is part of libXMLRPC - a C library for xml-encoded function calls.
        !             3: 
        !             4:   Author: Dan Libby (dan@libby.com)
        !             5:   Epinions.com may be contacted at feedback@epinions-inc.com
        !             6: */
        !             7: 
        !             8: /*  
        !             9:   Copyright 2000 Epinions, Inc. 
        !            10: 
        !            11:   Subject to the following 3 conditions, Epinions, Inc.  permits you, free 
        !            12:   of charge, to (a) use, copy, distribute, modify, perform and display this 
        !            13:   software and associated documentation files (the "Software"), and (b) 
        !            14:   permit others to whom the Software is furnished to do so as well.  
        !            15: 
        !            16:   1) The above copyright notice and this permission notice shall be included 
        !            17:   without modification in all copies or substantial portions of the 
        !            18:   Software.  
        !            19: 
        !            20:   2) THE SOFTWARE IS PROVIDED "AS IS", WITHOUT ANY WARRANTY OR CONDITION OF 
        !            21:   ANY KIND, EXPRESS, IMPLIED OR STATUTORY, INCLUDING WITHOUT LIMITATION ANY 
        !            22:   IMPLIED WARRANTIES OF ACCURACY, MERCHANTABILITY, FITNESS FOR A PARTICULAR 
        !            23:   PURPOSE OR NONINFRINGEMENT.  
        !            24: 
        !            25:   3) IN NO EVENT SHALL EPINIONS, INC. BE LIABLE FOR ANY DIRECT, INDIRECT, 
        !            26:   SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES OR LOST PROFITS ARISING OUT 
        !            27:   OF OR IN CONNECTION WITH THE SOFTWARE (HOWEVER ARISING, INCLUDING 
        !            28:   NEGLIGENCE), EVEN IF EPINIONS, INC.  IS AWARE OF THE POSSIBILITY OF SUCH 
        !            29:   DAMAGES.    
        !            30: 
        !            31: */
        !            32: 
        !            33: #ifndef __SIMPLESTRING_H__
        !            34:  #define __SIMPLESTRING_H__
        !            35: 
        !            36: /*-********************************
        !            37: * begin simplestring header stuff *
        !            38: **********************************/
        !            39: 
        !            40: #ifdef __cplusplus
        !            41: extern "C" {
        !            42: #endif
        !            43: 
        !            44:    /****s* struct/simplestring
        !            45:  * NAME
        !            46:  *  simplestring
        !            47:  * NOTES
        !            48:  *   represents a string efficiently for fast appending, etc.
        !            49:  * SOURCE
        !            50:  */
        !            51: typedef struct _simplestring {
        !            52:    char* str;         /* string buf               */
        !            53:    int len;           /* length of string/buf     */
        !            54:    int size;          /* size of allocated buffer */
        !            55: } simplestring;
        !            56: /******/
        !            57: 
        !            58: #ifndef NULL
        !            59:  #define NULL 0
        !            60: #endif
        !            61: 
        !            62: void simplestring_init(simplestring* string);
        !            63: void simplestring_clear(simplestring* string);
        !            64: void simplestring_free(simplestring* string);
        !            65: void simplestring_add(simplestring* string, const char* add);
        !            66: void simplestring_addn(simplestring* string, const char* add, int add_len);
        !            67: 
        !            68: #ifdef __cplusplus
        !            69: }
        !            70: #endif
        !            71: 
        !            72: /*-******************************
        !            73: * end simplestring header stuff *
        !            74: ********************************/
        !            75: 
        !            76: #endif /* __SIMPLESTRING_H__ */

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>