// // Copyright 2002 Perforce Software. All rights reserved. // // This file is part of Perforce - the FAST SCM System. // // p4wURL: // Handles parsing and construction of URLs based on knowledge // of p4web URL syntax #ifndef p4wURL_H #define p4wURL_H #include "p4wAllCommands.h" class StrBufDict; #define RSSEXT ".p4webrss.xml" // // View modes (client/depot/workspace) enum ViewMode { VM_CLIENT, VM_DEPOT, VM_WORKSPACE }; class p4wURL { public: p4wURL() {}; virtual ~p4wURL() {}; void ConstructURL( StrBuf & url, const char *path, AllCommands cmd, StrBufDict *cmdArgs, int isUnicode =0 ); const char *GetURLPath( StrPtr & url ); void ConstructIcon( StrBuf & icon, const char *name, int height, int width, const char *alt, int suppressBorder, const char *align=0, const char *id=0); void ConstructLocationURL( StrBuf &url, const char *path, AllCommands cmd, StrBufDict *cmdArgs, int isUnicode =0 ); char *GetNodeLocation( const char *path, int useDepot, AllCommands ac ); void GetDirLocation( StrBuf & newPath, const char *path, int useDepot, AllCommands ac ); char *GetFolderLocation( StrBuf & folder, const char *path, int useDepot ); char *GetSysDirDelim( char *pd ); int IsRootDir( const char *dir ); void ParseURL( const StrPtr &url, StrBufDict *stateParms, StrBufDict *dynParms, int skipConvert =0 ); void CreateBaseAndNode( StrBuf & base, StrBuf & node, const char * port, const char *path, StrBufDict *state, int useDepot, int noCache, AllCommands ac, int isHTTPS ); void SetNewBase( StrBuf & newBase, StrBufDict *oldBase, int editBase, const StrPtr &path, const char *var, const char *val, int noCache ); void SetOneBaseArg( const char *varName, StrRef *varToSet, const char *prefix, StrBuf &newBase, StrBufDict *oldBase, int editBase, const char *var, char *val ); void NormalizePath( StrBuf & path, AllCommands cmd, ViewMode vm ); void ConvertNTPath( StrBuf & path, ViewMode vm ); private: int IsEscapedAmpersand( const char *str ); int IsTerminatingAmpersand( const char *str, StrBuf *var ); }; #endif // p4wURL_H
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 12234 | Matt Attaway |
Rejigger P4Web project in preparation for official sunsetting The bin directory contains the last official builds of P4Web from the Perforce download site. P4Web is soon to be completely sunsetted; these builds are here for folks who don't want to build their own. To better handle the archived builds the source code has been moved into a separate src directory. |
||
//guest/perforce_software/p4web/Main/p4wURL.h | |||||
#1 | 8914 | Matt Attaway | Initial add of the P4Web source code |