Eneboo - Documentación para desarrolladores
src/flbase/aqsobjects/AQSUrlOperator_p.h
Ir a la documentación de este archivo.
00001 /***************************************************************************
00002  AQSUrlOperator_p.h
00003  -------------------
00004  begin                : 21/03/2011
00005  copyright            : (C) 2003-2011 by InfoSiAL S.L.
00006  email                : mail@infosial.com
00007  ***************************************************************************/
00008 /***************************************************************************
00009  *   This program is free software; you can redistribute it and/or modify  *
00010  *   it under the terms of the GNU General Public License as published by  *
00011  *   the Free Software Foundation; version 2 of the License.               *
00012  ***************************************************************************/
00013 /***************************************************************************
00014  Este  programa es software libre. Puede redistribuirlo y/o modificarlo
00015  bajo  los  trminos  de  la  Licencia  Pblica General de GNU   en  su
00016  versin 2, publicada  por  la  Free  Software Foundation.
00017  ***************************************************************************/
00018 
00019 #ifndef AQSURLOPERATOR_P_H_
00020 #define AQSURLOPERATOR_P_H_
00021 
00022 #include "AQSNetworkOperation_p.h"
00023 #include <qurloperator.h>
00024 
00025 class AQSUrlOperator : public AQSObject
00026 {
00027   Q_OBJECT
00028 
00029   AQ_DECLARE_AQS_OBJECT(UrlOperator, Object);
00030 
00031 public slots:
00032   QUrl *url() const {
00033     return static_cast<QUrl *>(o_);
00034   }
00035 
00036   //@AQ_BEGIN_DEF_PUB_SLOTS@
00037 public slots:
00038   virtual const QNetworkOperation *listChildren();
00039   virtual const QNetworkOperation *mkdir(const QString &);
00040   virtual const QNetworkOperation *remove(const QString &);
00041   virtual const QNetworkOperation *rename(const QString &, const QString &);
00042   virtual const QNetworkOperation *get(const QString& = QString::null);
00043   virtual const QNetworkOperation *put(QByteArray *, const QString& = QString::null);
00044   virtual const QNetworkOperation *put(AQSByteArray *, const QString& = QString::null);
00045   virtual void copy(const QStringList &, const QString &, bool = FALSE);
00046   virtual bool isDir(bool* = 0);
00047   virtual void setNameFilter(const QString &);
00048   QString nameFilter() const;
00049   virtual QUrlInfo *info(const QString &) const;
00050   virtual void stop();
00051   QString protocol() const;
00052   virtual void setProtocol(const QString &);
00053   QString user() const;
00054   virtual void setUser(const QString &);
00055   bool hasUser() const;
00056   QString password() const;
00057   virtual void setPassword(const QString &);
00058   bool hasPassword() const;
00059   QString host() const;
00060   virtual void setHost(const QString &);
00061   bool hasHost() const;
00062   int port() const;
00063   virtual void setPort(int);
00064   bool hasPort() const;
00065   QString path(bool = TRUE) const;
00066   virtual void setPath(const QString &);
00067   bool hasPath() const;
00068   virtual void setEncodedPathAndQuery(const QString &);
00069   QString encodedPathAndQuery();
00070   virtual void setQuery(const QString &);
00071   QString query() const;
00072   QString ref() const;
00073   virtual void setRef(const QString &);
00074   bool hasRef() const;
00075   bool isValid() const;
00076   bool isLocalFile() const;
00077   virtual void addPath(const QString &);
00078   virtual void setFileName(const QString &);
00079   QString fileName() const;
00080   QString dirPath() const;
00081   virtual QString toString(bool = FALSE, bool = TRUE) const;
00082   virtual bool cdUp();
00083   void decode(QString &);
00084   void encode(QString &);
00085   bool isRelativeUrl(const QString &);
00086 
00087 protected:
00088   static void *construct(const QSArgumentList &args) {
00089     QMap<int, QStringList> candidates;
00090     candidates[0].append(QString::null);
00091     candidates[1].append(QString::fromLatin1("QString"));
00092     candidates[1].append(QString::fromLatin1("QUrlOperator"));
00093     candidates[2].append(QString::fromLatin1("QUrlOperator,QString"));
00094     candidates[3].append(QString::fromLatin1("QUrlOperator,QString,bool"));
00095     candidates[1].append(QString::fromLatin1("QUrl"));
00096     candidates[1].append(QString::fromLatin1("QString"));
00097     candidates[1].append(QString::fromLatin1("QUrl"));
00098     candidates[1].append(QString::fromLatin1("QString"));
00099     QString sgt(castArgsSignature(args, candidates));
00100     if (sgt.isEmpty())
00101       return new QUrlOperator;
00102     if (sgt == QString::fromLatin1("QString"))
00103       return new QUrlOperator(*(argValue<QString *>(args[0])));
00104     if (sgt == QString::fromLatin1("QUrlOperator"))
00105       return new QUrlOperator(*(argValue<QUrlOperator *>(args[0])));
00106     if (sgt == QString::fromLatin1("QUrlOperator,QString"))
00107       return new QUrlOperator(*(argValue<QUrlOperator *>(args[0])),
00108                               *(argValue<QString *>(args[1])));
00109     if (sgt == QString::fromLatin1("QUrlOperator,QString,bool"))
00110       return new QUrlOperator(*(argValue<QUrlOperator *>(args[0])),
00111                               *(argValue<QString *>(args[1])),
00112                               args[2].variant().toBool());
00113     if (sgt == QString::fromLatin1("QUrl"))
00114       return new QUrlOperator(*(argValue<QUrl *>(args[0])));
00115     if (sgt == QString::fromLatin1("QString"))
00116       return new QUrlOperator(*(argValue<QString *>(args[0])));
00117     if (sgt == QString::fromLatin1("QUrl"))
00118       return new QUrlOperator(*(argValue<QUrl *>(args[0])));
00119     if (sgt == QString::fromLatin1("QString"))
00120       return new QUrlOperator(*(argValue<QString *>(args[0])));
00121     return 0;
00122   }
00123 
00124 public:
00125   static QMap<int, QStringList> candidateConstructors() {
00126     QMap<int, QStringList> candidates;
00127     candidates[0].append(QString::null);
00128     candidates[1].append(QString::fromLatin1("QString"));
00129     candidates[1].append(QString::fromLatin1("QUrlOperator"));
00130     candidates[2].append(QString::fromLatin1("QUrlOperator,QString"));
00131     candidates[3].append(QString::fromLatin1("QUrlOperator,QString,bool"));
00132     candidates[1].append(QString::fromLatin1("QUrl"));
00133     candidates[1].append(QString::fromLatin1("QString"));
00134     candidates[1].append(QString::fromLatin1("QUrl"));
00135     candidates[1].append(QString::fromLatin1("QString"));
00136     return candidates;
00137   }
00138   //@AQ_END_DEF_PUB_SLOTS@
00139 };
00140 
00141 //@AQ_BEGIN_IMP_PUB_SLOTS@
00142 inline const QNetworkOperation *AQSUrlOperator::listChildren()
00143 {
00144   AQ_CALL_RET(listChildren());
00145 }
00146 inline const QNetworkOperation *AQSUrlOperator::mkdir(const QString &arg0)
00147 {
00148   AQ_CALL_RET(mkdir(arg0));
00149 }
00150 inline const QNetworkOperation *AQSUrlOperator::remove(const QString &arg0)
00151 {
00152   AQ_CALL_RET(remove(arg0));
00153 }
00154 inline const QNetworkOperation *AQSUrlOperator::rename(const QString &arg0,  const QString &arg1)
00155 {
00156   AQ_CALL_RET(rename(arg0, arg1));
00157 }
00158 inline const QNetworkOperation *AQSUrlOperator::get(const QString &arg0)
00159 {
00160   AQ_CALL_RET(get(arg0));
00161 }
00162 inline const QNetworkOperation *AQSUrlOperator::put(QByteArray *arg0,  const QString &arg1)
00163 {
00164   AQ_CALL_RET(put(*arg0, arg1));
00165 }
00166 inline const QNetworkOperation *AQSUrlOperator::put(AQSByteArray *arg0,  const QString &arg1)
00167 {
00168   AQ_CALL_RET(put(*arg0, arg1));
00169 }
00170 inline void AQSUrlOperator::copy(const QStringList &arg0,  const QString &arg1,  bool arg2)
00171 {
00172   AQ_CALL_VOID(copy(arg0, arg1, arg2));
00173 }
00174 inline bool AQSUrlOperator::isDir(bool *arg0)
00175 {
00176   AQ_CALL_RET_V(isDir(arg0), bool);
00177 }
00178 inline void AQSUrlOperator::setNameFilter(const QString &arg0)
00179 {
00180   AQ_CALL_VOID(setNameFilter(arg0));
00181 }
00182 inline QString AQSUrlOperator::nameFilter() const
00183 {
00184   AQ_CALL_RET_V(nameFilter(), QString);
00185 }
00186 inline QUrlInfo *AQSUrlOperator::info(const QString &arg0) const
00187 {
00188   AQ_CALL_RET_PTR(info(arg0), QUrlInfo);
00189 }
00190 inline void AQSUrlOperator::stop()
00191 {
00192   AQ_CALL_VOID(stop());
00193 }
00194 inline QString AQSUrlOperator::protocol() const
00195 {
00196   AQ_CALL_RET_V(protocol(), QString);
00197 }
00198 inline void AQSUrlOperator::setProtocol(const QString &arg0)
00199 {
00200   AQ_CALL_VOID(setProtocol(arg0));
00201 }
00202 inline QString AQSUrlOperator::user() const
00203 {
00204   AQ_CALL_RET_V(user(), QString);
00205 }
00206 inline void AQSUrlOperator::setUser(const QString &arg0)
00207 {
00208   AQ_CALL_VOID(setUser(arg0));
00209 }
00210 inline bool AQSUrlOperator::hasUser() const
00211 {
00212   AQ_CALL_RET_V(hasUser(), bool);
00213 }
00214 inline QString AQSUrlOperator::password() const
00215 {
00216   AQ_CALL_RET_V(password(), QString);
00217 }
00218 inline void AQSUrlOperator::setPassword(const QString &arg0)
00219 {
00220   AQ_CALL_VOID(setPassword(arg0));
00221 }
00222 inline bool AQSUrlOperator::hasPassword() const
00223 {
00224   AQ_CALL_RET_V(hasPassword(), bool);
00225 }
00226 inline QString AQSUrlOperator::host() const
00227 {
00228   AQ_CALL_RET_V(host(), QString);
00229 }
00230 inline void AQSUrlOperator::setHost(const QString &arg0)
00231 {
00232   AQ_CALL_VOID(setHost(arg0));
00233 }
00234 inline bool AQSUrlOperator::hasHost() const
00235 {
00236   AQ_CALL_RET_V(hasHost(), bool);
00237 }
00238 inline int AQSUrlOperator::port() const
00239 {
00240   AQ_CALL_RET_V(port(), int);
00241 }
00242 inline void AQSUrlOperator::setPort(int arg0)
00243 {
00244   AQ_CALL_VOID(setPort(arg0));
00245 }
00246 inline bool AQSUrlOperator::hasPort() const
00247 {
00248   AQ_CALL_RET_V(hasPort(), bool);
00249 }
00250 inline QString AQSUrlOperator::path(bool arg0) const
00251 {
00252   AQ_CALL_RET_V(path(arg0), QString);
00253 }
00254 inline void AQSUrlOperator::setPath(const QString &arg0)
00255 {
00256   AQ_CALL_VOID(setPath(arg0));
00257 }
00258 inline bool AQSUrlOperator::hasPath() const
00259 {
00260   AQ_CALL_RET_V(hasPath(), bool);
00261 }
00262 inline void AQSUrlOperator::setEncodedPathAndQuery(const QString &arg0)
00263 {
00264   AQ_CALL_VOID(setEncodedPathAndQuery(arg0));
00265 }
00266 inline QString AQSUrlOperator::encodedPathAndQuery()
00267 {
00268   AQ_CALL_RET_V(encodedPathAndQuery(), QString);
00269 }
00270 inline void AQSUrlOperator::setQuery(const QString &arg0)
00271 {
00272   AQ_CALL_VOID(setQuery(arg0));
00273 }
00274 inline QString AQSUrlOperator::query() const
00275 {
00276   AQ_CALL_RET_V(query(), QString);
00277 }
00278 inline QString AQSUrlOperator::ref() const
00279 {
00280   AQ_CALL_RET_V(ref(), QString);
00281 }
00282 inline void AQSUrlOperator::setRef(const QString &arg0)
00283 {
00284   AQ_CALL_VOID(setRef(arg0));
00285 }
00286 inline bool AQSUrlOperator::hasRef() const
00287 {
00288   AQ_CALL_RET_V(hasRef(), bool);
00289 }
00290 inline bool AQSUrlOperator::isValid() const
00291 {
00292   AQ_CALL_RET_V(isValid(), bool);
00293 }
00294 inline bool AQSUrlOperator::isLocalFile() const
00295 {
00296   AQ_CALL_RET_V(isLocalFile(), bool);
00297 }
00298 inline void AQSUrlOperator::addPath(const QString &arg0)
00299 {
00300   AQ_CALL_VOID(addPath(arg0));
00301 }
00302 inline void AQSUrlOperator::setFileName(const QString &arg0)
00303 {
00304   AQ_CALL_VOID(setFileName(arg0));
00305 }
00306 inline QString AQSUrlOperator::fileName() const
00307 {
00308   AQ_CALL_RET_V(fileName(), QString);
00309 }
00310 inline QString AQSUrlOperator::dirPath() const
00311 {
00312   AQ_CALL_RET_V(dirPath(), QString);
00313 }
00314 inline QString AQSUrlOperator::toString(bool arg0,  bool arg1) const
00315 {
00316   AQ_CALL_RET_V(toString(arg0, arg1), QString);
00317 }
00318 inline bool AQSUrlOperator::cdUp()
00319 {
00320   AQ_CALL_RET_V(cdUp(), bool);
00321 }
00322 inline void AQSUrlOperator::decode(QString &arg0)
00323 {
00324   AQ_CALL_VOID(decode(arg0));
00325 }
00326 inline void AQSUrlOperator::encode(QString &arg0)
00327 {
00328   AQ_CALL_VOID(encode(arg0));
00329 }
00330 inline bool AQSUrlOperator::isRelativeUrl(const QString &arg0)
00331 {
00332   AQ_CALL_RET_V(isRelativeUrl(arg0), bool);
00333 }
00334 //@AQ_END_IMP_PUB_SLOTS@
00335 
00336 #endif /* AQSURLOPERATOR_P_H_ */
00337 // @AQSOBJECT@
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'