[KLF Application][KLF Tools][KLF Backend][KLF Home]
KLatexFormula Project
Public Slots | Public Member Functions | Static Public Member Functions | Protected Slots | Protected Member Functions
KLFLibLegacyEngine Class Reference

The Legacy Library support for the KLFLib framework. More...

#include <klfliblegacyengine.h>

Inheritance diagram for KLFLibLegacyEngine:
Inheritance graph
[legend]
Collaboration diagram for KLFLibLegacyEngine:
Collaboration graph
[legend]

List of all members.

Public Slots

virtual bool createSubResource (const QString &subResource, const QString &subResourceTitle)
virtual bool renameSubResource (const QString &subResource, const QString &subResourceName)
virtual bool deleteSubResource (const QString &subResource)
virtual bool save ()
virtual void setAutoSaveInterval (int intervalms)
virtual QList< entryIdinsertEntries (const QString &subResource, const KLFLibEntryList &entries)
virtual bool changeEntries (const QString &subResource, const QList< entryId > &idlist, const QList< int > &properties, const QList< QVariant > &values)
virtual bool deleteEntries (const QString &subResource, const QList< entryId > &idlist)
virtual bool saveTo (const QUrl &newPath)

Public Member Functions

virtual ~KLFLibLegacyEngine ()
virtual uint compareUrlTo (const QUrl &other, uint interestFlags=0xfffffff) const
virtual bool canModifyData (const QString &subRes, ModifyType modifytype) const
virtual bool canModifyProp (int propid) const
virtual bool canRegisterProperty (const QString &propName) const
virtual KLFLibEntry entry (const QString &resource, entryId id)
virtual QList< KLFLibEntryWithIdallEntries (const QString &resource, const QList< int > &wantedEntryProperties=QList< int >())
virtual QStringList subResourceList () const
virtual bool canCreateSubResource () const
virtual bool canRenameSubResource (const QString &subResource) const
virtual bool canDeleteSubResource (const QString &subResource) const
- Public Member Functions inherited from KLFLibResourceSimpleEngine
 KLFLibResourceSimpleEngine (const QUrl &url, uint supportedfeatureflags, QObject *parent=NULL)
virtual ~KLFLibResourceSimpleEngine ()
virtual QList< KLFLib::entryIdallIds (const QString &subResource)
virtual bool hasEntry (const QString &, entryId id)
virtual QList< KLFLibEntryWithIdentries (const QString &, const QList< KLFLib::entryId > &idList, const QList< int > &wantedEntryProperties=QList< int >())
virtual int query (const QString &subResource, const Query &query, QueryResult *result)
virtual QList< QVariantqueryValues (const QString &subResource, int entryPropId)
- Public Member Functions inherited from KLFLibResourceEngine
 KLFLibResourceEngine (const QUrl &url, uint supportedfeatureflags, QObject *parent=NULL)
virtual ~KLFLibResourceEngine ()
virtual uint supportedFeatureFlags () const
 List of features supported by this resource engine.
virtual QUrl url (uint flags=0x0) const
 query URL
virtual bool isReadOnly () const
 query read-only state
virtual QString title () const
 The human-set title of this resource.
virtual bool locked () const
 Is this resource is locked?
virtual QString viewType () const
 The (last) View Type used to display this resource.
virtual bool accessShared () const
 If the resource is accessed by many clients.
virtual QVariant resourceProperty (const QString &name) const
 Get the value of a resource property.
virtual bool canModifyData (ModifyType modifytype) const
virtual QString suggestedViewTypeIdentifier () const
virtual bool hasSubResource (const QString &subResource) const
virtual QString defaultSubResource () const
virtual bool compareDefaultSubResourceEquals (const QString &subResourceName) const
 Compare our sub-resource name to another.
virtual QVariant subResourceProperty (const QString &subResource, int propId) const
virtual QList< int > subResourcePropertyIdList () const
virtual QString subResourcePropertyName (int propId) const
virtual bool canModifySubResourceProperty (const QString &subResource, int propId) const
virtual KLFLibEntry entry (entryId id)
 query an entry in this resource
virtual bool hasEntry (entryId id)
 query the existence of an entry in this resource
virtual QList< KLFLibEntryWithIdentries (const QList< KLFLib::entryId > &idList, const QList< int > &wantedEntryProperties=QList< int >())
 query multiple entries in this resource
virtual QList< KLFLib::entryIdallIds ()
 Returns all IDs in this resource (and the default sub-resource)
virtual QList< KLFLibEntryWithIdallEntries (const QList< int > &wantedEntryProperties=QList< int >())
 query all entries in this resource
void blockProgressReportingForNextOperation ()
 Specifies that the next operation (only) should not report progress.
void blockProgressReporting (bool block)
 (Un)Blocks generally progress reporting
- Public Member Functions inherited from QObject
 QObject (QObject *parent=0)
 blockSignals (bool block)
 childEvent (QChildEvent *event)
 children ()
 connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type=Qt::AutoCompatConnection)
 connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type=Qt::AutoCompatConnection)
 connectNotify (const char *signal)
 customEvent (QEvent *event)
 deleteLater ()
 destroyed (QObject *obj=0)
 disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
 disconnect (const char *signal=0, const QObject *receiver=0, const char *method=0)
 disconnect (const QObject *receiver, const char *method=0)
 disconnectNotify (const char *signal)
 dumpObjectInfo ()
 dumpObjectTree ()
 dynamicPropertyNames ()
 event (QEvent *e)
 eventFilter (QObject *watched, QEvent *event)
 findChild (const QString &name=QString()
 findChildren (const QString &name=QString()
 findChildren (const QRegExp &regExp)
 inherits (const char *className)
 installEventFilter (QObject *filterObj)
 isWidgetType ()
 killTimer (int id)
 metaObject ()
 moveToThread (QThread *targetThread)
 parent ()
 property (const char *name)
 receivers (const char *signal)
 removeEventFilter (QObject *obj)
 sender ()
 setParent (QObject *parent)
 setProperty (const char *name, const QVariant &value)
 signalsBlocked ()
 startTimer (int interval)
 thread ()
 timerEvent (QTimerEvent *event)
 tr (const char *sourceText, const char *comment=0, int n=-1)
 trUtf8 (const char *sourceText, const char *comment=0, int n=-1)
 staticMetaObject
 QObject (QObject *parent, const char *name)
 checkConnectArgs (const char *signal, const QObject *object, const char *method)
 child (const char *objName, const char *inheritsClass=0, bool recursiveSearch=true)
 className ()
 insertChild (QObject *object)
 isA (const char *className)
 name ()
 name (const char *defaultName)
 normalizeSignalSlot (const char *signalSlot)
 removeChild (QObject *object)
 setName (const char *name)
- Public Member Functions inherited from KLFPropertizedObject
 KLFPropertizedObject (const QString &propertyNameSpace)
virtual ~KLFPropertizedObject ()
virtual QVariant property (const QString &propName) const
virtual QVariant property (int propId) const
QList< int > propertyIdList () const
QStringList propertyNameList () const
QMap< QString, QVariantallProperties () const
void setAllProperties (const QMap< QString, QVariant > &propValues)
QByteArray allPropertiesToByteArray () const
void setAllPropertiesFromByteArray (const QByteArray &data)
virtual QString toString (uint toStringFlags=0) const
int propertyMaxId () const
bool propertyIdRegistered (int propId) const
bool propertyNameRegistered (const QString &propertyName) const
int propertyIdForName (const QString &propertyName) const
QString propertyNameForId (int propId) const
QList< int > registeredPropertyIdList () const
QStringList registeredPropertyNameList () const
QMap< QString, int > registeredProperties () const

Static Public Member Functions

static KLFLibLegacyEngineopenUrl (const QUrl &url, QObject *parent=NULL)
static KLFLibLegacyEnginecreateDotKLF (const QString &fileName, QString legacyResourceName, QObject *parent=NULL)
- Static Public Member Functions inherited from KLFLibResourceSimpleEngine
static int queryImpl (KLFLibResourceEngine *resource, const QString &subResource, const Query &query, QueryResult *result)
static QList< QVariantqueryValuesImpl (KLFLibResourceEngine *resource, const QString &subResource, int entryPropId)
static bool testEntryMatchConditionImpl (const KLFLib::EntryMatchCondition &condition, const KLFLibEntry &libentry)

Protected Slots

void updateResourceProperty (int propId)

Protected Member Functions

virtual bool saveResourceProperty (int propId, const QVariant &value)

Detailed Description

The Legacy Library support for the KLFLib framework.

Implements a KLFLibResourceEngine resource engine for accessing (KLF<=3.1)-created libraries (*.klf, default library files)

Different legacy resources (in the *.klf file) are mapped to sub-resources (in KLFLibResourceEngine).

Definition at line 135 of file klfliblegacyengine.h.


Constructor & Destructor Documentation

KLFLibLegacyEngine::~KLFLibLegacyEngine ( )
virtual

Member Function Documentation

QList< KLFLibResourceEngine::KLFLibEntryWithId > KLFLibLegacyEngine::allEntries ( const QString resource,
const QList< int > &  wantedEntryProperties = QList<int>() 
)
virtual
bool KLFLibLegacyEngine::canCreateSubResource ( ) const
virtual

Reimplemented from KLFLibResourceEngine.

Definition at line 607 of file klfliblegacyengine.cpp.

References canModifyData(), and KLFLibResourceEngine::ChangeData.

bool KLFLibLegacyEngine::canDeleteSubResource ( const QString subResource) const
virtual
bool KLFLibLegacyEngine::canModifyData ( const QString subRes,
ModifyType  modifytype 
) const
virtual
bool KLFLibLegacyEngine::canModifyProp ( int  propid) const
virtual

Reimplemented from KLFLibResourceEngine.

Definition at line 540 of file klfliblegacyengine.cpp.

Referenced by canRegisterProperty().

bool KLFLibLegacyEngine::canRegisterProperty ( const QString propName) const
virtual

Reimplemented from KLFLibResourceEngine.

Definition at line 546 of file klfliblegacyengine.cpp.

References canModifyProp().

bool KLFLibLegacyEngine::canRenameSubResource ( const QString subResource) const
virtual

Reimplemented from KLFLibResourceEngine.

Definition at line 612 of file klfliblegacyengine.cpp.

References canModifyData(), and KLFLibResourceEngine::ChangeData.

bool KLFLibLegacyEngine::changeEntries ( const QString subResource,
const QList< entryId > &  idlist,
const QList< int > &  properties,
const QList< QVariant > &  values 
)
virtualslot
uint KLFLibLegacyEngine::compareUrlTo ( const QUrl other,
uint  interestFlags = 0xfffffff 
) const
virtual
KLFLibLegacyEngine * KLFLibLegacyEngine::createDotKLF ( const QString fileName,
QString  legacyResourceName,
QObject parent = NULL 
)
static

Use this function as a constructor. Creates a KLFLibLegacyEngine object, with QObject parent parent, creating a fresh, empty .klf file.

Returns NULL if creating the file failed.

legacyResourceName is the name of an empty (legacy) resource (ie. sub-resource) to create in the newly created file.

A non-NULL returned object is linked to a file that was successfully created.

Definition at line 425 of file klfliblegacyengine.cpp.

References QUrl::addQueryItem(), KLFLibLegacyFileDataPrivate::canonicalFilePath(), QFile::exists(), QUrl::fromLocalFile(), QString::isEmpty(), KLF_FUNC_NAME, klfDbgSt, QUrl::setScheme(), QObject::tr(), and KLFLibResourceEngine::url().

Referenced by KLFLibLegacyEngineFactory::createResource().

bool KLFLibLegacyEngine::createSubResource ( const QString subResource,
const QString subResourceTitle 
)
virtualslot
bool KLFLibLegacyEngine::deleteEntries ( const QString subResource,
const QList< entryId > &  idlist 
)
virtualslot
bool KLFLibLegacyEngine::deleteSubResource ( const QString subResource)
virtualslot
KLFLibEntry KLFLibLegacyEngine::entry ( const QString resource,
entryId  id 
)
virtual
QList< KLFLibResourceEngine::entryId > KLFLibLegacyEngine::insertEntries ( const QString subResource,
const KLFLibEntryList entries 
)
virtualslot
KLFLibLegacyEngine * KLFLibLegacyEngine::openUrl ( const QUrl url,
QObject parent = NULL 
)
static

Use this function as a constructor for a KLFLibLegacyEngine object.

Opens the URL referenced by url and returns a pointer to a freshly instantiated KLFLibLegacyEngine object, the parent of which is set to parent. Returns NULL in case of an error.

Definition at line 398 of file klfliblegacyengine.cpp.

References QUrl::hasQueryItem(), QString::isEmpty(), KLF_DEBUG_BLOCK, KLF_FUNC_NAME, klfDbgSt, klfUrlLocalFilePath(), QUrl::queryItemValue(), and QUrl::scheme().

Referenced by KLFLibLegacyEngineFactory::openResource().

bool KLFLibLegacyEngine::renameSubResource ( const QString subResource,
const QString subResourceName 
)
virtualslot
bool KLFLibLegacyEngine::save ( )
virtualslot
bool KLFLibLegacyEngine::saveResourceProperty ( int  propId,
const QVariant value 
)
protectedvirtual
bool KLFLibLegacyEngine::saveTo ( const QUrl newPath)
virtualslot
void KLFLibLegacyEngine::setAutoSaveInterval ( int  intervalms)
virtualslot
QStringList KLFLibLegacyEngine::subResourceList ( ) const
virtual
void KLFLibLegacyEngine::updateResourceProperty ( int  propId)
protectedslot

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

Generated by doxygen 1.8.1