TGHtmlUri.h

Go to the documentation of this file.
00001 // @(#)root/guihtml:$Id: TObject.h 20877 2007-11-19 11:17:07Z rdm $
00002 // Author:  Valeriy Onuchin   03/05/2007
00003 
00004 /*************************************************************************
00005  * Copyright (C) 1995-2001, Rene Brun, Fons Rademakers and Reiner Rohlfs *
00006  * All rights reserved.                                                  *
00007  *                                                                       *
00008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
00009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
00010  *************************************************************************/
00011 
00012 /**************************************************************************
00013 
00014     HTML widget for xclass. Based on tkhtml 1.28
00015     Copyright (C) 1997-2000 D. Richard Hipp <drh@acm.org>
00016     Copyright (C) 2002-2003 Hector Peraza.
00017 
00018     This library is free software; you can redistribute it and/or
00019     modify it under the terms of the GNU Library General Public
00020     License as published by the Free Software Foundation; either
00021     version 2 of the License, or (at your option) any later version.
00022 
00023     This library is distributed in the hope that it will be useful,
00024     but WITHOUT ANY WARRANTY; without even the implied warranty of
00025     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00026     Library General Public License for more details.
00027 
00028     You should have received a copy of the GNU Library General Public
00029     License along with this library; if not, write to the Free
00030     Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00031 
00032 **************************************************************************/
00033 
00034 #ifndef ROOT_TGHtmlUri
00035 #define ROOT_TGHtmlUri
00036 
00037 #ifndef ROOT_TObject
00038 #include "TObject.h"
00039 #endif
00040 
00041 #define URI_SCHEME_MASK     (1<<0)
00042 #define URI_AUTH_MASK       (1<<1)
00043 #define URI_PATH_MASK       (1<<2)
00044 #define URI_QUERY_MASK      (1<<3)
00045 #define URI_FRAGMENT_MASK   (1<<4)
00046 
00047 #define URI_FULL_MASK       (URI_SCHEME_MASK | URI_AUTH_MASK |  \
00048                              URI_PATH_MASK   | URI_QUERY_MASK | \
00049                              URI_FRAGMENT_MASK)
00050 
00051 //----------------------------------------------------------------------
00052 // A parsed URI is held in an instance of the following class.
00053 //
00054 // The examples are from the URI
00055 //   http://192.168.1.1:8080/cgi-bin/printenv?name=xyzzy&addr=none#frag
00056 
00057 class TGHtmlUri : public TObject {
00058 public:
00059    TGHtmlUri(const char *zUri = 0);
00060    TGHtmlUri(const TGHtmlUri *uri);
00061    virtual ~TGHtmlUri();
00062 
00063    char *BuildUri();
00064    int  EqualsUri(const TGHtmlUri *uri, int field_mask = URI_FULL_MASK);
00065 
00066 public:
00067    int ComponentLength(const char *z, const char *zInit, const char *zTerm);
00068 
00069    char *fZScheme;             // Ex: "http"
00070    char *fZAuthority;          // Ex: "192.168.1.1:8080"
00071    char *fZPath;               // Ex: "cgi-bin/printenv"
00072    char *fZQuery;              // Ex: "name=xyzzy&addr=none"
00073    char *fZFragment;           // Ex: "frag"
00074 };
00075 
00076 #endif  // ROOT_TGHtmlUri

Generated on Tue Jul 5 14:22:16 2011 for ROOT_528-00b_version by  doxygen 1.5.1