00001
00028 #ifndef INC_SOA_ARCIMSCONNECTION_H
00029 #define INC_SOA_ARCIMSCONNECTION_H
00030
00031 #ifndef INC_MI32_MISTRING_H
00032 #include <mi32/mistring.h>
00033 #endif
00034 #ifndef INC_MI32_MIMETYPE_H
00035 #include <mi32/mimetype.h>
00036 #endif
00037
00038 namespace SPATREF {
00039 class COORDREFSYS;
00040 }
00041 namespace SPATMOD {
00042 namespace IMAGE {
00043 class SOURCE_HTML;
00044 }
00045 }
00046 struct COLOR;
00047 class MIMETYPE;
00048 class HTTPMESSAGE;
00049 class XMLDOC;
00050
00051 namespace SOA {
00052 namespace ARCIMS {
00053
00054 class SERVICEINFO;
00055
00056
00057
00060 class CONNECTION {
00061 public:
00062
00064 static bool IsCompatibleURL (
00065 const MISTRING& url
00066 );
00067
00069 CONNECTION ();
00070
00072 CONNECTION (const CONNECTION&);
00073
00075 virtual ~CONNECTION ();
00076
00078 CONNECTION& operator= (const CONNECTION&);
00079
00080
00082 ERRVALUE BuildGetFeatureInfoRequest (
00083 HTTPMESSAGE& RequestHdrs,
00084 XMLDOC& RequestBody,
00085 const MISTRINGLIST& LayerNameList,
00086 const MISTRINGLIST& LayerStyleList,
00087 const SPATREF::COORDREFSYS& CoordRefSys,
00088 const DRECT2D& BoundingBox,
00089 INT32 TgtWidth,
00090 INT32 TgtHeight,
00091 const MIMETYPE& ImageFormat,
00092 const MISTRINGLIST& QueryLayerList,
00093 const MIMETYPE& InfoFormat,
00094 INT32 PixelColumn,
00095 INT32 PixelRow,
00096 INT32 FeatureCount = 1
00097 ) const;
00098
00099
00105 ERRVALUE BuildGetImageRequest (
00106 HTTPMESSAGE& RequestHdrs,
00107 XMLDOC& RequestBody,
00108 const MISTRINGLIST& LayerIDList,
00109 const SPATREF::COORDREFSYS& CoordRefSys,
00110 const DRECT2D& BoundingBox,
00111 INT32 TgtWidth,
00112 INT32 TgtHeight,
00113 const MIMETYPE& Format,
00114 bool bRequestImage = true,
00115 const COLOR *pColorBG = 0
00116 ) const;
00117
00118 ERRVALUE BuildGetLegendRequest (
00119 HTTPMESSAGE& RequestHdrs,
00120 XMLDOC& RequestBody,
00121 const MISTRINGLIST& LayerIDList,
00122 const MIMETYPE& Format,
00123 const COLOR *pLegendBGColor = 0
00124 ) const;
00125
00128 ERRVALUE DoGetServiceInfo (
00129 const MISTRING& ServerURL,
00130 bool synchronous,
00131 MDLGPARENT dlgparent = 0
00132 );
00133
00136 ERRVALUE DoGetServiceInfo (
00137 bool synchronous,
00138 MDLGPARENT dlgparent = 0
00139 );
00140
00141 const MIMETYPE& GetImageType (
00142 ) const { return (m_ImageType); }
00143
00144 const MISTRING& GetServerURL (
00145 ) const { return (m_ServerURL); }
00146
00150 const ARCIMS::SERVICEINFO& GetServiceInfo (
00151 ) const;
00152
00154 MISTRING GetServiceTitle (
00155 ) const;
00156
00158 MISTRING GetServiceToolTip (
00159 ) const;
00160
00162 bool HasServiceInfo (
00163 ) const { return (m_bHasServiceInfo); }
00164
00165
00168 void SetServerURL (
00169 const MISTRING& ServerURL
00170 );
00171
00172 private:
00173 #ifndef GENERATING_DOXYGEN_OUTPUT
00174 MISTRING m_ServerURL;
00175 ARCIMS::SERVICEINFO *m_pServiceInfo;
00176 bool m_bHasServiceInfo;
00177 MIMETYPE m_ImageType;
00178
00179 #endif
00180 };
00181
00182
00183
00184 }
00185 }
00186
00187 #endif // INC_SOA_ARCIMSCONNECTION_H