ParaView
Public Member Functions
pqFileDialogModel Class Reference

pqFileDialogModel allows remote browsing of a connected ParaView server's filesystem, as well as browsing of the local file system. More...

#include <pqFileDialogModel.h>

List of all members.

Public Member Functions

 pqFileDialogModel (pqServer *server, QObject *Parent=NULL)
 server is the server for which we need the listing.
 ~pqFileDialogModel ()
void setCurrentPath (const QString &)
 Sets the path that the file dialog will display.
QString getCurrentPath ()
 Returns the path the the file dialog will display.
bool isHidden (const QModelIndex &)
 Return true if the file at the index is hidden.
bool isDir (const QModelIndex &)
 Return true if the given row is a directory.
bool mkdir (const QString &dirname)
bool rmdir (const QString &dirname)
bool rename (const QString &oldname, const QString &newname)
bool fileExists (const QString &file, QString &fullpath)
 Returns whether the file exists also returns the full path, which could be a resolved shortcut.
bool dirExists (const QString &dir, QString &fullpath)
 Returns whether a directory exists also returns the full path, which could be a resolved shortcut.
QChar separator () const
 returns the path delimiter, could be \ or / depending on the platform this model is browsing
QString absoluteFilePath (const QString &)
 return the absolute path for this file
QStringList getFilePaths (const QModelIndex &)
 Returns the set of file paths associated with the given row (a row may represent one-to-many paths if grouping is implemented) this also resolved symlinks if necessary.
pqServerserver () const
 Returns the server that this model is browsing.
bool setData (const QModelIndex &idx, const QVariant &value, int role)
 sets data (used by the view when editing names of folders)
int columnCount (const QModelIndex &) const
 return the number of columns in the model
QVariant data (const QModelIndex &idx, int role) const
 return the data for an item
QModelIndex index (int row, int column, const QModelIndex &) const
 return an index from another index
QModelIndex parent (const QModelIndex &) const
 return the parent index of an index
int rowCount (const QModelIndex &) const
 return the number of rows under a given index
bool hasChildren (const QModelIndex &p) const
 return whether a given index has children
QVariant headerData (int section, Qt::Orientation, int role) const
 returns header data
Qt::ItemFlags flags (const QModelIndex &idx) const
 returns flags for item

Detailed Description

pqFileDialogModel allows remote browsing of a connected ParaView server's filesystem, as well as browsing of the local file system.

To use, pass a new instance of pqServerFileDialogModel to pqFileDialog object.

See also:
pqFileDialog

Definition at line 55 of file pqFileDialogModel.h.


Constructor & Destructor Documentation

pqFileDialogModel::pqFileDialogModel ( pqServer server,
QObject *  Parent = NULL 
)

server is the server for which we need the listing.

if the server is NULL, we get file listings locally

pqFileDialogModel::~pqFileDialogModel ( )

Member Function Documentation

void pqFileDialogModel::setCurrentPath ( const QString &  )

Sets the path that the file dialog will display.

QString pqFileDialogModel::getCurrentPath ( )

Returns the path the the file dialog will display.

bool pqFileDialogModel::isHidden ( const QModelIndex &  )

Return true if the file at the index is hidden.

bool pqFileDialogModel::isDir ( const QModelIndex &  )

Return true if the given row is a directory.

bool pqFileDialogModel::mkdir ( const QString &  dirname)
bool pqFileDialogModel::rmdir ( const QString &  dirname)
bool pqFileDialogModel::rename ( const QString &  oldname,
const QString &  newname 
)
bool pqFileDialogModel::fileExists ( const QString &  file,
QString &  fullpath 
)

Returns whether the file exists also returns the full path, which could be a resolved shortcut.

bool pqFileDialogModel::dirExists ( const QString &  dir,
QString &  fullpath 
)

Returns whether a directory exists also returns the full path, which could be a resolved shortcut.

QChar pqFileDialogModel::separator ( ) const

returns the path delimiter, could be \ or / depending on the platform this model is browsing

QString pqFileDialogModel::absoluteFilePath ( const QString &  )

return the absolute path for this file

QStringList pqFileDialogModel::getFilePaths ( const QModelIndex &  )

Returns the set of file paths associated with the given row (a row may represent one-to-many paths if grouping is implemented) this also resolved symlinks if necessary.

pqServer* pqFileDialogModel::server ( ) const

Returns the server that this model is browsing.

bool pqFileDialogModel::setData ( const QModelIndex &  idx,
const QVariant &  value,
int  role 
)

sets data (used by the view when editing names of folders)

int pqFileDialogModel::columnCount ( const QModelIndex &  ) const

return the number of columns in the model

QVariant pqFileDialogModel::data ( const QModelIndex &  idx,
int  role 
) const

return the data for an item

QModelIndex pqFileDialogModel::index ( int  row,
int  column,
const QModelIndex &   
) const

return an index from another index

QModelIndex pqFileDialogModel::parent ( const QModelIndex &  ) const

return the parent index of an index

int pqFileDialogModel::rowCount ( const QModelIndex &  ) const

return the number of rows under a given index

bool pqFileDialogModel::hasChildren ( const QModelIndex &  p) const

return whether a given index has children

QVariant pqFileDialogModel::headerData ( int  section,
Qt::Orientation  ,
int  role 
) const

returns header data

Qt::ItemFlags pqFileDialogModel::flags ( const QModelIndex &  idx) const

returns flags for item


The documentation for this class was generated from the following file: