Revision b0b8dac3
Von Christian Ehringfeld vor fast 10 Jahren hinzugefügt
EntityManager.pro | ||
---|---|---|
src/schema.h \
|
||
src/schema/sqliteschema.h \
|
||
src/tableschema.h \
|
||
src/columnschema.h
|
||
src/columnschema.h \
|
||
src/schema/pgsqlschema.h \
|
||
src/schema/mysqlschema.h
|
||
|
||
SOURCES += \
|
||
src/entity.cpp \
|
||
... | ... | |
src/schema.cpp \
|
||
src/schema/sqliteschema.cpp \
|
||
src/tableschema.cpp \
|
||
src/columnschema.cpp
|
||
src/columnschema.cpp \
|
||
src/schema/pgsqlschema.cpp \
|
||
src/schema/mysqlschema.cpp
|
||
|
||
unix {
|
||
target.path = /usr/lib
|
build-Example-Desktop-Debug/Makefile | ||
---|---|---|
#############################################################################
|
||
# Makefile for building: EntityManager
|
||
# Generated by qmake (3.0) (Qt 5.4.1)
|
||
# Project: ../example/Example.pro
|
||
# Template: app
|
||
# Command: /usr/lib/qt/bin/qmake -spec linux-g++ CONFIG+=debug -o Makefile ../example/Example.pro
|
||
#############################################################################
|
||
|
||
MAKEFILE = Makefile
|
||
|
||
####### Compiler, tools and options
|
||
|
||
CC = gcc
|
||
CXX = g++
|
||
DEFINES = -DQT_SQL_LIB -DQT_CORE_LIB
|
||
CFLAGS = -pipe -g -Wall -W -D_REENTRANT -fPIE $(DEFINES)
|
||
CXXFLAGS = -pipe -g -Wall -W -D_REENTRANT -fPIE $(DEFINES)
|
||
INCPATH = -I../example -I. -isystem /usr/include/qt -isystem /usr/include/qt/QtSql -isystem /usr/include/qt/QtCore -I. -I/usr/lib/qt/mkspecs/linux-g++
|
||
QMAKE = /usr/lib/qt/bin/qmake
|
||
DEL_FILE = rm -f
|
||
CHK_DIR_EXISTS= test -d
|
||
MKDIR = mkdir -p
|
||
COPY = cp -f
|
||
COPY_FILE = cp -f
|
||
COPY_DIR = cp -f -R
|
||
INSTALL_FILE = install -m 644 -p
|
||
INSTALL_PROGRAM = install -m 755 -p
|
||
INSTALL_DIR = $(COPY_DIR)
|
||
DEL_FILE = rm -f
|
||
SYMLINK = ln -f -s
|
||
DEL_DIR = rmdir
|
||
MOVE = mv -f
|
||
TAR = tar -cf
|
||
COMPRESS = gzip -9f
|
||
DISTNAME = EntityManager1.0.0
|
||
DISTDIR = /home/cehringfeld/gitrepos/entitymanager/example/.tmp/EntityManager1.0.0
|
||
LINK = g++
|
||
LFLAGS =
|
||
LIBS = $(SUBLIBS) -lQt5Sql -lQt5Core -lpthread
|
||
AR = ar cqs
|
||
RANLIB =
|
||
SED = sed
|
||
STRIP = strip
|
||
|
||
####### Output directory
|
||
|
||
OBJECTS_DIR = ./
|
||
|
||
####### Files
|
||
|
||
SOURCES = ../example/models/artikel.cpp
|
||
OBJECTS = artikel.o
|
||
DIST = /usr/lib/qt/mkspecs/features/spec_pre.prf \
|
||
/usr/lib/qt/mkspecs/common/shell-unix.conf \
|
||
/usr/lib/qt/mkspecs/common/unix.conf \
|
||
/usr/lib/qt/mkspecs/common/linux.conf \
|
||
/usr/lib/qt/mkspecs/common/gcc-base.conf \
|
||
/usr/lib/qt/mkspecs/common/gcc-base-unix.conf \
|
||
/usr/lib/qt/mkspecs/common/g++-base.conf \
|
||
/usr/lib/qt/mkspecs/common/g++-unix.conf \
|
||
/usr/lib/qt/mkspecs/qconfig.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_Attica.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KActivities.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KArchive.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KAuth.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KBookmarks.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCMUtils.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCodecs.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCompletion.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigCore.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigGui.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCoreAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCrash.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDBusAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDeclarative.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDESu.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDEWebKit.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KEmoticons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KGlobalAccel.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KGuiAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KHtml.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KI18n.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIconThemes.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIdleTime.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOCore.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOFileWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KItemModels.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KItemViews.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJobWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJS.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJSApi.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJsEmbed.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNewStuff.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNotifications.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNotifyConfig.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNTLM.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KParts.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KPlotting.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KPty.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KRunner.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KScreen.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KService.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KTextEditor.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KTextWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KUnitConversion.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KWallet.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KWidgetsAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KWindowSystem.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KXmlGui.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_bootstrap_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_clucene_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_concurrent.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_concurrent_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_core.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_core_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_dbus.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_dbus_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_declarative.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_declarative_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designer.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designer_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designercomponents_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_gui.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_gui_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_help.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_help_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_location.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_location_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimedia.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimedia_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimediawidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimediawidgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_network.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_network_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_opengl.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_opengl_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_openglextensions.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_openglextensions_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_platformsupport_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_positioning.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_positioning_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_printsupport.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_printsupport_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qml.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qml_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmldevtools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmltest.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmltest_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qtmultimediaquicktools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quick.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quick_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickparticles_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickwidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickwidgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_script.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_script_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_scripttools.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_scripttools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sensors.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sensors_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sql.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sql_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_svg.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_svg_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_testlib.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_testlib_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_uitools.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_uitools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webchannel.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webchannel_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkit.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkit_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkitwidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkitwidgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_websockets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_websockets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_widgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_widgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_x11extras.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_x11extras_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xml.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xml_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xmlpatterns.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xmlpatterns_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_phonon4qt5.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_QuickAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_Solid.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_SonnetCore.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_SonnetUi.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_ThreadWeaver.pri \
|
||
/usr/lib/qt/mkspecs/features/qt_functions.prf \
|
||
/usr/lib/qt/mkspecs/features/qt_config.prf \
|
||
/usr/lib/qt/mkspecs/linux-g++/qmake.conf \
|
||
/usr/lib/qt/mkspecs/features/spec_post.prf \
|
||
/usr/lib/qt/mkspecs/features/exclusive_builds.prf \
|
||
/usr/lib/qt/mkspecs/features/default_pre.prf \
|
||
/usr/lib/qt/mkspecs/features/resolve_config.prf \
|
||
/usr/lib/qt/mkspecs/features/default_post.prf \
|
||
/usr/lib/qt/mkspecs/features/warn_on.prf \
|
||
/usr/lib/qt/mkspecs/features/qt.prf \
|
||
/usr/lib/qt/mkspecs/features/resources.prf \
|
||
/usr/lib/qt/mkspecs/features/moc.prf \
|
||
/usr/lib/qt/mkspecs/features/unix/thread.prf \
|
||
/usr/lib/qt/mkspecs/features/testcase_targets.prf \
|
||
/usr/lib/qt/mkspecs/features/exceptions.prf \
|
||
/usr/lib/qt/mkspecs/features/yacc.prf \
|
||
/usr/lib/qt/mkspecs/features/lex.prf \
|
||
../example/Example.pro ../example/models/artikel.h ../example/models/artikel.cpp
|
||
QMAKE_TARGET = EntityManager
|
||
DESTDIR = #avoid trailing-slash linebreak
|
||
TARGET = EntityManager
|
||
|
||
|
||
first: all
|
||
####### Implicit rules
|
||
|
||
.SUFFIXES: .o .c .cpp .cc .cxx .C
|
||
|
||
.cpp.o:
|
||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||
|
||
.cc.o:
|
||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||
|
||
.cxx.o:
|
||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||
|
||
.C.o:
|
||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
|
||
|
||
.c.o:
|
||
$(CC) -c $(CFLAGS) $(INCPATH) -o "$@" "$<"
|
||
|
||
####### Build rules
|
||
|
||
$(TARGET): $(OBJECTS)
|
||
$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)
|
||
|
||
Makefile: ../example/Example.pro /usr/lib/qt/mkspecs/linux-g++/qmake.conf /usr/lib/qt/mkspecs/features/spec_pre.prf \
|
||
/usr/lib/qt/mkspecs/common/shell-unix.conf \
|
||
/usr/lib/qt/mkspecs/common/unix.conf \
|
||
/usr/lib/qt/mkspecs/common/linux.conf \
|
||
/usr/lib/qt/mkspecs/common/gcc-base.conf \
|
||
/usr/lib/qt/mkspecs/common/gcc-base-unix.conf \
|
||
/usr/lib/qt/mkspecs/common/g++-base.conf \
|
||
/usr/lib/qt/mkspecs/common/g++-unix.conf \
|
||
/usr/lib/qt/mkspecs/qconfig.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_Attica.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KActivities.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KArchive.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KAuth.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KBookmarks.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCMUtils.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCodecs.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCompletion.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigCore.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigGui.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCoreAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KCrash.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDBusAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDeclarative.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDESu.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KDEWebKit.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KEmoticons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KGlobalAccel.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KGuiAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KHtml.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KI18n.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIconThemes.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIdleTime.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOCore.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOFileWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KItemModels.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KItemViews.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJobWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJS.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJSApi.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KJsEmbed.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNewStuff.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNotifications.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNotifyConfig.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KNTLM.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KParts.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KPlotting.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KPty.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KRunner.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KScreen.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KService.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KTextEditor.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KTextWidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KUnitConversion.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KWallet.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KWidgetsAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KWindowSystem.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_KXmlGui.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_bootstrap_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_clucene_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_concurrent.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_concurrent_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_core.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_core_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_dbus.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_dbus_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_declarative.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_declarative_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designer.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designer_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designercomponents_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_gui.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_gui_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_help.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_help_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_location.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_location_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimedia.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimedia_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimediawidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimediawidgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_network.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_network_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_opengl.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_opengl_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_openglextensions.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_openglextensions_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_platformsupport_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_positioning.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_positioning_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_printsupport.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_printsupport_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qml.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qml_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmldevtools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmltest.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmltest_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qtmultimediaquicktools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quick.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quick_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickparticles_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickwidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickwidgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_script.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_script_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_scripttools.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_scripttools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sensors.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sensors_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sql.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sql_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_svg.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_svg_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_testlib.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_testlib_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_uitools.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_uitools_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webchannel.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webchannel_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkit.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkit_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkitwidgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkitwidgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_websockets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_websockets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_widgets.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_widgets_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_x11extras.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_x11extras_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xml.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xml_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xmlpatterns.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xmlpatterns_private.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_phonon4qt5.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_QuickAddons.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_Solid.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_SonnetCore.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_SonnetUi.pri \
|
||
/usr/lib/qt/mkspecs/modules/qt_ThreadWeaver.pri \
|
||
/usr/lib/qt/mkspecs/features/qt_functions.prf \
|
||
/usr/lib/qt/mkspecs/features/qt_config.prf \
|
||
/usr/lib/qt/mkspecs/linux-g++/qmake.conf \
|
||
/usr/lib/qt/mkspecs/features/spec_post.prf \
|
||
/usr/lib/qt/mkspecs/features/exclusive_builds.prf \
|
||
/usr/lib/qt/mkspecs/features/default_pre.prf \
|
||
/usr/lib/qt/mkspecs/features/resolve_config.prf \
|
||
/usr/lib/qt/mkspecs/features/default_post.prf \
|
||
/usr/lib/qt/mkspecs/features/warn_on.prf \
|
||
/usr/lib/qt/mkspecs/features/qt.prf \
|
||
/usr/lib/qt/mkspecs/features/resources.prf \
|
||
/usr/lib/qt/mkspecs/features/moc.prf \
|
||
/usr/lib/qt/mkspecs/features/unix/thread.prf \
|
||
/usr/lib/qt/mkspecs/features/testcase_targets.prf \
|
||
/usr/lib/qt/mkspecs/features/exceptions.prf \
|
||
/usr/lib/qt/mkspecs/features/yacc.prf \
|
||
/usr/lib/qt/mkspecs/features/lex.prf \
|
||
../example/Example.pro \
|
||
/usr/lib/libQt5Sql.prl \
|
||
/usr/lib/libQt5Core.prl
|
||
$(QMAKE) -spec linux-g++ CONFIG+=debug -o Makefile ../example/Example.pro
|
||
/usr/lib/qt/mkspecs/features/spec_pre.prf:
|
||
/usr/lib/qt/mkspecs/common/shell-unix.conf:
|
||
/usr/lib/qt/mkspecs/common/unix.conf:
|
||
/usr/lib/qt/mkspecs/common/linux.conf:
|
||
/usr/lib/qt/mkspecs/common/gcc-base.conf:
|
||
/usr/lib/qt/mkspecs/common/gcc-base-unix.conf:
|
||
/usr/lib/qt/mkspecs/common/g++-base.conf:
|
||
/usr/lib/qt/mkspecs/common/g++-unix.conf:
|
||
/usr/lib/qt/mkspecs/qconfig.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_Attica.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KActivities.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KArchive.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KAuth.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KBookmarks.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KCMUtils.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KCodecs.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KCompletion.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigCore.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigGui.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KConfigWidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KCoreAddons.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KCrash.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KDBusAddons.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KDeclarative.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KDESu.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KDEWebKit.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KEmoticons.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KGlobalAccel.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KGuiAddons.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KHtml.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KI18n.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KIconThemes.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KIdleTime.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOCore.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOFileWidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KIOWidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KItemModels.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KItemViews.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KJobWidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KJS.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KJSApi.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KJsEmbed.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KNewStuff.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KNotifications.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KNotifyConfig.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KNTLM.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KParts.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KPlotting.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KPty.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KRunner.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KScreen.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KService.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KTextEditor.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KTextWidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KUnitConversion.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KWallet.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KWidgetsAddons.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KWindowSystem.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_KXmlGui.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_bootstrap_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_clucene_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_concurrent.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_concurrent_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_core.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_core_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_dbus.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_dbus_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_declarative.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_declarative_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designer.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designer_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_designercomponents_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_gui.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_gui_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_help.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_help_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_location.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_location_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimedia.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimedia_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimediawidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_multimediawidgets_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_network.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_network_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_opengl.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_opengl_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_openglextensions.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_openglextensions_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_platformsupport_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_positioning.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_positioning_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_printsupport.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_printsupport_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qml.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qml_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmldevtools_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmltest.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qmltest_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_qtmultimediaquicktools_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quick.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quick_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickparticles_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickwidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_quickwidgets_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_script.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_script_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_scripttools.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_scripttools_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sensors.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sensors_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sql.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_sql_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_svg.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_svg_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_testlib.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_testlib_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_uitools.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_uitools_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webchannel.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webchannel_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkit.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkit_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkitwidgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_webkitwidgets_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_websockets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_websockets_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_widgets.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_widgets_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_x11extras.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_x11extras_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xml.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xml_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xmlpatterns.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_lib_xmlpatterns_private.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_phonon4qt5.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_QuickAddons.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_Solid.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_SonnetCore.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_SonnetUi.pri:
|
||
/usr/lib/qt/mkspecs/modules/qt_ThreadWeaver.pri:
|
||
/usr/lib/qt/mkspecs/features/qt_functions.prf:
|
||
/usr/lib/qt/mkspecs/features/qt_config.prf:
|
||
/usr/lib/qt/mkspecs/linux-g++/qmake.conf:
|
||
/usr/lib/qt/mkspecs/features/spec_post.prf:
|
||
/usr/lib/qt/mkspecs/features/exclusive_builds.prf:
|
||
/usr/lib/qt/mkspecs/features/default_pre.prf:
|
||
/usr/lib/qt/mkspecs/features/resolve_config.prf:
|
||
/usr/lib/qt/mkspecs/features/default_post.prf:
|
||
/usr/lib/qt/mkspecs/features/warn_on.prf:
|
||
/usr/lib/qt/mkspecs/features/qt.prf:
|
||
/usr/lib/qt/mkspecs/features/resources.prf:
|
||
/usr/lib/qt/mkspecs/features/moc.prf:
|
||
/usr/lib/qt/mkspecs/features/unix/thread.prf:
|
||
/usr/lib/qt/mkspecs/features/testcase_targets.prf:
|
||
/usr/lib/qt/mkspecs/features/exceptions.prf:
|
||
/usr/lib/qt/mkspecs/features/yacc.prf:
|
||
/usr/lib/qt/mkspecs/features/lex.prf:
|
||
../example/Example.pro:
|
||
/usr/lib/libQt5Sql.prl:
|
||
/usr/lib/libQt5Core.prl:
|
||
qmake: FORCE
|
||
@$(QMAKE) -spec linux-g++ CONFIG+=debug -o Makefile ../example/Example.pro
|
||
|
||
qmake_all: FORCE
|
||
|
||
|
||
all: Makefile $(TARGET)
|
||
|
||
dist: distdir FORCE
|
||
(cd `dirname $(DISTDIR)` && $(TAR) $(DISTNAME).tar $(DISTNAME) && $(COMPRESS) $(DISTNAME).tar) && $(MOVE) `dirname $(DISTDIR)`/$(DISTNAME).tar.gz . && $(DEL_FILE) -r $(DISTDIR)
|
||
|
||
distdir: FORCE
|
||
@test -d $(DISTDIR) || mkdir -p $(DISTDIR)
|
||
$(COPY_FILE) --parents $(DIST) $(DISTDIR)/
|
||
$(COPY_FILE) --parents ../example/models/artikel.h $(DISTDIR)/
|
||
$(COPY_FILE) --parents ../example/models/artikel.cpp $(DISTDIR)/
|
||
|
||
|
||
clean:compiler_clean
|
||
-$(DEL_FILE) $(OBJECTS)
|
||
-$(DEL_FILE) *~ core *.core
|
||
|
||
|
||
distclean: clean
|
||
-$(DEL_FILE) $(TARGET)
|
||
-$(DEL_FILE) Makefile
|
||
|
||
|
||
####### Sub-libraries
|
||
|
||
mocclean: compiler_moc_header_clean compiler_moc_source_clean
|
||
|
||
mocables: compiler_moc_header_make_all compiler_moc_source_make_all
|
||
|
||
check: first
|
||
|
||
compiler_rcc_make_all:
|
||
compiler_rcc_clean:
|
||
compiler_moc_header_make_all:
|
||
compiler_moc_header_clean:
|
||
compiler_moc_source_make_all:
|
||
compiler_moc_source_clean:
|
||
compiler_yacc_decl_make_all:
|
||
compiler_yacc_decl_clean:
|
||
compiler_yacc_impl_make_all:
|
||
compiler_yacc_impl_clean:
|
||
compiler_lex_make_all:
|
||
compiler_lex_clean:
|
||
compiler_clean:
|
||
|
||
####### Compile
|
||
|
||
artikel.o: ../example/models/artikel.cpp ../example/models/artikel.h
|
||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o artikel.o ../example/models/artikel.cpp
|
||
|
||
####### Install
|
||
|
||
install: FORCE
|
||
|
||
uninstall: FORCE
|
||
|
||
FORCE:
|
||
|
src/columnschema.h | ||
---|---|---|
#ifndef COLUMNSCHEMA_H
|
||
#define COLUMNSCHEMA_H
|
||
#include <QString>
|
||
#include <QList>
|
||
|
||
namespace CuteEntityManager {
|
||
|
src/database.cpp | ||
---|---|---|
}
|
||
|
||
|
||
DatabaseType Database::getDatabaseType() {
|
||
QString d = this->database.driverName();
|
||
if(d == "qmysql") {
|
||
return CuteEntityManager::MYSQL;
|
||
} else if(d == "qpgsql") {
|
||
return CuteEntityManager::PGSQL;
|
||
} else {
|
||
return CuteEntityManager::SQLITE;
|
||
}
|
||
int Database::getDatabaseType() {
|
||
return CuteEntityManager::getDatabaseType(this->database.driverName());
|
||
}
|
||
|
||
void Database::getTableListFromDatabase() {
|
||
if(this->database.open()) {
|
||
QString q = "";
|
||
if(this->databasetype == OpenTeacherTool::SQLITE) {
|
||
if(this->databasetype == CuteEntityManager::SQLITE) {
|
||
q = this->sqliteTableList();
|
||
} else if(this->databasetype == OpenTeacherTool::MYSQL){
|
||
} else if(this->databasetype == CuteEntityManager::MYSQL){
|
||
q = this->mysqlTableList();
|
||
} else if(this->databasetype == OpenTeacherTool::PGSQL) {
|
||
} else if(this->databasetype == CuteEntityManager::PGSQL) {
|
||
q = this->pgsqlSeqTable();
|
||
}
|
||
QSqlQuery query = QSqlQuery(this->database);
|
||
... | ... | |
|
||
QChar Database::escapeChar() {
|
||
QChar c = QChar();
|
||
if(this->databasetype == OpenTeacherTool::SQLITE) {
|
||
if(this->databasetype == CuteEntityManager::SQLITE) {
|
||
c = '\'';
|
||
} else if(this->databasetype == OpenTeacherTool::MYSQL) {
|
||
} else if(this->databasetype == CuteEntityManager::MYSQL) {
|
||
c = '`';
|
||
}
|
||
return c;
|
||
... | ... | |
if(this->database.open() && this->getLastId() == -1) {
|
||
QString query = "";
|
||
QStringList l = QStringList();
|
||
if(this->databasetype == OpenTeacherTool::MYSQL) {
|
||
if(this->databasetype == CuteEntityManager::MYSQL) {
|
||
query = this->mysqlSeqTable();
|
||
} else if(this->databasetype == OpenTeacherTool::SQLITE) {
|
||
} else if(this->databasetype == CuteEntityManager::SQLITE) {
|
||
query = this->sqliteSeqTable();
|
||
} else if(this->databasetype == OpenTeacherTool::PGSQL) {
|
||
} else if(this->databasetype == CuteEntityManager::PGSQL) {
|
||
query = this->pgsqlSeqTable();
|
||
}
|
||
l.append(query);
|
src/database.h | ||
---|---|---|
void refreshTableList();
|
||
bool containsTable(QString tblname);
|
||
bool updateSequenceCounter(QSqlQuery &q);
|
||
DatabaseType getDatabaseType();
|
||
int getDatabaseType();
|
||
QChar escapeChar();
|
||
};
|
||
}
|
src/entity.h | ||
---|---|---|
class Entity : public QObject {
|
||
Q_OBJECT
|
||
public:
|
||
qint64 getId() = 0;
|
||
void setId(qint64 id) = 0;
|
||
virtual qint64 getId();
|
||
virtual void setId(qint64 id);
|
||
virtual ~Entity();
|
||
virtual QString getTablename() = 0;
|
||
// virtual QMap<QString, QString> getManyToManyRelations() = 0; //Key = Table, Value = joined Table Column
|
||
protected:
|
||
Entity();
|
||
qint64 id;
|
||
};
|
||
}
|
||
#endif // MODEL_H
|
src/entitymanager.cpp | ||
---|---|---|
}
|
||
}
|
||
|
||
qint8 EntityManager::count(Entity* entity, bool ignoreID) {
|
||
qint8 rc = 0;
|
||
QSqlQuery q = this->db->getQuery("SELECT COUNT(*) FROM " + entity->getTablename() + this->where(entity->getAttributeValues(),"AND",ignoreID));
|
||
this->bindValues(entity->getAttributeValues(),q);
|
||
this->db->select(q);
|
||
if(q.next()) {
|
||
rc = q.value(0).toInt();
|
||
}
|
||
return rc;
|
||
}
|
||
|
||
QString EntityManager::buildCreateQuery(QHash<QString,QVariant>::const_iterator i, QHash<QString,QVariant>::const_iterator end, QString &p1, QString &p2) {
|
||
bool first = true;
|
||
while(i != end) {
|
||
if(!first) {
|
||
p1 += ",";
|
||
p2 += ",";
|
||
} else {
|
||
first = false;
|
||
}
|
||
p1 += i.key();
|
||
p2 += ":"+i.key();
|
||
++i;
|
||
}
|
||
p1 += ")";
|
||
p2 += ");";
|
||
return p1 + p2;
|
||
}
|
||
|
||
bool EntityManager::create(Entity *entity) {
|
||
bool rc = false;
|
||
if(this->checkTable(entity) && this->count(entity) == 0) {
|
||
QSqlQuery q = this->db->getQuery();
|
||
QString p1 = "INSERT INTO " + entity->getTablename() + "(";
|
||
QString p2 = "VALUES(";
|
||
entity->setId(this->db->getLastId());
|
||
if(!entity->getAttributeValues()->isEmpty()) {
|
||
q.prepare(this->buildCreateQuery(entity->getAttributeValues()->constBegin(),entity->getAttributeValues()->constEnd(),p1,p2));
|
||
}
|
||
this->bindValues(entity->getAttributeValues(),q);
|
||
if(this->db->updateSequenceCounter(q)) {
|
||
entity->setId(this->findId(entity));
|
||
rc = true;
|
||
}
|
||
}
|
||
return rc;
|
||
}
|
||
|
||
QHash<QString,QVariant> EntityManager::find(qint64 id, QString tblname) {
|
||
QSqlQuery q = this->db->getQuery("SELECT * FROM " + tblname +" WHERE id= :id LIMIT 1;");
|
||
q.bindValue(":id",id);
|
||
this->db->select(q);
|
||
QSqlRecord rec = q.record();
|
||
QHash<QString,QVariant> map = QHash<QString, QVariant>();
|
||
if(q.next()) {
|
||
for (int var = 0; var < rec.count(); ++var) {
|
||
map.insert(rec.fieldName(var),q.value(rec.indexOf(rec.fieldName(var)))); // parameters of q.value can maybe replaced with var
|
||
}
|
||
}
|
||
return map;
|
||
}
|
||
|
||
QList<QHash <QString,QVariant> > EntityManager::findByAttributes(QHash<QString, QVariant> *m, const QString &tblname, bool ignoreID) {
|
||
QSqlQuery q = this->db->getQuery("SELECT * FROM " + tblname + this->where(m,"AND",ignoreID));
|
||
this->bindValues(m,q,true);
|
||
return this->convertQueryResult(q);
|
||
}
|
||
|
||
QList<QHash<QString, QVariant> > EntityManager::convertQueryResult(QSqlQuery &q) {
|
||
QList<QHash <QString, QVariant> > listmap = QList<QHash <QString,QVariant> >();
|
||
this->db->select(q);
|
||
QSqlRecord rec = q.record();
|
||
QStringList l = QStringList();
|
||
qint16 field_count = rec.count();
|
||
for (int var = 0; var < field_count; ++var) {
|
||
l.append(rec.fieldName(var));
|
||
}
|
||
QHash<QString,QVariant> map = QHash<QString, QVariant>();
|
||
while(q.next()) {
|
||
for (int var = 0; var < field_count; ++var) {
|
||
map.insert(l.at(var),q.value(rec.indexOf(l.at(var))));
|
||
}
|
||
listmap.append(map);
|
||
}
|
||
return listmap;
|
||
}
|
||
|
||
QList<QHash <QString,QVariant> > EntityManager::findAll(QString tblname) {
|
||
QSqlQuery q =this->db->getQuery("SELECT * FROM " + tblname + ";");
|
||
return this->convertQueryResult(q);
|
||
}
|
||
|
||
bool EntityManager::merge(Entity *entity) {
|
||
if(this->count(entity) == 0 && entity->getId() != -1) {
|
||
QSqlQuery q = this->db->getQuery("UPDATE " + entity->getTablename() + " SET " +this->attributes(entity->getAttributeValues()) + " WHERE id=:idM;");
|
||
this->bindValues(entity->getAttributeValues(),q);
|
||
q.bindValue(":idM",entity->getId());
|
||
return this->db->transaction(q);
|
||
} else {
|
||
return false;
|
||
}
|
||
}
|
||
|
||
|
||
qint64 EntityManager::findId(Entity *entity) {
|
||
qint64 r = -1;
|
||
QSqlQuery q = this->db->getQuery("SELECT id FROM " + entity->getTablename() + this->where(entity->getAttributeValues(),"AND",true) + " LIMIT 1");
|
||
this->bindValues(entity->getAttributeValues(),q);
|
||
this->db->select(q);
|
||
if(q.next()) {
|
||
r = q.value(0).toInt();
|
||
}
|
||
return r;
|
||
}
|
||
|
||
QString EntityManager::attributes(QHash<QString, QVariant> *m, QString conjunction, bool ignoreID) {
|
||
QString rc = "";
|
||
if(!m->isEmpty()) {
|
||
QHash<QString, QVariant>::const_iterator i = m->constBegin();
|
||
while(i != m->constEnd()) {
|
||
if(!ignoreID || (ignoreID && !(i.key() == "id"))) {
|
||
if(!(rc == "")) {
|
||
rc += " " + conjunction + " ";
|
||
}
|
||
rc += i.key() + "= :" +i.key();
|
||
}
|
||
++i;
|
||
}
|
||
}
|
||
return rc;
|
||
}
|
||
|
||
|
||
QString EntityManager::where(QHash<QString, QVariant> *m, QString conjunction, bool ignoreID) {
|
||
if(m->size() == 0 || (ignoreID && m->contains("id") && m->size() == 1)) {
|
||
return "";
|
||
}
|
||
return " WHERE " + this->attributes(m,conjunction,ignoreID);
|
||
}
|
||
|
||
QString EntityManager::where(Entity *entity, QString conjunction, bool ignoreID) {
|
||
return this->where(entity->getAttributeValues(),conjunction,ignoreID);
|
||
}
|
||
|
||
QList<QHash <QString,QVariant> > EntityManager::findByAttributes(Entity *entity, bool ignoreID) {
|
||
return this->findByAttributes(entity->getAttributeValues(), entity->getTablename(),ignoreID);
|
||
}
|
||
|
||
bool EntityManager::save(Entity *entity) {
|
||
if(entity->getId() > -1) {
|
||
return this->merge(entity);
|
||
} else {
|
||
return this->create(entity);
|
||
}
|
||
}
|
||
|
||
|
||
bool EntityManager::remove(Entity *&entity) {
|
||
bool rc = false;
|
||
QSqlQuery q = this->db->getQuery("DELETE FROM " + entity->getTablename() + " WHERE id= :id;");
|
||
q.bindValue(":id",entity->getId());
|
||
if(this->db->transaction(q)) {
|
||
delete entity;
|
||
entity = 0;
|
||
rc = true;
|
||
}
|
||
return rc;
|
||
}
|
||
|
||
QString EntityManager::createTableQuery(Entity *entity) {
|
||
QChar c = this->db->escapeChar();
|
||
QHash<QString, QString> m = entity->getProperties(this->db->getDatabaseType());
|
||
bool first = true;
|
||
QString s = "CREATE TABLE IF NOT EXISTS ";
|
||
s.append(c).append(entity->getTablename()).append(c).append("(");
|
||
QHash<QString, QString>::const_iterator i = m.constBegin();
|
||
while (i != m.constEnd()) {
|
||
if(first) {
|
||
first = false;
|
||
} else {
|
||
s.append(',');
|
||
}
|
||
s.append(c).append(i.key()).append(c).append(" " + i.value());
|
||
++i;
|
||
}
|
||
s.append(");");
|
||
return s;
|
||
}
|
||
|
||
bool EntityManager::createTable(Entity *entity) {
|
||
bool rc = false;
|
||
this->db->containsTable(entity->getTablename()) ? rc = true : rc = false;
|
||
if(!rc) {
|
||
QSqlQuery q = this->db->getQuery(this->createTableQuery(entity));
|
||
if(this->db->transaction(q)) {
|
||
this->db->refreshTableList();
|
||
rc = true;
|
||
}
|
||
}
|
||
return rc;
|
||
|
||
}
|
||
//qint8 EntityManager::count(Entity* entity, bool ignoreID) {
|
||
// qint8 rc = 0;
|
||
// QSqlQuery q = this->db->getQuery("SELECT COUNT(*) FROM " + entity->getTablename() + this->where(entity->getAttributeValues(),"AND",ignoreID));
|
||
// this->bindValues(entity->getAttributeValues(),q);
|
||
// this->db->select(q);
|
||
// if(q.next()) {
|
||
// rc = q.value(0).toInt();
|
||
// }
|
||
// return rc;
|
||
//}
|
||
|
||
//QString EntityManager::buildCreateQuery(QHash<QString,QVariant>::const_iterator i, QHash<QString,QVariant>::const_iterator end, QString &p1, QString &p2) {
|
||
// bool first = true;
|
||
// while(i != end) {
|
||
// if(!first) {
|
||
// p1 += ",";
|
||
// p2 += ",";
|
||
// } else {
|
||
// first = false;
|
||
// }
|
||
// p1 += i.key();
|
||
// p2 += ":"+i.key();
|
||
// ++i;
|
||
// }
|
||
// p1 += ")";
|
||
// p2 += ");";
|
||
// return p1 + p2;
|
||
//}
|
||
|
||
//bool EntityManager::create(Entity *entity) {
|
||
// bool rc = false;
|
||
// if(this->checkTable(entity) && this->count(entity) == 0) {
|
||
// QSqlQuery q = this->db->getQuery();
|
||
// QString p1 = "INSERT INTO " + entity->getTablename() + "(";
|
||
// QString p2 = "VALUES(";
|
||
// entity->setId(this->db->getLastId());
|
||
// if(!entity->getAttributeValues()->isEmpty()) {
|
||
// q.prepare(this->buildCreateQuery(entity->getAttributeValues()->constBegin(),entity->getAttributeValues()->constEnd(),p1,p2));
|
||
// }
|
||
// this->bindValues(entity->getAttributeValues(),q);
|
||
// if(this->db->updateSequenceCounter(q)) {
|
||
// entity->setId(this->findId(entity));
|
||
// rc = true;
|
||
// }
|
||
// }
|
||
// return rc;
|
||
//}
|
||
|
||
//QHash<QString,QVariant> EntityManager::find(qint64 id, QString tblname) {
|
||
// QSqlQuery q = this->db->getQuery("SELECT * FROM " + tblname +" WHERE id= :id LIMIT 1;");
|
||
// q.bindValue(":id",id);
|
||
// this->db->select(q);
|
||
// QSqlRecord rec = q.record();
|
||
// QHash<QString,QVariant> map = QHash<QString, QVariant>();
|
||
// if(q.next()) {
|
||
// for (int var = 0; var < rec.count(); ++var) {
|
||
// map.insert(rec.fieldName(var),q.value(rec.indexOf(rec.fieldName(var)))); // parameters of q.value can maybe replaced with var
|
||
// }
|
||
// }
|
||
// return map;
|
||
//}
|
||
|
||
//QList<QHash <QString,QVariant> > EntityManager::findByAttributes(QHash<QString, QVariant> *m, const QString &tblname, bool ignoreID) {
|
||
// QSqlQuery q = this->db->getQuery("SELECT * FROM " + tblname + this->where(m,"AND",ignoreID));
|
||
// this->bindValues(m,q,true);
|
||
// return this->convertQueryResult(q);
|
||
//}
|
||
|
||
//QList<QHash<QString, QVariant> > EntityManager::convertQueryResult(QSqlQuery &q) {
|
||
// QList<QHash <QString, QVariant> > listmap = QList<QHash <QString,QVariant> >();
|
||
// this->db->select(q);
|
||
// QSqlRecord rec = q.record();
|
||
// QStringList l = QStringList();
|
||
// qint16 field_count = rec.count();
|
||
// for (int var = 0; var < field_count; ++var) {
|
||
// l.append(rec.fieldName(var));
|
||
// }
|
||
// QHash<QString,QVariant> map = QHash<QString, QVariant>();
|
||
// while(q.next()) {
|
||
// for (int var = 0; var < field_count; ++var) {
|
||
// map.insert(l.at(var),q.value(rec.indexOf(l.at(var))));
|
||
// }
|
||
// listmap.append(map);
|
||
// }
|
||
// return listmap;
|
||
//}
|
||
|
||
//QList<QHash <QString,QVariant> > EntityManager::findAll(QString tblname) {
|
||
// QSqlQuery q =this->db->getQuery("SELECT * FROM " + tblname + ";");
|
||
// return this->convertQueryResult(q);
|
||
//}
|
||
|
||
//bool EntityManager::merge(Entity *entity) {
|
||
// if(this->count(entity) == 0 && entity->getId() != -1) {
|
||
// QSqlQuery q = this->db->getQuery("UPDATE " + entity->getTablename() + " SET " +this->attributes(entity->getAttributeValues()) + " WHERE id=:idM;");
|
||
// this->bindValues(entity->getAttributeValues(),q);
|
||
// q.bindValue(":idM",entity->getId());
|
||
// return this->db->transaction(q);
|
||
// } else {
|
||
// return false;
|
||
// }
|
||
//}
|
||
|
||
|
||
//qint64 EntityManager::findId(Entity *entity) {
|
||
// qint64 r = -1;
|
||
// QSqlQuery q = this->db->getQuery("SELECT id FROM " + entity->getTablename() + this->where(entity->getAttributeValues(),"AND",true) + " LIMIT 1");
|
||
// this->bindValues(entity->getAttributeValues(),q);
|
||
// this->db->select(q);
|
||
// if(q.next()) {
|
||
// r = q.value(0).toInt();
|
||
// }
|
||
// return r;
|
||
//}
|
||
|
||
//QString EntityManager::attributes(QHash<QString, QVariant> *m, QString conjunction, bool ignoreID) {
|
||
// QString rc = "";
|
||
// if(!m->isEmpty()) {
|
||
// QHash<QString, QVariant>::const_iterator i = m->constBegin();
|
||
// while(i != m->constEnd()) {
|
||
// if(!ignoreID || (ignoreID && !(i.key() == "id"))) {
|
||
// if(!(rc == "")) {
|
||
// rc += " " + conjunction + " ";
|
||
// }
|
||
// rc += i.key() + "= :" +i.key();
|
||
// }
|
||
// ++i;
|
||
// }
|
||
// }
|
||
// return rc;
|
||
//}
|
||
|
||
|
||
//QString EntityManager::where(QHash<QString, QVariant> *m, QString conjunction, bool ignoreID) {
|
||
// if(m->size() == 0 || (ignoreID && m->contains("id") && m->size() == 1)) {
|
||
// return "";
|
||
// }
|
||
// return " WHERE " + this->attributes(m,conjunction,ignoreID);
|
||
//}
|
||
|
||
//QString EntityManager::where(Entity *entity, QString conjunction, bool ignoreID) {
|
||
// return this->where(entity->getAttributeValues(),conjunction,ignoreID);
|
||
//}
|
||
|
||
//QList<QHash <QString,QVariant> > EntityManager::findByAttributes(Entity *entity, bool ignoreID) {
|
||
// return this->findByAttributes(entity->getAttributeValues(), entity->getTablename(),ignoreID);
|
||
//}
|
||
|
||
//bool EntityManager::save(Entity *entity) {
|
||
// if(entity->getId() > -1) {
|
||
// return this->merge(entity);
|
||
// } else {
|
||
// return this->create(entity);
|
||
// }
|
||
//}
|
||
|
||
|
||
//bool EntityManager::remove(Entity *&entity) {
|
||
// bool rc = false;
|
||
// QSqlQuery q = this->db->getQuery("DELETE FROM " + entity->getTablename() + " WHERE id= :id;");
|
||
// q.bindValue(":id",entity->getId());
|
||
// if(this->db->transaction(q)) {
|
||
// delete entity;
|
||
// entity = 0;
|
||
// rc = true;
|
||
// }
|
||
// return rc;
|
||
//}
|
||
|
||
//QString EntityManager::createTableQuery(Entity *entity) {
|
||
// QChar c = this->db->escapeChar();
|
||
// QHash<QString, QString> m = entity->getProperties(this->db->getDatabaseType());
|
||
// bool first = true;
|
||
// QString s = "CREATE TABLE IF NOT EXISTS ";
|
||
// s.append(c).append(entity->getTablename()).append(c).append("(");
|
||
// QHash<QString, QString>::const_iterator i = m.constBegin();
|
||
// while (i != m.constEnd()) {
|
||
// if(first) {
|
||
// first = false;
|
||
// } else {
|
||
// s.append(',');
|
||
// }
|
||
// s.append(c).append(i.key()).append(c).append(" " + i.value());
|
||
// ++i;
|
||
// }
|
||
// s.append(");");
|
||
// return s;
|
||
//}
|
||
|
||
//bool EntityManager::createTable(Entity *entity) {
|
||
// bool rc = false;
|
||
// this->db->containsTable(entity->getTablename()) ? rc = true : rc = false;
|
||
// if(!rc) {
|
||
// QSqlQuery q = this->db->getQuery(this->createTableQuery(entity));
|
||
// if(this->db->transaction(q)) {
|
||
// this->db->refreshTableList();
|
||
// rc = true;
|
||
// }
|
||
// }
|
||
// return rc;
|
||
|
||
//}
|
src/enums/databasetype.h | ||
---|---|---|
|
||
#ifndef DATABASETYPE_H
|
||
#define DATABASETYPE_H
|
||
|
||
#include <QString>
|
||
#include "../schema.h"
|
||
#include "../schema/sqliteschema.h"
|
||
namespace CuteEntityManager {
|
||
enum DatabaseType {
|
||
SQLITE=0,
|
||
PGSQL=1,
|
||
MYSQL=2
|
||
};
|
||
enum DatabaseType {
|
||
SQLITE=0,
|
||
PGSQL=1,
|
||
MYSQL=2
|
||
};
|
||
|
||
static const int getDatabaseType(QString s) {
|
||
if(s == "qmysql") {
|
||
return CuteEntityManager::MYSQL;
|
||
} else if(s == "qpgsql") {
|
||
return CuteEntityManager::PGSQL;
|
||
} else if(s == "qsqlite"){
|
||
return CuteEntityManager::SQLITE;
|
||
}
|
||
}
|
||
|
||
static const Schema getSchema(int db) {
|
||
switch (db) {
|
||
case SQLITE:
|
||
return SqliteSchema();
|
||
break;
|
||
case PGSQL:
|
||
case MYSQL:
|
||
default:
|
||
return SqliteSchema();
|
||
break;
|
||
}
|
||
}
|
||
|
||
|
||
}
|
||
#endif // DATABASETYPE_H
|
src/schema.cpp | ||
---|---|---|
using namespace CuteEntityManager;
|
||
|
||
Schema::Schema() {
|
||
|
||
this->typeMap = QSharedPointer<QHash<QString,QString>>(new QHash<QString,QString>());
|
||
}
|
||
|
||
Schema::~Schema() {
|
src/schema.h | ||
---|---|---|
#define SCHEMA_H
|
||
#include <QString>
|
||
#include "tableschema.h"
|
||
#include <QHash>
|
||
#include <QSharedPointer>
|
||
|
||
namespace CuteEntityManager {
|
||
|
||
class Schema {
|
||
public:
|
||
Schema();
|
||
~Schema();
|
||
virtual ~Schema();
|
||
const QString TYPE_PK = "pk";
|
||
const QString TYPE_BIGPK = "bigpk";
|
||
const QString TYPE_STRING = "string";
|
||
const QString TYPE_TEXT = "text";
|
||
const QString TYPE_SMALLINT = "smallint";
|
||
const QString TYPE_INTEGER = "integer";
|
||
const QString TYPE_BIGINT = "bigint";
|
||
const QString TYPE_FLOAT = "float";
|
||
const QString TYPE_DOUBLE = "double";
|
||
const QString TYPE_DECIMAL = "decimal";
|
||
const QString TYPE_DATETIME = "datetime";
|
||
const QString TYPE_TIMESTAMP = "timestamp";
|
||
const QString TYPE_TIME = "time";
|
||
const QString TYPE_DATE = "date";
|
||
const QString TYPE_BINARY = "binary";
|
||
const QString TYPE_BOOLEAN = "boolean";
|
||
const QString TYPE_MONEY = "money";
|
||
virtual QHash<QString, QString> *getTypeMap() = 0;
|
||
|
||
protected:
|
||
virtual QList<QString> findTableNames(QString schema = "");
|
||
virtual QList<QString> findUniqueIndexes(QString tableName);
|
||
virtual TableSchema findConstraints(TableSchema ts);
|
||
virtual QString getCreateTableSql(TableSchema ts);
|
||
virtual bool findColumns(TableSchema ts);
|
||
|
||
virtual bool findColumns(TableSchema ts);
|
||
QSharedPointer<QHash<QString, QString>> typeMap;
|
||
|
||
};
|
||
}
|
src/schema/mysqlschema.cpp | ||
---|---|---|
#include "mysqlschema.h"
|
||
using namespace CuteEntityManager;
|
||
|
||
MysqlSchema::MysqlSchema() : Schema() {
|
||
|
||
}
|
||
|
||
MysqlSchema::~MysqlSchema() {
|
||
|
||
}
|
||
|
||
QHash<QString, QString>* MysqlSchema::getTypeMap() {
|
||
if(this->typeMap.data()->empty()) {
|
||
// this->typeMap->data()->insert(TYPE_SMALLINT, 'tinyint');
|
||
// this->typeMap->data()->insert(TYPE_SMALLINT, 'bit');
|
||
// this->typeMap->data()->insert(TYPE_BOOLEAN, 'boolean');
|
||
// this->typeMap->data()->insert(TYPE_BOOLEAN, 'bool');
|
||
// this->typeMap->data()->insert(TYPE_SMALLINT, 'smallint');
|
||
// this->typeMap->data()->insert(TYPE_INTEGER, 'mediumint');
|
||
// this->typeMap->data()->insert(TYPE_INTEGER, 'int');
|
||
// this->typeMap->data()->insert(TYPE_INTEGER, 'integer');
|
||
// this->typeMap->data()->insert(TYPE_BIGINT, 'bigint');
|
||
// this->typeMap->data()->insert(TYPE_FLOAT, 'float');
|
||
// this->typeMap->data()->insert(TYPE_DOUBLE, 'double');
|
||
// this->typeMap->data()->insert(TYPE_FLOAT, 'real');
|
||
// this->typeMap->data()->insert(TYPE_DECIMAL, 'decimal');
|
||
// this->typeMap->data()->insert(TYPE_DECIMAL, 'numeric');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'tinytext');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'mediumtext');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'longtext');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'text');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'varchar');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'string');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'char');
|
||
// this->typeMap->data()->insert(TYPE_BINARY, 'blob');
|
||
// this->typeMap->data()->insert(TYPE_DATETIME, 'datetime');
|
||
// this->typeMap->data()->insert(TYPE_DATE, 'year');
|
||
// this->typeMap->data()->insert(TYPE_DATE, 'date');
|
||
// this->typeMap->data()->insert(TYPE_TIME, 'time');
|
||
// this->typeMap->data()->insert(TYPE_TIMESTAMP, 'timestamp');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'enum');
|
||
}
|
||
return this->typeMap.data();
|
||
}
|
src/schema/mysqlschema.h | ||
---|---|---|
#ifndef MYSQLSCHEMA_H
|
||
#define MYSQLSCHEMA_H
|
||
#include "../schema.h"
|
||
namespace CuteEntityManager {
|
||
class MysqlSchema : public Schema {
|
||
public:
|
||
MysqlSchema();
|
||
~MysqlSchema();
|
||
QHash<QString, QString> *getTypeMap();
|
||
};
|
||
}
|
||
#endif // MYSQLSCHEMA_H
|
src/schema/pgsqlschema.cpp | ||
---|---|---|
#include "pgsqlschema.h"
|
||
using namespace CuteEntityManager;
|
||
|
||
PgSqlSchema::PgSqlSchema() : Schema() {
|
||
|
||
}
|
||
|
||
PgSqlSchema::~PgSqlSchema() {
|
||
|
||
}
|
||
|
||
QHash<QString, QString>* PgSqlSchema::getTypeMap() {
|
||
if(this->typeMap.data()->empty()) {
|
||
// this->typeMap->data()->insert(TYPE_SMALLINT, 'tinyint');
|
||
// this->typeMap->data()->insert(TYPE_SMALLINT, 'bit');
|
||
// this->typeMap->data()->insert(TYPE_BOOLEAN, 'boolean');
|
||
// this->typeMap->data()->insert(TYPE_BOOLEAN, 'bool');
|
||
// this->typeMap->data()->insert(TYPE_SMALLINT, 'smallint');
|
||
// this->typeMap->data()->insert(TYPE_INTEGER, 'mediumint');
|
||
// this->typeMap->data()->insert(TYPE_INTEGER, 'int');
|
||
// this->typeMap->data()->insert(TYPE_INTEGER, 'integer');
|
||
// this->typeMap->data()->insert(TYPE_BIGINT, 'bigint');
|
||
// this->typeMap->data()->insert(TYPE_FLOAT, 'float');
|
||
// this->typeMap->data()->insert(TYPE_DOUBLE, 'double');
|
||
// this->typeMap->data()->insert(TYPE_FLOAT, 'real');
|
||
// this->typeMap->data()->insert(TYPE_DECIMAL, 'decimal');
|
||
// this->typeMap->data()->insert(TYPE_DECIMAL, 'numeric');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'tinytext');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'mediumtext');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'longtext');
|
||
// this->typeMap->data()->insert(TYPE_TEXT, 'text');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'varchar');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'string');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'char');
|
||
// this->typeMap->data()->insert(TYPE_BINARY, 'blob');
|
||
// this->typeMap->data()->insert(TYPE_DATETIME, 'datetime');
|
||
// this->typeMap->data()->insert(TYPE_DATE, 'year');
|
||
// this->typeMap->data()->insert(TYPE_DATE, 'date');
|
||
// this->typeMap->data()->insert(TYPE_TIME, 'time');
|
||
// this->typeMap->data()->insert(TYPE_TIMESTAMP, 'timestamp');
|
||
// this->typeMap->data()->insert(TYPE_STRING, 'enum');
|
||
}
|
||
return this->typeMap.data();
|
||
}
|
||
|
src/schema/pgsqlschema.h | ||
---|---|---|
#ifndef PGSQLSCHEMA_H
|
||
#define PGSQLSCHEMA_H
|
||
#include "../schema.h"
|
||
namespace CuteEntityManager {
|
||
class PgSqlSchema : public Schema {
|
||
public:
|
||
PgSqlSchema();
|
||
~PgSqlSchema();
|
||
QHash<QString, QString> *getTypeMap();
|
||
};
|
||
}
|
||
|
||
#endif // PGSQLSCHEMA_H
|
src/schema/sqliteschema.cpp | ||
---|---|---|
#include "sqliteschema.h"
|
||
using namespace CuteEntityManager;
|
||
|
||
SqliteSchema::SqliteSchema() : parent() {
|
||
SqliteSchema::SqliteSchema() : Schema() {
|
||
|
||
}
|
||
|
||
SqliteSchema::~SqliteSchema()
|
||
{
|
||
SqliteSchema::~SqliteSchema() {
|
||
|
||
}
|
||
|
||
|
||
QString Database::sqliteTableList() {
|
||
return "SELECT tbl_name FROM sqlite_master WHERE type='table';";
|
||
QHash<QString, QString>* SqliteSchema::getTypeMap() {
|
||
if(this->typeMap.data()->empty()) {
|
||
this->typeMap.data()->insert(TYPE_SMALLINT, "tinyint");
|
||
this->typeMap.data()->insert(TYPE_SMALLINT, "bit");
|
||
this->typeMap.data()->insert(TYPE_BOOLEAN, "boolean");
|
||
this->typeMap.data()->insert(TYPE_BOOLEAN, "bool");
|
||
this->typeMap.data()->insert(TYPE_SMALLINT, "smallint");
|
||
this->typeMap.data()->insert(TYPE_INTEGER, "mediumint");
|
||
this->typeMap.data()->insert(TYPE_INTEGER, "int");
|
||
this->typeMap.data()->insert(TYPE_INTEGER, "integer");
|
||
this->typeMap.data()->insert(TYPE_BIGINT, "bigint");
|
||
this->typeMap.data()->insert(TYPE_FLOAT, "float");
|
||
this->typeMap.data()->insert(TYPE_DOUBLE, "double");
|
||
this->typeMap.data()->insert(TYPE_FLOAT, "real");
|
||
this->typeMap.data()->insert(TYPE_DECIMAL, "decimal");
|
||
this->typeMap.data()->insert(TYPE_DECIMAL, "numeric");
|
||
this->typeMap.data()->insert(TYPE_TEXT, "tinytext");
|
||
this->typeMap.data()->insert(TYPE_TEXT, "mediumtext");
|
||
this->typeMap.data()->insert(TYPE_TEXT, "longtext");
|
||
this->typeMap.data()->insert(TYPE_TEXT, "text");
|
||
this->typeMap.data()->insert(TYPE_STRING, "varchar");
|
||
this->typeMap.data()->insert(TYPE_STRING, "string");
|
||
this->typeMap.data()->insert(TYPE_STRING, "char");
|
||
this->typeMap.data()->insert(TYPE_BINARY, "blob");
|
||
this->typeMap.data()->insert(TYPE_DATETIME, "datetime");
|
||
this->typeMap.data()->insert(TYPE_DATE, "year");
|
||
this->typeMap.data()->insert(TYPE_DATE, "date");
|
||
this->typeMap.data()->insert(TYPE_TIME, "time");
|
||
this->typeMap.data()->insert(TYPE_TIMESTAMP, "timestamp");
|
||
this->typeMap.data()->insert(TYPE_STRING, "enum");
|
||
}
|
||
return this->typeMap.data();
|
||
}
|
||
|
||
|
||
//QString Database::sqliteTableList() {
|
||
// return "SELECT tbl_name FROM sqlite_master WHERE type="table";";
|
||
//}
|
src/schema/sqliteschema.h | ||
---|---|---|
public:
|
||
SqliteSchema();
|
||
~SqliteSchema();
|
||
QHash<QString, QString> *getTypeMap();
|
||
};
|
||
}
|
||
#endif // SQLITESCHEMA_H
|
src/tableschema.cpp | ||
---|---|---|
#include "tableschema.h"
|
||
using namespace CuteEntityManager;
|
||
|
||
TableSchema::TableSchema()
|
||
{
|
Auch abrufbar als: Unified diff
...