From d5ebb7ca124a760c5813f5e1ac265cf3c5a996c4 Mon Sep 17 00:00:00 2001 From: Tomasz Sowa Date: Wed, 13 Oct 2021 01:27:14 +0200 Subject: [PATCH] changed the way how the request's answer is created, now winix can return json, xml, csv from out_main_stream or from frames and json from models removed from Request: bool send_bin_stream bool return_json bool return_info_only pt::Space info bool page_generated bool out_main_stream_use_html_filter bool out_streams_use_html_filter added to Request: enum AnswerSource enum AnswerContainer AnswerSource answer_source AnswerContainer answer_container bool use_ezc_engine std::wstring frame bool send_all_frames bool use_html_filter added to Config: // the name of the url parameter for returning all frames, e.g. https://domain.tld/mydir/myfunction/allframes // default: allframes std::wstring request_all_frames_parameter; // the name of the root element when serializing request answer to xml // default: winix std::wstring xml_root; algorithm (the whole algorithm is described in core/request.h): at the beginning of a request winix sets answer_source to models answer_container to text use_ezc_engine to true next answer_container and use_ezc_engine can be changed in the following way: 1. winix will look for 'Accept' http header and depending on the header winix will set: (not implemented yet) Accept | answer_container | use_ezc_engine ------------------------------------|----------------- application/json | json | false application/xml | xml | false text/csv | csv | false 2. next answer_container is set depending on 'container' url parameter container | answer_container --------------------------------------------------------- not present | don't change the value text | text json | json xml | xml csv | csv use_ezc_engine is set depending on 'answer' url parameter: answer | use_ezc_engine --------------------------------- not present | don't change the value html | true data | false if 'answer' is html then we take into account two more parameters: frame: frame_name (empty default) - if set then winix returns this specific frame allframes: (if present then winix returns all frames) --- winixd/Makefile.dep | 2 +- winixd/core/Makefile.dep | 150 +++--- winixd/core/app.cpp | 714 ++++++++++++++++++----------- winixd/core/app.h | 33 +- winixd/core/compress.cpp | 2 + winixd/core/config.cpp | 3 + winixd/core/config.h | 8 + winixd/core/header.h | 24 +- winixd/core/misc.cpp | 13 +- winixd/core/misc.h | 1 + winixd/core/request.cpp | 119 ++++- winixd/core/request.h | 255 ++++++++--- winixd/core/system.cpp | 21 +- winixd/core/system.h | 2 +- winixd/functions/Makefile.dep | 12 +- winixd/functions/cat.cpp | 5 + winixd/functions/cp.cpp | 6 +- winixd/functions/download.cpp | 2 +- winixd/functions/emacs.cpp | 44 +- winixd/functions/emacs.h | 4 + winixd/functions/functions.cpp | 2 +- winixd/functions/mkdir.cpp | 6 +- winixd/functions/rm.cpp | 22 +- winixd/functions/rm.h | 2 + winixd/functions/run.cpp | 5 + winixd/functions/tinymce.cpp | 4 +- winixd/functions/upload.cpp | 12 +- winixd/functions/upload.h | 2 + winixd/html/fun_run.html | 8 +- winixd/html/fun_tinymce.html | 1 - winixd/html/fun_upload.html | 5 +- winixd/main/Makefile.dep | 3 +- winixd/models/Makefile.dep | 18 +- winixd/models/itemcontent.cpp | 12 +- winixd/models/itemcontent.h | 5 + winixd/notify/Makefile.dep | 18 +- winixd/plugins/export/Makefile.dep | 6 +- winixd/plugins/group/Makefile.dep | 54 ++- winixd/plugins/menu/Makefile.dep | 43 +- winixd/plugins/stats/Makefile.dep | 18 +- winixd/plugins/thread/Makefile.dep | 12 +- winixd/plugins/ticket/Makefile.dep | 6 +- 42 files changed, 1085 insertions(+), 599 deletions(-) diff --git a/winixd/Makefile.dep b/winixd/Makefile.dep index 719b74f..a801c4c 100644 --- a/winixd/Makefile.dep +++ b/winixd/Makefile.dep @@ -1 +1 @@ -winix.src.files = ./core/app.h ./core/basethread.cpp ./core/acceptbaseparser.cpp ./core/acceptbaseparser.h ./core/acceptencodingparser.h ./core/basethread.h ./core/config.cpp ./core/config.h ./core/compress.cpp ./core/compress.h ./core/crypt.cpp ./core/dircontainer.cpp ./core/cookieparser.h ./core/request.cpp ./core/crypt.h ./core/cur.h ./core/winixmodeldeprecated.cpp ./core/app.cpp ./core/dircontainer.h ./core/dirs.cpp ./core/dirs.h ./core/error.h ./core/filelog.cpp ./core/filelog.h ./core/groups.cpp ./core/groups.h ./core/httpsimpleparser.cpp ./core/httpsimpleparser.h ./core/image.cpp ./core/image.h ./core/ipban.h ./core/ipbancontainer.cpp ./core/ipbancontainer.h ./core/job.cpp ./core/job.h ./core/lastcontainer.cpp ./core/lastcontainer.h ./core/loadavg.cpp ./core/loadavg.h ./core/lock.h ./core/lock.cpp ./core/log.cpp ./core/log.h ./core/logmanipulators.h ./core/misc.cpp ./core/misc.h ./core/mount.cpp ./core/mount.h ./core/mountparser.cpp ./core/mountparser.h ./core/mounts.cpp ./core/mounts.h ./core/plugin.cpp ./core/plugin.h ./core/plugindata.cpp ./core/plugindata.h ./core/pluginmsg.h ./core/postmultiparser.cpp ./core/postmultiparser.h ./core/postparser.h ./core/rebus.cpp ./core/rebus.h ./core/request.h ./core/requesttypes.h ./core/run.cpp ./core/run.h ./core/session.cpp ./core/session.h ./core/sessioncontainer.cpp ./core/sessioncontainer.h ./core/sessionidmanager.cpp ./core/sessionidmanager.h ./core/sessionmanager.cpp ./core/sessionmanager.h ./core/sessionparser.cpp ./core/sessionparser.h ./core/slog.cpp ./core/slog.h ./core/synchro.cpp ./core/synchro.h ./core/system.cpp ./core/system.h ./core/textstream.h ./core/threadmanager.cpp ./core/timezone.h ./core/threadmanager.h ./core/timezone.cpp ./core/timezones.cpp ./core/timezones.h ./core/ugcontainer.h ./core/users.cpp ./core/users.h ./core/version.h ./core/winix_const.h ./core/winixbase.cpp ./core/winixbase.h ./core/winixrequest.cpp ./core/winixrequest.h ./core/winixsystem.cpp ./core/winixsystem.h ./core/winixmodeldeprecated.h ./core/header.h ./db/db.cpp ./db/db.h ./db/dbbase.cpp ./db/dbbase.h ./db/dbconn.cpp ./db/dbconn.h ./db/dbtextstream.cpp ./db/dbtextstream.h ./functions/account.cpp ./functions/account.h ./functions/adduser.cpp ./functions/adduser.h ./functions/cat.cpp ./functions/cat.h ./functions/chmod.cpp ./functions/chmod.h ./functions/chown.cpp ./functions/chown.h ./functions/ckeditor.cpp ./functions/ckeditor.h ./functions/cp.cpp ./functions/cp.h ./functions/default.cpp ./functions/default.h ./functions/download.cpp ./functions/download.h ./functions/emacs.cpp ./functions/emacs.h ./functions/env.cpp ./functions/env.h ./functions/functionbase.cpp ./functions/functionbase.h ./functions/functionparser.cpp ./functions/functionparser.h ./functions/functions.cpp ./functions/functions.h ./functions/imgcrop.cpp ./functions/imgcrop.h ./functions/ipban.cpp ./functions/ipban.h ./functions/last.cpp ./functions/last.h ./functions/ln.cpp ./functions/ln.h ./functions/locale.cpp ./functions/locale.h ./functions/login.cpp ./functions/login.h ./functions/logout.cpp ./functions/logout.h ./functions/ls.cpp ./functions/ls.h ./functions/man.cpp ./functions/man.h ./functions/meta.cpp ./functions/meta.h ./functions/mkdir.cpp ./functions/mkdir.h ./functions/mount.cpp ./functions/mount.h ./functions/mv.cpp ./functions/mv.h ./functions/nicedit.cpp ./functions/nicedit.h ./functions/node.cpp ./functions/node.h ./functions/passwd.cpp ./functions/passwd.h ./functions/priv.cpp ./functions/priv.h ./functions/privchanger.cpp ./functions/privchanger.h ./functions/pw.cpp ./functions/pw.h ./functions/reload.cpp ./functions/reload.h ./functions/rm.cpp ./functions/rm.h ./functions/rmuser.cpp ./functions/rmuser.h ./functions/run.cpp ./functions/run.h ./functions/sort.cpp ./functions/sort.h ./functions/specialdefault.cpp ./functions/specialdefault.h ./functions/stat.cpp ./functions/stat.h ./functions/subject.cpp ./functions/subject.h ./functions/template.cpp ./functions/template.h ./functions/timezone.cpp ./functions/timezone.h ./functions/tinymce.cpp ./functions/tinymce.h ./functions/uname.cpp ./functions/uname.h ./functions/upload.cpp ./functions/upload.h ./functions/uptime.cpp ./functions/uptime.h ./functions/vim.cpp ./functions/vim.h ./functions/who.cpp ./functions/who.h ./main/main.cpp ./models/group.cpp ./models/group.h ./models/item.cpp ./models/item.h ./models/itemcontent.cpp ./models/itemcontent.h ./models/migration.cpp ./models/migration.h ./models/user.cpp ./models/user.h ./models/userwrapper.h ./models/winixmodel.cpp ./models/winixmodel.h ./models/winixmodelconnector.cpp ./models/winixmodelconnector.h ./notify/notify.cpp ./notify/notify.h ./notify/notifypool.cpp ./notify/notifypool.h ./notify/notifythread.cpp ./notify/notifythread.h ./notify/templatesnotify.cpp ./notify/templatesnotify.h ./plugins/export/edb.cpp ./plugins/export/edb.h ./plugins/export/export.h ./plugins/export/exportinfo.cpp ./plugins/export/exportinfo.h ./plugins/export/exportthread.cpp ./plugins/export/exportthread.h ./plugins/export/funexport.cpp ./plugins/export/funexport.h ./plugins/export/init.cpp ./plugins/export/message.h ./plugins/gallery/gallery.cpp ./plugins/gallery/gallery.h ./plugins/gallery/galleryinfo.cpp ./plugins/gallery/galleryinfo.h ./plugins/gallery/init.cpp ./plugins/gallery/templates.cpp ./plugins/group/groupinfo.cpp ./plugins/group/groupinfo.h ./plugins/group/groups.cpp ./plugins/group/groups.h ./plugins/group/init.cpp ./plugins/group/templates.cpp ./plugins/mailregister/funregistermail.cpp ./plugins/mailregister/funregistermail.h ./plugins/mailregister/funregistermail_showusers.cpp ./plugins/mailregister/funregistermail_showusers.h ./plugins/mailregister/init.cpp ./plugins/mailregister/mdb.cpp ./plugins/mailregister/mdb.h ./plugins/mailregister/registermail_info.cpp ./plugins/mailregister/registermail_info.h ./plugins/mailregister/templates.cpp ./plugins/menu/cache.cpp ./plugins/menu/cache.h ./plugins/menu/init.cpp ./plugins/menu/templates.cpp ./plugins/seo/init.cpp ./plugins/seo/seo.cpp ./plugins/seo/seo.h ./plugins/stats/bot.cpp ./plugins/stats/bot.h ./plugins/stats/init.cpp ./plugins/stats/stats.cpp ./plugins/stats/stats.h ./plugins/stats/statssession.h ./plugins/stats/templates.cpp ./plugins/stats/templates.h ./plugins/thread/createthread.cpp ./plugins/thread/createthread.h ./plugins/thread/funthread.cpp ./plugins/thread/funthread.h ./plugins/thread/init.cpp ./plugins/thread/pluginmsg.h ./plugins/thread/reply.cpp ./plugins/thread/reply.h ./plugins/thread/showthreads.cpp ./plugins/thread/showthreads.h ./plugins/thread/tdb.cpp ./plugins/thread/tdb.h ./plugins/thread/templates.cpp ./plugins/thread/templates.h ./plugins/thread/thread.cpp ./plugins/thread/thread.h ./plugins/thread/threadfiles.cpp ./plugins/thread/threadfiles.h ./plugins/thread/threadinfo.cpp ./plugins/thread/threadinfo.h ./plugins/ticket/createticket.cpp ./plugins/ticket/createticket.h ./plugins/ticket/editticket.cpp ./plugins/ticket/editticket.h ./plugins/ticket/funticket.cpp ./plugins/ticket/funticket.h ./plugins/ticket/init.cpp ./plugins/ticket/pluginmsg.h ./plugins/ticket/sessiondata.cpp ./plugins/ticket/sessiondata.h ./plugins/ticket/showtickets.cpp ./plugins/ticket/showtickets.h ./plugins/ticket/tdb.cpp ./plugins/ticket/tdb.h ./plugins/ticket/templates.cpp ./plugins/ticket/ticket.h ./plugins/ticket/ticketinfo.cpp ./plugins/ticket/ticketinfo.h ./templates/adduser.cpp ./templates/antispam.cpp ./templates/changepatterns.cpp ./templates/changepatterns.h ./templates/config.cpp ./templates/currentdate.cpp ./templates/dir.cpp ./templates/doc.cpp ./templates/filters.cpp ./templates/generic.cpp ./templates/htmltextstream.cpp ./templates/htmltextstream.h ./templates/indexpatterns.cpp ./templates/indexpatterns.h ./templates/insert.cpp ./templates/ipban.cpp ./templates/locale.cpp ./templates/last.cpp ./templates/misc.cpp ./templates/locale.h ./templates/localefilter.cpp ./templates/localefilter.h ./templates/login.cpp ./templates/ls.cpp ./templates/man.cpp ./templates/misc.h ./templates/patterns.h ./templates/mount.cpp ./templates/passwd.cpp ./templates/patterncacher.cpp ./templates/patterncacher.h ./templates/patterns.cpp ./templates/priv.cpp ./templates/templates.h ./templates/rebus.cpp ./templates/server.cpp ./templates/slog.cpp ./templates/stat.cpp ./templates/sys.cpp ./templates/template.cpp ./templates/templates.cpp ./templates/user.cpp ./templates/textextstream.cpp ./templates/textextstream.h ./templates/upload.cpp ./templates/uptime.cpp ./templates/who.cpp ./templates/winix.cpp ../../ezc/src/blocks.cpp ../../ezc/src/blocks.h ../../ezc/src/cache.cpp ../../ezc/src/cache.h ../../ezc/src/expressionparser.h ../../ezc/src/ezc.h ../../ezc/src/functions.h ../../ezc/src/generator.h ../../ezc/src/models.h ../../ezc/src/item.cpp ../../ezc/src/item.h ../../ezc/src/objects.h ../../ezc/src/outstreams.h ../../ezc/src/pattern.cpp ../../ezc/src/pattern.h ../../ezc/src/patternparser.cpp ../../ezc/src/patternparser.h ../../ezc/src/funinfo.h ../../ezc/src/models.cpp ../../tito/src/aes.cpp ../../tito/src/aes.h ../../tito/src/base32.cpp ../../tito/src/base32.h ../../tito/src/base64.cpp ../../tito/src/base64.h ../../tito/src/crypto.cpp ../../tito/src/crypto.h ../../tito/src/misc.cpp ../../tito/src/misc.h ../../pikotools/src/convert/convert.h ../../pikotools/src/convert/inttostr.cpp ../../pikotools/src/convert/inttostr.h ../../pikotools/src/convert/misc.cpp ../../pikotools/src/convert/misc.h ../../pikotools/src/convert/patternreplacer.h ../../pikotools/src/convert/strtoint.h ../../pikotools/src/convert/text.cpp ../../pikotools/src/convert/text.h ../../pikotools/src/convert/text_private.h ../../pikotools/src/convert/double.cpp ../../pikotools/src/convert/double.h ../../pikotools/src/convert/baseparser.h ../../pikotools/src/convert/baseparser.cpp ../../pikotools/src/date/date.cpp ../../pikotools/src/date/date.h ../../pikotools/src/log/filelog.cpp ../../pikotools/src/log/filelog.h ../../pikotools/src/log/log.cpp ../../pikotools/src/log/log.h ../../pikotools/src/membuffer/membuffer.h ../../pikotools/src/space/space.cpp ../../pikotools/src/space/space.h ../../pikotools/src/space/spaceparser.cpp ../../pikotools/src/space/spaceparser.h ../../pikotools/src/textstream/textstream.h ../../pikotools/src/textstream/types.h ../../pikotools/src/textstream/stream.h ../../pikotools/src/utf8/utf8.cpp ../../pikotools/src/utf8/utf8.h ../../pikotools/src/utf8/utf8_private.cpp ../../pikotools/src/utf8/utf8_private.h ../../pikotools/src/utf8/utf8_templates.h ../../pikotools/src/csv/csvparser.cpp ../../pikotools/src/csv/csvparser.h ../../pikotools/src/mainoptions/mainoptionsparser.cpp ../../pikotools/src/mainoptions/mainoptionsparser.h ../../pikotools/src/html/htmlparser.cpp ../../pikotools/src/html/htmlparser.h ../../pikotools/src/html/bbcodeparser.h ../../pikotools/src/html/bbcodeparser.cpp ../../morm/src/baseexpression.cpp ../../morm/src/baseexpression.h ../../morm/src/clearer.cpp ../../morm/src/clearer.h ../../morm/src/cursor.h ../../morm/src/cursorhelper.h ../../morm/src/dbconnector.cpp ../../morm/src/dbconnector.h ../../morm/src/dbexpression.cpp ../../morm/src/dbexpression.h ../../morm/src/fieldvaluehelper.h ../../morm/src/finder.h ../../morm/src/finderhelper.h ../../morm/src/flatconnector.cpp ../../morm/src/flatconnector.h ../../morm/src/flatexpression.cpp ../../morm/src/flatexpression.h ../../morm/src/jsonconnector.cpp ../../morm/src/jsonconnector.h ../../morm/src/jsonexpression.cpp ../../morm/src/jsonexpression.h ../../morm/src/model.cpp ../../morm/src/model.h ../../morm/src/modelconnector.cpp ../../morm/src/modelconnector.h ../../morm/src/modeldata.h ../../morm/src/modelenv.h ../../morm/src/morm.h ../../morm/src/morm_types.h ../../morm/src/outstream.h ../../morm/src/postgresqlconnector.cpp ../../morm/src/postgresqlconnector.h ../../morm/src/postgresqlexpression.cpp ../../morm/src/postgresqlexpression.h ../../morm/src/postgresqlqueryresult.cpp ../../morm/src/postgresqlqueryresult.h ../../morm/src/queryresult.cpp ../../morm/src/queryresult.h ../../morm/src/ft.h ../../morm/src/baseobjectwrapper.h ../../morm/src/modelcontainerwrapper.h ../../morm/src/spacewrapper.h ../../morm/src/wrapper.h \ No newline at end of file +winix.src.files = ./core/app.h ./core/basethread.cpp ./core/acceptbaseparser.cpp ./core/acceptbaseparser.h ./core/acceptencodingparser.h ./core/basethread.h ./core/config.cpp ./core/config.h ./core/compress.cpp ./core/compress.h ./core/crypt.cpp ./core/dircontainer.cpp ./core/cookieparser.h ./core/request.cpp ./core/crypt.h ./core/cur.h ./core/winixmodeldeprecated.cpp ./core/app.cpp ./core/dircontainer.h ./core/dirs.cpp ./core/dirs.h ./core/error.h ./core/filelog.cpp ./core/filelog.h ./core/groups.cpp ./core/groups.h ./core/httpsimpleparser.cpp ./core/httpsimpleparser.h ./core/image.cpp ./core/image.h ./core/ipban.h ./core/ipbancontainer.cpp ./core/ipbancontainer.h ./core/job.cpp ./core/job.h ./core/lastcontainer.cpp ./core/lastcontainer.h ./core/loadavg.cpp ./core/loadavg.h ./core/lock.h ./core/lock.cpp ./core/log.cpp ./core/log.h ./core/logmanipulators.h ./core/misc.cpp ./core/misc.h ./core/mount.cpp ./core/mount.h ./core/mountparser.cpp ./core/mountparser.h ./core/mounts.cpp ./core/mounts.h ./core/plugin.cpp ./core/plugin.h ./core/plugindata.cpp ./core/plugindata.h ./core/pluginmsg.h ./core/postmultiparser.cpp ./core/postmultiparser.h ./core/postparser.h ./core/rebus.cpp ./core/rebus.h ./core/request.h ./core/requesttypes.h ./core/run.cpp ./core/run.h ./core/session.cpp ./core/session.h ./core/sessioncontainer.cpp ./core/sessioncontainer.h ./core/sessionidmanager.cpp ./core/sessionidmanager.h ./core/sessionmanager.cpp ./core/sessionmanager.h ./core/sessionparser.cpp ./core/sessionparser.h ./core/slog.cpp ./core/slog.h ./core/synchro.cpp ./core/synchro.h ./core/system.cpp ./core/system.h ./core/textstream.h ./core/threadmanager.cpp ./core/timezone.h ./core/threadmanager.h ./core/timezone.cpp ./core/timezones.cpp ./core/timezones.h ./core/ugcontainer.h ./core/users.cpp ./core/users.h ./core/version.h ./core/winix_const.h ./core/winixbase.cpp ./core/winixbase.h ./core/winixrequest.cpp ./core/winixrequest.h ./core/winixsystem.cpp ./core/winixsystem.h ./core/winixmodeldeprecated.h ./core/header.h ./db/db.cpp ./db/db.h ./db/dbbase.cpp ./db/dbbase.h ./db/dbconn.cpp ./db/dbconn.h ./db/dbtextstream.cpp ./db/dbtextstream.h ./functions/account.cpp ./functions/account.h ./functions/adduser.cpp ./functions/adduser.h ./functions/cat.cpp ./functions/cat.h ./functions/chmod.cpp ./functions/chmod.h ./functions/chown.cpp ./functions/chown.h ./functions/ckeditor.cpp ./functions/ckeditor.h ./functions/cp.cpp ./functions/cp.h ./functions/default.cpp ./functions/default.h ./functions/download.cpp ./functions/download.h ./functions/emacs.cpp ./functions/emacs.h ./functions/env.cpp ./functions/env.h ./functions/functionbase.cpp ./functions/functionbase.h ./functions/functionparser.cpp ./functions/functionparser.h ./functions/functions.cpp ./functions/functions.h ./functions/imgcrop.cpp ./functions/imgcrop.h ./functions/ipban.cpp ./functions/ipban.h ./functions/last.cpp ./functions/last.h ./functions/ln.cpp ./functions/ln.h ./functions/locale.cpp ./functions/locale.h ./functions/login.cpp ./functions/login.h ./functions/logout.cpp ./functions/logout.h ./functions/ls.cpp ./functions/ls.h ./functions/man.cpp ./functions/man.h ./functions/meta.cpp ./functions/meta.h ./functions/mkdir.cpp ./functions/mkdir.h ./functions/mount.cpp ./functions/mount.h ./functions/mv.cpp ./functions/mv.h ./functions/nicedit.cpp ./functions/nicedit.h ./functions/node.cpp ./functions/node.h ./functions/passwd.cpp ./functions/passwd.h ./functions/priv.cpp ./functions/priv.h ./functions/privchanger.cpp ./functions/privchanger.h ./functions/pw.cpp ./functions/pw.h ./functions/reload.cpp ./functions/reload.h ./functions/rm.cpp ./functions/rm.h ./functions/rmuser.cpp ./functions/rmuser.h ./functions/run.cpp ./functions/run.h ./functions/sort.cpp ./functions/sort.h ./functions/specialdefault.cpp ./functions/specialdefault.h ./functions/stat.cpp ./functions/stat.h ./functions/subject.cpp ./functions/subject.h ./functions/template.cpp ./functions/template.h ./functions/timezone.cpp ./functions/timezone.h ./functions/tinymce.cpp ./functions/tinymce.h ./functions/uname.cpp ./functions/uname.h ./functions/upload.cpp ./functions/upload.h ./functions/uptime.cpp ./functions/uptime.h ./functions/vim.cpp ./functions/vim.h ./functions/who.cpp ./functions/who.h ./main/main.cpp ./models/group.cpp ./models/group.h ./models/item.cpp ./models/item.h ./models/itemcontent.cpp ./models/itemcontent.h ./models/migration.cpp ./models/migration.h ./models/user.cpp ./models/user.h ./models/userwrapper.h ./models/winixmodel.cpp ./models/winixmodel.h ./models/winixmodelconnector.cpp ./models/winixmodelconnector.h ./notify/notify.cpp ./notify/notify.h ./notify/notifypool.cpp ./notify/notifypool.h ./notify/notifythread.cpp ./notify/notifythread.h ./notify/templatesnotify.cpp ./notify/templatesnotify.h ./plugins/export/edb.cpp ./plugins/export/edb.h ./plugins/export/export.h ./plugins/export/exportinfo.cpp ./plugins/export/exportinfo.h ./plugins/export/exportthread.cpp ./plugins/export/exportthread.h ./plugins/export/funexport.cpp ./plugins/export/funexport.h ./plugins/export/init.cpp ./plugins/export/message.h ./plugins/gallery/gallery.cpp ./plugins/gallery/gallery.h ./plugins/gallery/galleryinfo.cpp ./plugins/gallery/galleryinfo.h ./plugins/gallery/init.cpp ./plugins/gallery/templates.cpp ./plugins/group/groupinfo.cpp ./plugins/group/groupinfo.h ./plugins/group/groups.cpp ./plugins/group/groups.h ./plugins/group/init.cpp ./plugins/group/templates.cpp ./plugins/mailregister/funregistermail.cpp ./plugins/mailregister/funregistermail.h ./plugins/mailregister/funregistermail_showusers.cpp ./plugins/mailregister/funregistermail_showusers.h ./plugins/mailregister/init.cpp ./plugins/mailregister/mdb.cpp ./plugins/mailregister/mdb.h ./plugins/mailregister/registermail_info.cpp ./plugins/mailregister/registermail_info.h ./plugins/mailregister/templates.cpp ./plugins/menu/cache.cpp ./plugins/menu/cache.h ./plugins/menu/init.cpp ./plugins/menu/templates.cpp ./plugins/seo/init.cpp ./plugins/seo/seo.cpp ./plugins/seo/seo.h ./plugins/stats/bot.cpp ./plugins/stats/bot.h ./plugins/stats/init.cpp ./plugins/stats/stats.cpp ./plugins/stats/stats.h ./plugins/stats/statssession.h ./plugins/stats/templates.cpp ./plugins/stats/templates.h ./plugins/thread/createthread.cpp ./plugins/thread/createthread.h ./plugins/thread/funthread.cpp ./plugins/thread/funthread.h ./plugins/thread/init.cpp ./plugins/thread/pluginmsg.h ./plugins/thread/reply.cpp ./plugins/thread/reply.h ./plugins/thread/showthreads.cpp ./plugins/thread/showthreads.h ./plugins/thread/tdb.cpp ./plugins/thread/tdb.h ./plugins/thread/templates.cpp ./plugins/thread/templates.h ./plugins/thread/thread.cpp ./plugins/thread/thread.h ./plugins/thread/threadfiles.cpp ./plugins/thread/threadfiles.h ./plugins/thread/threadinfo.cpp ./plugins/thread/threadinfo.h ./plugins/ticket/createticket.cpp ./plugins/ticket/createticket.h ./plugins/ticket/editticket.cpp ./plugins/ticket/editticket.h ./plugins/ticket/funticket.cpp ./plugins/ticket/funticket.h ./plugins/ticket/init.cpp ./plugins/ticket/pluginmsg.h ./plugins/ticket/sessiondata.cpp ./plugins/ticket/sessiondata.h ./plugins/ticket/showtickets.cpp ./plugins/ticket/showtickets.h ./plugins/ticket/tdb.cpp ./plugins/ticket/tdb.h ./plugins/ticket/templates.cpp ./plugins/ticket/ticket.h ./plugins/ticket/ticketinfo.cpp ./plugins/ticket/ticketinfo.h ./templates/adduser.cpp ./templates/antispam.cpp ./templates/changepatterns.cpp ./templates/changepatterns.h ./templates/config.cpp ./templates/currentdate.cpp ./templates/dir.cpp ./templates/doc.cpp ./templates/filters.cpp ./templates/generic.cpp ./templates/htmltextstream.cpp ./templates/htmltextstream.h ./templates/indexpatterns.cpp ./templates/indexpatterns.h ./templates/insert.cpp ./templates/ipban.cpp ./templates/locale.cpp ./templates/last.cpp ./templates/misc.cpp ./templates/locale.h ./templates/localefilter.cpp ./templates/localefilter.h ./templates/login.cpp ./templates/ls.cpp ./templates/man.cpp ./templates/misc.h ./templates/patterns.h ./templates/mount.cpp ./templates/passwd.cpp ./templates/patterncacher.cpp ./templates/patterncacher.h ./templates/patterns.cpp ./templates/priv.cpp ./templates/templates.h ./templates/rebus.cpp ./templates/server.cpp ./templates/slog.cpp ./templates/stat.cpp ./templates/sys.cpp ./templates/template.cpp ./templates/templates.cpp ./templates/user.cpp ./templates/textextstream.cpp ./templates/textextstream.h ./templates/upload.cpp ./templates/uptime.cpp ./templates/who.cpp ./templates/winix.cpp ../../ezc/src/blocks.cpp ../../ezc/src/blocks.h ../../ezc/src/cache.cpp ../../ezc/src/cache.h ../../ezc/src/expressionparser.h ../../ezc/src/ezc.h ../../ezc/src/functions.h ../../ezc/src/generator.h ../../ezc/src/models.h ../../ezc/src/item.cpp ../../ezc/src/item.h ../../ezc/src/objects.h ../../ezc/src/outstreams.h ../../ezc/src/pattern.cpp ../../ezc/src/pattern.h ../../ezc/src/patternparser.cpp ../../ezc/src/patternparser.h ../../ezc/src/funinfo.h ../../ezc/src/models.cpp ../../tito/src/aes.cpp ../../tito/src/aes.h ../../tito/src/base32.cpp ../../tito/src/base32.h ../../tito/src/base64.cpp ../../tito/src/base64.h ../../tito/src/crypto.cpp ../../tito/src/crypto.h ../../tito/src/misc.cpp ../../tito/src/misc.h ../../pikotools/src/convert/convert.h ../../pikotools/src/convert/inttostr.cpp ../../pikotools/src/convert/inttostr.h ../../pikotools/src/convert/misc.cpp ../../pikotools/src/convert/misc.h ../../pikotools/src/convert/patternreplacer.h ../../pikotools/src/convert/strtoint.h ../../pikotools/src/convert/text.cpp ../../pikotools/src/convert/text.h ../../pikotools/src/convert/text_private.h ../../pikotools/src/convert/double.cpp ../../pikotools/src/convert/double.h ../../pikotools/src/convert/baseparser.h ../../pikotools/src/convert/baseparser.cpp ../../pikotools/src/date/date.cpp ../../pikotools/src/date/date.h ../../pikotools/src/log/filelog.cpp ../../pikotools/src/log/filelog.h ../../pikotools/src/log/log.cpp ../../pikotools/src/log/log.h ../../pikotools/src/membuffer/membuffer.h ../../pikotools/src/space/space.cpp ../../pikotools/src/space/space.h ../../pikotools/src/space/spaceparser.cpp ../../pikotools/src/space/spaceparser.h ../../pikotools/src/textstream/textstream.h ../../pikotools/src/textstream/types.h ../../pikotools/src/textstream/stream.h ../../pikotools/src/utf8/utf8.cpp ../../pikotools/src/utf8/utf8.h ../../pikotools/src/utf8/utf8_private.cpp ../../pikotools/src/utf8/utf8_private.h ../../pikotools/src/utf8/utf8_templates.h ../../pikotools/src/utf8/utf8_stream.h ../../pikotools/src/csv/csvparser.cpp ../../pikotools/src/csv/csvparser.h ../../pikotools/src/mainoptions/mainoptionsparser.cpp ../../pikotools/src/mainoptions/mainoptionsparser.h ../../pikotools/src/html/htmlparser.cpp ../../pikotools/src/html/htmlparser.h ../../pikotools/src/html/bbcodeparser.h ../../pikotools/src/html/bbcodeparser.cpp ../../morm/src/baseexpression.cpp ../../morm/src/baseexpression.h ../../morm/src/clearer.cpp ../../morm/src/clearer.h ../../morm/src/cursor.h ../../morm/src/cursorhelper.h ../../morm/src/dbconnector.cpp ../../morm/src/dbconnector.h ../../morm/src/dbexpression.cpp ../../morm/src/dbexpression.h ../../morm/src/fieldvaluehelper.h ../../morm/src/finder.h ../../morm/src/finderhelper.h ../../morm/src/flatconnector.cpp ../../morm/src/flatconnector.h ../../morm/src/flatexpression.cpp ../../morm/src/flatexpression.h ../../morm/src/jsonconnector.cpp ../../morm/src/jsonconnector.h ../../morm/src/jsonexpression.cpp ../../morm/src/jsonexpression.h ../../morm/src/model.cpp ../../morm/src/model.h ../../morm/src/modelconnector.cpp ../../morm/src/modelconnector.h ../../morm/src/modeldata.h ../../morm/src/modelenv.h ../../morm/src/morm.h ../../morm/src/morm_types.h ../../morm/src/outstream.h ../../morm/src/postgresqlconnector.cpp ../../morm/src/postgresqlconnector.h ../../morm/src/postgresqlexpression.cpp ../../morm/src/postgresqlexpression.h ../../morm/src/postgresqlqueryresult.cpp ../../morm/src/postgresqlqueryresult.h ../../morm/src/queryresult.cpp ../../morm/src/queryresult.h ../../morm/src/ft.h ../../morm/src/baseobjectwrapper.h ../../morm/src/modelcontainerwrapper.h ../../morm/src/spacewrapper.h ../../morm/src/wrapper.h \ No newline at end of file diff --git a/winixd/core/Makefile.dep b/winixd/core/Makefile.dep index 2acc07e..9de095c 100644 --- a/winixd/core/Makefile.dep +++ b/winixd/core/Makefile.dep @@ -10,15 +10,15 @@ acceptbaseparser.o: ../../../pikotools/src/utf8/utf8.h acceptbaseparser.o: ../../../pikotools/src/textstream/stream.h acceptbaseparser.o: ../../../pikotools/src/utf8/utf8_templates.h acceptbaseparser.o: ../../../pikotools/src/utf8/utf8_private.h -acceptbaseparser.o: ../../../pikotools/src/convert/baseparser.h log.h -acceptbaseparser.o: logmanipulators.h ../../../pikotools/src/log/log.h +acceptbaseparser.o: ../../../pikotools/src/convert/baseparser.h acceptbaseparser.o: ../../../pikotools/src/textstream/textstream.h acceptbaseparser.o: ../../../pikotools/src/textstream/stream.h acceptbaseparser.o: ../../../pikotools/src/space/space.h acceptbaseparser.o: ../../../pikotools/src/date/date.h acceptbaseparser.o: ../../../pikotools/src/membuffer/membuffer.h -acceptbaseparser.o: ../../../pikotools/src/textstream/types.h filelog.h -acceptbaseparser.o: ../../../winix/winixd/core/synchro.h +acceptbaseparser.o: ../../../pikotools/src/textstream/types.h log.h +acceptbaseparser.o: logmanipulators.h ../../../pikotools/src/log/log.h +acceptbaseparser.o: filelog.h ../../../winix/winixd/core/synchro.h acceptbaseparser.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h acceptbaseparser.o: ../../../morm/src/model.h acceptbaseparser.o: ../../../morm/src/modelconnector.h @@ -212,14 +212,14 @@ basethread.o: ../../../pikotools/src/utf8/utf8.h basethread.o: ../../../pikotools/src/textstream/stream.h basethread.o: ../../../pikotools/src/utf8/utf8_templates.h basethread.o: ../../../pikotools/src/utf8/utf8_private.h -basethread.o: ../../../pikotools/src/convert/baseparser.h log.h -basethread.o: logmanipulators.h ../../../pikotools/src/log/log.h +basethread.o: ../../../pikotools/src/convert/baseparser.h basethread.o: ../../../pikotools/src/textstream/textstream.h basethread.o: ../../../pikotools/src/textstream/stream.h basethread.o: ../../../pikotools/src/space/space.h basethread.o: ../../../pikotools/src/date/date.h basethread.o: ../../../pikotools/src/membuffer/membuffer.h -basethread.o: ../../../pikotools/src/textstream/types.h filelog.h +basethread.o: ../../../pikotools/src/textstream/types.h log.h +basethread.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h basethread.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h basethread.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h basethread.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -352,14 +352,14 @@ crypt.o: ../../../pikotools/src/utf8/utf8.h crypt.o: ../../../pikotools/src/textstream/stream.h crypt.o: ../../../pikotools/src/utf8/utf8_templates.h crypt.o: ../../../pikotools/src/utf8/utf8_private.h -crypt.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -crypt.o: ../../../pikotools/src/log/log.h +crypt.o: ../../../pikotools/src/convert/baseparser.h crypt.o: ../../../pikotools/src/textstream/textstream.h crypt.o: ../../../pikotools/src/textstream/stream.h crypt.o: ../../../pikotools/src/space/space.h crypt.o: ../../../pikotools/src/date/date.h crypt.o: ../../../pikotools/src/membuffer/membuffer.h -crypt.o: ../../../pikotools/src/textstream/types.h filelog.h +crypt.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +crypt.o: ../../../pikotools/src/log/log.h filelog.h crypt.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h crypt.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h crypt.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -412,14 +412,14 @@ dircontainer.o: ../../../pikotools/src/utf8/utf8.h dircontainer.o: ../../../pikotools/src/textstream/stream.h dircontainer.o: ../../../pikotools/src/utf8/utf8_templates.h dircontainer.o: ../../../pikotools/src/utf8/utf8_private.h -dircontainer.o: ../../../pikotools/src/convert/baseparser.h log.h -dircontainer.o: logmanipulators.h ../../../pikotools/src/log/log.h +dircontainer.o: ../../../pikotools/src/convert/baseparser.h dircontainer.o: ../../../pikotools/src/textstream/textstream.h dircontainer.o: ../../../pikotools/src/textstream/stream.h dircontainer.o: ../../../pikotools/src/space/space.h dircontainer.o: ../../../pikotools/src/date/date.h dircontainer.o: ../../../pikotools/src/membuffer/membuffer.h -dircontainer.o: ../../../pikotools/src/textstream/types.h filelog.h +dircontainer.o: ../../../pikotools/src/textstream/types.h log.h +dircontainer.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h dircontainer.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h dircontainer.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h dircontainer.o: ../../../morm/src/modelconnector.h @@ -477,14 +477,14 @@ dirs.o: ../../../pikotools/src/utf8/utf8.h dirs.o: ../../../pikotools/src/textstream/stream.h dirs.o: ../../../pikotools/src/utf8/utf8_templates.h dirs.o: ../../../pikotools/src/utf8/utf8_private.h -dirs.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -dirs.o: ../../../pikotools/src/log/log.h +dirs.o: ../../../pikotools/src/convert/baseparser.h dirs.o: ../../../pikotools/src/textstream/textstream.h dirs.o: ../../../pikotools/src/textstream/stream.h dirs.o: ../../../pikotools/src/space/space.h dirs.o: ../../../pikotools/src/date/date.h dirs.o: ../../../pikotools/src/membuffer/membuffer.h -dirs.o: ../../../pikotools/src/textstream/types.h filelog.h +dirs.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +dirs.o: ../../../pikotools/src/log/log.h filelog.h dirs.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h dirs.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h dirs.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -667,15 +667,15 @@ httpsimpleparser.o: ../../../pikotools/src/utf8/utf8.h httpsimpleparser.o: ../../../pikotools/src/textstream/stream.h httpsimpleparser.o: ../../../pikotools/src/utf8/utf8_templates.h httpsimpleparser.o: ../../../pikotools/src/utf8/utf8_private.h -httpsimpleparser.o: ../../../pikotools/src/convert/baseparser.h log.h -httpsimpleparser.o: logmanipulators.h ../../../pikotools/src/log/log.h +httpsimpleparser.o: ../../../pikotools/src/convert/baseparser.h httpsimpleparser.o: ../../../pikotools/src/textstream/textstream.h httpsimpleparser.o: ../../../pikotools/src/textstream/stream.h httpsimpleparser.o: ../../../pikotools/src/space/space.h httpsimpleparser.o: ../../../pikotools/src/date/date.h httpsimpleparser.o: ../../../pikotools/src/membuffer/membuffer.h -httpsimpleparser.o: ../../../pikotools/src/textstream/types.h filelog.h -httpsimpleparser.o: ../../../winix/winixd/core/synchro.h +httpsimpleparser.o: ../../../pikotools/src/textstream/types.h log.h +httpsimpleparser.o: logmanipulators.h ../../../pikotools/src/log/log.h +httpsimpleparser.o: filelog.h ../../../winix/winixd/core/synchro.h httpsimpleparser.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h httpsimpleparser.o: ../../../morm/src/model.h httpsimpleparser.o: ../../../morm/src/modelconnector.h @@ -723,14 +723,14 @@ image.o: ../../../pikotools/src/utf8/utf8.h image.o: ../../../pikotools/src/textstream/stream.h image.o: ../../../pikotools/src/utf8/utf8_templates.h image.o: ../../../pikotools/src/utf8/utf8_private.h -image.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -image.o: ../../../pikotools/src/log/log.h +image.o: ../../../pikotools/src/convert/baseparser.h image.o: ../../../pikotools/src/textstream/textstream.h image.o: ../../../pikotools/src/textstream/stream.h image.o: ../../../pikotools/src/space/space.h image.o: ../../../pikotools/src/date/date.h image.o: ../../../pikotools/src/membuffer/membuffer.h -image.o: ../../../pikotools/src/textstream/types.h filelog.h +image.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +image.o: ../../../pikotools/src/log/log.h filelog.h image.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h image.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h image.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -810,15 +810,15 @@ ipbancontainer.o: ../../../pikotools/src/utf8/utf8.h ipbancontainer.o: ../../../pikotools/src/textstream/stream.h ipbancontainer.o: ../../../pikotools/src/utf8/utf8_templates.h ipbancontainer.o: ../../../pikotools/src/utf8/utf8_private.h -ipbancontainer.o: ../../../pikotools/src/convert/baseparser.h log.h -ipbancontainer.o: logmanipulators.h ../../../pikotools/src/log/log.h +ipbancontainer.o: ../../../pikotools/src/convert/baseparser.h ipbancontainer.o: ../../../pikotools/src/textstream/textstream.h ipbancontainer.o: ../../../pikotools/src/textstream/stream.h ipbancontainer.o: ../../../pikotools/src/space/space.h ipbancontainer.o: ../../../pikotools/src/date/date.h ipbancontainer.o: ../../../pikotools/src/membuffer/membuffer.h -ipbancontainer.o: ../../../pikotools/src/textstream/types.h filelog.h -ipbancontainer.o: ../../../winix/winixd/core/synchro.h +ipbancontainer.o: ../../../pikotools/src/textstream/types.h log.h +ipbancontainer.o: logmanipulators.h ../../../pikotools/src/log/log.h +ipbancontainer.o: filelog.h ../../../winix/winixd/core/synchro.h ipbancontainer.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h ipbancontainer.o: ../../../morm/src/model.h ipbancontainer.o: ../../../morm/src/modelconnector.h @@ -857,14 +857,14 @@ job.o: ../../../pikotools/src/utf8/utf8.h job.o: ../../../pikotools/src/textstream/stream.h job.o: ../../../pikotools/src/utf8/utf8_templates.h job.o: ../../../pikotools/src/utf8/utf8_private.h -job.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -job.o: ../../../pikotools/src/log/log.h +job.o: ../../../pikotools/src/convert/baseparser.h job.o: ../../../pikotools/src/textstream/textstream.h job.o: ../../../pikotools/src/textstream/stream.h job.o: ../../../pikotools/src/space/space.h job.o: ../../../pikotools/src/date/date.h job.o: ../../../pikotools/src/membuffer/membuffer.h -job.o: ../../../pikotools/src/textstream/types.h filelog.h +job.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +job.o: ../../../pikotools/src/log/log.h filelog.h job.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h job.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h job.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -895,13 +895,13 @@ lastcontainer.o: ../../../pikotools/src/utf8/utf8.h lastcontainer.o: ../../../pikotools/src/textstream/stream.h lastcontainer.o: ../../../pikotools/src/utf8/utf8_templates.h lastcontainer.o: ../../../pikotools/src/utf8/utf8_private.h -lastcontainer.o: ../../../pikotools/src/convert/baseparser.h log.h -lastcontainer.o: logmanipulators.h ../../../pikotools/src/log/log.h +lastcontainer.o: ../../../pikotools/src/convert/baseparser.h lastcontainer.o: ../../../pikotools/src/textstream/textstream.h lastcontainer.o: ../../../pikotools/src/textstream/stream.h lastcontainer.o: ../../../pikotools/src/space/space.h lastcontainer.o: ../../../pikotools/src/membuffer/membuffer.h -lastcontainer.o: ../../../pikotools/src/textstream/types.h filelog.h +lastcontainer.o: ../../../pikotools/src/textstream/types.h log.h +lastcontainer.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h lastcontainer.o: ../../../winix/winixd/core/synchro.h lastcontainer.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h lastcontainer.o: ../../../morm/src/model.h ../../../morm/src/modelconnector.h @@ -943,14 +943,14 @@ loadavg.o: ../../../pikotools/src/utf8/utf8.h loadavg.o: ../../../pikotools/src/textstream/stream.h loadavg.o: ../../../pikotools/src/utf8/utf8_templates.h loadavg.o: ../../../pikotools/src/utf8/utf8_private.h -loadavg.o: ../../../pikotools/src/convert/baseparser.h log.h -loadavg.o: logmanipulators.h ../../../pikotools/src/log/log.h +loadavg.o: ../../../pikotools/src/convert/baseparser.h loadavg.o: ../../../pikotools/src/textstream/textstream.h loadavg.o: ../../../pikotools/src/textstream/stream.h loadavg.o: ../../../pikotools/src/space/space.h loadavg.o: ../../../pikotools/src/date/date.h loadavg.o: ../../../pikotools/src/membuffer/membuffer.h -loadavg.o: ../../../pikotools/src/textstream/types.h filelog.h +loadavg.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +loadavg.o: ../../../pikotools/src/log/log.h filelog.h loadavg.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h loadavg.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h loadavg.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -1138,14 +1138,14 @@ mountparser.o: ../../../pikotools/src/utf8/utf8.h mountparser.o: ../../../pikotools/src/textstream/stream.h mountparser.o: ../../../pikotools/src/utf8/utf8_templates.h mountparser.o: ../../../pikotools/src/utf8/utf8_private.h -mountparser.o: ../../../pikotools/src/convert/baseparser.h log.h -mountparser.o: logmanipulators.h ../../../pikotools/src/log/log.h +mountparser.o: ../../../pikotools/src/convert/baseparser.h mountparser.o: ../../../pikotools/src/textstream/textstream.h mountparser.o: ../../../pikotools/src/textstream/stream.h mountparser.o: ../../../pikotools/src/space/space.h mountparser.o: ../../../pikotools/src/date/date.h mountparser.o: ../../../pikotools/src/membuffer/membuffer.h -mountparser.o: ../../../pikotools/src/textstream/types.h filelog.h +mountparser.o: ../../../pikotools/src/textstream/types.h log.h +mountparser.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h mountparser.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h mountparser.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h mountparser.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -1217,14 +1217,14 @@ mounts.o: ../../../pikotools/src/utf8/utf8.h mounts.o: ../../../pikotools/src/textstream/stream.h mounts.o: ../../../pikotools/src/utf8/utf8_templates.h mounts.o: ../../../pikotools/src/utf8/utf8_private.h -mounts.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -mounts.o: ../../../pikotools/src/log/log.h +mounts.o: ../../../pikotools/src/convert/baseparser.h mounts.o: ../../../pikotools/src/textstream/textstream.h mounts.o: ../../../pikotools/src/textstream/stream.h mounts.o: ../../../pikotools/src/space/space.h mounts.o: ../../../pikotools/src/date/date.h mounts.o: ../../../pikotools/src/membuffer/membuffer.h -mounts.o: ../../../pikotools/src/textstream/types.h filelog.h +mounts.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +mounts.o: ../../../pikotools/src/log/log.h filelog.h mounts.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h mounts.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h mounts.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -1291,14 +1291,14 @@ plugin.o: ../../../pikotools/src/utf8/utf8.h plugin.o: ../../../pikotools/src/textstream/stream.h plugin.o: ../../../pikotools/src/utf8/utf8_templates.h plugin.o: ../../../pikotools/src/utf8/utf8_private.h -plugin.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -plugin.o: ../../../pikotools/src/log/log.h +plugin.o: ../../../pikotools/src/convert/baseparser.h plugin.o: ../../../pikotools/src/textstream/textstream.h plugin.o: ../../../pikotools/src/textstream/stream.h plugin.o: ../../../pikotools/src/space/space.h plugin.o: ../../../pikotools/src/date/date.h plugin.o: ../../../pikotools/src/membuffer/membuffer.h -plugin.o: ../../../pikotools/src/textstream/types.h filelog.h +plugin.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +plugin.o: ../../../pikotools/src/log/log.h filelog.h plugin.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h plugin.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h plugin.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -1439,14 +1439,14 @@ plugindata.o: ../../../pikotools/src/utf8/utf8.h plugindata.o: ../../../pikotools/src/textstream/stream.h plugindata.o: ../../../pikotools/src/utf8/utf8_templates.h plugindata.o: ../../../pikotools/src/utf8/utf8_private.h -plugindata.o: ../../../pikotools/src/convert/baseparser.h log.h -plugindata.o: logmanipulators.h ../../../pikotools/src/log/log.h +plugindata.o: ../../../pikotools/src/convert/baseparser.h plugindata.o: ../../../pikotools/src/textstream/textstream.h plugindata.o: ../../../pikotools/src/textstream/stream.h plugindata.o: ../../../pikotools/src/space/space.h plugindata.o: ../../../pikotools/src/date/date.h plugindata.o: ../../../pikotools/src/membuffer/membuffer.h -plugindata.o: ../../../pikotools/src/textstream/types.h filelog.h +plugindata.o: ../../../pikotools/src/textstream/types.h log.h +plugindata.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h plugindata.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h plugindata.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h plugindata.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -1688,14 +1688,14 @@ run.o: ../../../pikotools/src/utf8/utf8.h run.o: ../../../pikotools/src/textstream/stream.h run.o: ../../../pikotools/src/utf8/utf8_templates.h run.o: ../../../pikotools/src/utf8/utf8_private.h -run.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -run.o: ../../../pikotools/src/log/log.h +run.o: ../../../pikotools/src/convert/baseparser.h run.o: ../../../pikotools/src/textstream/textstream.h run.o: ../../../pikotools/src/textstream/stream.h run.o: ../../../pikotools/src/space/space.h run.o: ../../../pikotools/src/date/date.h run.o: ../../../pikotools/src/membuffer/membuffer.h -run.o: ../../../pikotools/src/textstream/types.h filelog.h +run.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +run.o: ../../../pikotools/src/log/log.h filelog.h run.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h run.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h run.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -1867,14 +1867,14 @@ sessionidmanager.o: ../../../pikotools/src/utf8/utf8.h sessionidmanager.o: ../../../pikotools/src/textstream/stream.h sessionidmanager.o: ../../../pikotools/src/utf8/utf8_templates.h sessionidmanager.o: ../../../pikotools/src/utf8/utf8_private.h -sessionidmanager.o: ../../../pikotools/src/convert/baseparser.h log.h -sessionidmanager.o: logmanipulators.h ../../../pikotools/src/log/log.h +sessionidmanager.o: ../../../pikotools/src/convert/baseparser.h sessionidmanager.o: ../../../pikotools/src/textstream/textstream.h sessionidmanager.o: ../../../pikotools/src/textstream/stream.h sessionidmanager.o: ../../../pikotools/src/date/date.h sessionidmanager.o: ../../../pikotools/src/membuffer/membuffer.h -sessionidmanager.o: ../../../pikotools/src/textstream/types.h filelog.h -sessionidmanager.o: ../../../winix/winixd/core/synchro.h +sessionidmanager.o: ../../../pikotools/src/textstream/types.h log.h +sessionidmanager.o: logmanipulators.h ../../../pikotools/src/log/log.h +sessionidmanager.o: filelog.h ../../../winix/winixd/core/synchro.h sessionidmanager.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h sessionidmanager.o: ../../../morm/src/model.h sessionidmanager.o: ../../../morm/src/modelconnector.h @@ -2176,14 +2176,14 @@ system.o: ../../../pikotools/src/utf8/utf8.h system.o: ../../../pikotools/src/textstream/stream.h system.o: ../../../pikotools/src/utf8/utf8_templates.h system.o: ../../../pikotools/src/utf8/utf8_private.h -system.o: ../../../pikotools/src/convert/baseparser.h log.h logmanipulators.h -system.o: ../../../pikotools/src/log/log.h +system.o: ../../../pikotools/src/convert/baseparser.h system.o: ../../../pikotools/src/textstream/textstream.h system.o: ../../../pikotools/src/textstream/stream.h system.o: ../../../pikotools/src/space/space.h system.o: ../../../pikotools/src/date/date.h system.o: ../../../pikotools/src/membuffer/membuffer.h -system.o: ../../../pikotools/src/textstream/types.h filelog.h +system.o: ../../../pikotools/src/textstream/types.h log.h logmanipulators.h +system.o: ../../../pikotools/src/log/log.h filelog.h system.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h system.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h system.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -2322,14 +2322,14 @@ threadmanager.o: ../../../pikotools/src/utf8/utf8.h threadmanager.o: ../../../pikotools/src/textstream/stream.h threadmanager.o: ../../../pikotools/src/utf8/utf8_templates.h threadmanager.o: ../../../pikotools/src/utf8/utf8_private.h -threadmanager.o: ../../../pikotools/src/convert/baseparser.h log.h -threadmanager.o: logmanipulators.h ../../../pikotools/src/log/log.h +threadmanager.o: ../../../pikotools/src/convert/baseparser.h threadmanager.o: ../../../pikotools/src/textstream/textstream.h threadmanager.o: ../../../pikotools/src/textstream/stream.h threadmanager.o: ../../../pikotools/src/space/space.h threadmanager.o: ../../../pikotools/src/date/date.h threadmanager.o: ../../../pikotools/src/membuffer/membuffer.h -threadmanager.o: ../../../pikotools/src/textstream/types.h filelog.h +threadmanager.o: ../../../pikotools/src/textstream/types.h log.h +threadmanager.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h threadmanager.o: ../../../winix/winixd/core/synchro.h threadmanager.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h threadmanager.o: ../../../morm/src/model.h ../../../morm/src/modelconnector.h @@ -2384,13 +2384,13 @@ timezones.o: ../../../pikotools/src/utf8/utf8.h timezones.o: ../../../pikotools/src/textstream/stream.h timezones.o: ../../../pikotools/src/utf8/utf8_templates.h timezones.o: ../../../pikotools/src/utf8/utf8_private.h -timezones.o: ../../../pikotools/src/convert/baseparser.h winixbase.h -timezones.o: ../../../winix/winixd/core/config.h log.h logmanipulators.h -timezones.o: ../../../pikotools/src/log/log.h +timezones.o: ../../../pikotools/src/convert/baseparser.h timezones.o: ../../../pikotools/src/textstream/textstream.h timezones.o: ../../../pikotools/src/textstream/stream.h timezones.o: ../../../pikotools/src/membuffer/membuffer.h -timezones.o: ../../../pikotools/src/textstream/types.h filelog.h +timezones.o: ../../../pikotools/src/textstream/types.h winixbase.h +timezones.o: ../../../winix/winixd/core/config.h log.h logmanipulators.h +timezones.o: ../../../pikotools/src/log/log.h filelog.h timezones.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h timezones.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h timezones.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -2518,14 +2518,14 @@ winixbase.o: ../../../pikotools/src/utf8/utf8.h winixbase.o: ../../../pikotools/src/textstream/stream.h winixbase.o: ../../../pikotools/src/utf8/utf8_templates.h winixbase.o: ../../../pikotools/src/utf8/utf8_private.h -winixbase.o: ../../../pikotools/src/convert/baseparser.h log.h -winixbase.o: logmanipulators.h ../../../pikotools/src/log/log.h +winixbase.o: ../../../pikotools/src/convert/baseparser.h winixbase.o: ../../../pikotools/src/textstream/textstream.h winixbase.o: ../../../pikotools/src/textstream/stream.h winixbase.o: ../../../pikotools/src/space/space.h winixbase.o: ../../../pikotools/src/date/date.h winixbase.o: ../../../pikotools/src/membuffer/membuffer.h -winixbase.o: ../../../pikotools/src/textstream/types.h filelog.h +winixbase.o: ../../../pikotools/src/textstream/types.h log.h +winixbase.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h winixbase.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h winixbase.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h winixbase.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -2559,15 +2559,15 @@ winixmodeldeprecated.o: ../../../pikotools/src/utf8/utf8.h winixmodeldeprecated.o: ../../../pikotools/src/textstream/stream.h winixmodeldeprecated.o: ../../../pikotools/src/utf8/utf8_templates.h winixmodeldeprecated.o: ../../../pikotools/src/utf8/utf8_private.h -winixmodeldeprecated.o: ../../../pikotools/src/convert/baseparser.h log.h -winixmodeldeprecated.o: logmanipulators.h ../../../pikotools/src/log/log.h +winixmodeldeprecated.o: ../../../pikotools/src/convert/baseparser.h winixmodeldeprecated.o: ../../../pikotools/src/textstream/textstream.h winixmodeldeprecated.o: ../../../pikotools/src/textstream/stream.h winixmodeldeprecated.o: ../../../pikotools/src/space/space.h winixmodeldeprecated.o: ../../../pikotools/src/date/date.h winixmodeldeprecated.o: ../../../pikotools/src/membuffer/membuffer.h -winixmodeldeprecated.o: ../../../pikotools/src/textstream/types.h filelog.h -winixmodeldeprecated.o: ../../../winix/winixd/core/synchro.h +winixmodeldeprecated.o: ../../../pikotools/src/textstream/types.h log.h +winixmodeldeprecated.o: logmanipulators.h ../../../pikotools/src/log/log.h +winixmodeldeprecated.o: filelog.h ../../../winix/winixd/core/synchro.h winixmodeldeprecated.o: ../../../morm/src/morm.h winixmodeldeprecated.o: ../../../morm/src/morm_types.h winixmodeldeprecated.o: ../../../morm/src/model.h @@ -2611,14 +2611,14 @@ winixsystem.o: ../../../pikotools/src/utf8/utf8.h winixsystem.o: ../../../pikotools/src/textstream/stream.h winixsystem.o: ../../../pikotools/src/utf8/utf8_templates.h winixsystem.o: ../../../pikotools/src/utf8/utf8_private.h -winixsystem.o: ../../../pikotools/src/convert/baseparser.h log.h -winixsystem.o: logmanipulators.h ../../../pikotools/src/log/log.h +winixsystem.o: ../../../pikotools/src/convert/baseparser.h winixsystem.o: ../../../pikotools/src/textstream/textstream.h winixsystem.o: ../../../pikotools/src/textstream/stream.h winixsystem.o: ../../../pikotools/src/space/space.h winixsystem.o: ../../../pikotools/src/date/date.h winixsystem.o: ../../../pikotools/src/membuffer/membuffer.h -winixsystem.o: ../../../pikotools/src/textstream/types.h filelog.h +winixsystem.o: ../../../pikotools/src/textstream/types.h log.h +winixsystem.o: logmanipulators.h ../../../pikotools/src/log/log.h filelog.h winixsystem.o: ../../../winix/winixd/core/synchro.h ../../../morm/src/morm.h winixsystem.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h winixsystem.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h diff --git a/winixd/core/app.cpp b/winixd/core/app.cpp index 5e1ee3f..1c2e098 100644 --- a/winixd/core/app.cpp +++ b/winixd/core/app.cpp @@ -711,8 +711,9 @@ void App::ClearAfterRequest() cur.session->ClearAfterRequest(); cur.session = session_manager.GetTmpSession(); output_8bit.clear(); + output_8bit2.clear(); compressed_output.clear(); - html_filtered.clear(); + //html_filtered.clear(); aheader_name.clear(); aheader_value.clear(); cur.mount = system.mounts.GetEmptyMount(); @@ -775,77 +776,11 @@ void App::SaveSessionsIfNeeded() } - -pt::WTextStream * App::CreateFrameAnswer() -{ - Request & req = *cur.request; - auto i = req.out_streams.streams_map.begin(); - const std::wstring * frame = cur.request->ParamValuep(config.request_frame_parameter); - - if( frame ) - { - for( ; i != req.out_streams.streams_map.end() ; ++i) - { - if( i->first == *frame ) - { - return &i->second->get_buffer(); - } - } - } - - return nullptr; -} - - -pt::WTextStream * App::CreateJSONAnswer() -{ - Request & req = *cur.request; - json_out_stream.clear(); - - if( !req.return_info_only ) - { - json_out_stream << L"{\n\"frames\": {\n"; - - auto i = req.out_streams.streams_map.begin(); - bool is_first = true; - - for( ; i != req.out_streams.streams_map.end() ; ++i) - { - if( !is_first ) - { - json_out_stream << L",\n"; - } - - json_out_stream << L"\""; - JSONescape(i->first, json_out_stream); - json_out_stream << L"\": \""; - JSONescapeStream(i->second->get_buffer(), json_out_stream); - json_out_stream << L"\""; - is_first = false; - } - - json_out_stream << L"}\n,\n\"info\": "; - } - - req.info.serialize_to_json_stream(json_out_stream, false); - log << log3 << "App: sending JSON answer"; - - if( !req.return_info_only ) - json_out_stream << L"}\n"; - else - log << " (Request::info only)"; - - log << logend; - - return &json_out_stream; -} - - // !! IMPROVE ME change to a better name -void App::MakePage() +void App::MakeEzcGenerator() { - if( cur.request->page_generated || !cur.request->redirect_to.empty() || !cur.request->x_sendfile.empty() ) - return; +// if( cur.request->page_generated || !cur.request->redirect_to.empty() || !cur.request->x_sendfile.empty() ) +// return; clock_gettime(CLOCK_REALTIME, &cur.request->timespec_ezc_engine_start); @@ -888,10 +823,12 @@ void App::CheckPostRedirect() void App::AddDefaultModels() { - if( !cur.request->send_bin_stream && !cur.request->return_json ) + // there is no need to add default models if we return a binary stream + if( cur.request->answer_source != Request::AnswerSource::answer_bin_stream ) { if( cur.request->function && cur.request->function->register_default_models ) { + // may it would be better do not return cur.request by default? cur.request->models.Add(L"request", cur.request); if( cur.session && cur.session->puser ) @@ -920,8 +857,8 @@ void App::Make() return; } - if( cur.request->ParamValue(L"reqtype") == L"json" ) - cur.request->return_json = true; + if( !cur.request->PrepareAnswerType() ) + return; if( cur.session->ip_ban && cur.session->ip_ban->IsIPBanned() ) { @@ -973,9 +910,6 @@ void App::Make() log << log1 << "App: there is no a root dir (dir_tab is empty -- after calling a function)" << logend; return; } - - plugin.Call(WINIX_CONTENT_MAKE); - MakePage(); } @@ -1316,9 +1250,9 @@ void App::ReadPostVars() post_multi_parser.Parse(fcgi_request.in, cur.request->post_tab, cur.request->post_file_tab); } else - if( pt::is_substr_nc(L"application/json", cur.request->env_content_type.c_str()) ) + if( pt::is_substr_nc(Winix::Header::application_json, cur.request->env_content_type.c_str()) ) { - log << log3 << "App: post content type: application/json" << logend; + log << log3 << "App: post content type: " << Winix::Header::application_json << logend; ReadPostJson(); } else @@ -1498,27 +1432,42 @@ void App::PrepareHeaderContentType() { if( !cur.request->out_headers.has_key(Winix::Header::content_type) ) { - if( !cur.request->send_bin_stream ) + if( cur.request->answer_source == Request::AnswerSource::answer_bin_stream ) { - if( cur.request->return_json ) + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::application_octet_stream); + } + else + { + if( cur.request->answer_container == Request::AnswerContainer::answer_json ) { - cur.request->out_headers.add(Winix::Header::content_type, L"application/json; charset=UTF-8"); + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::application_json_utf8); } else + if( cur.request->answer_container == Request::AnswerContainer::answer_xml ) + { + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::application_xml_utf8); + } + else + if( cur.request->answer_container == Request::AnswerContainer::answer_csv ) + { + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::text_csv_utf8); + } + else + if( cur.request->answer_container == Request::AnswerContainer::answer_text ) { switch( config.content_type_header ) { case 1: - cur.request->out_headers.add(Winix::Header::content_type, L"application/xhtml+xml; charset=UTF-8"); + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::application_xhtml_xml_utf8); break; case 2: - cur.request->out_headers.add(Winix::Header::content_type, L"application/xml; charset=UTF-8"); + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::application_xml_utf8); break; case 0: default: - cur.request->out_headers.add(Winix::Header::content_type, L"text/html; charset=UTF-8"); + cur.request->out_headers.add(Winix::Header::content_type, Winix::Header::text_html_utf8); } } } @@ -1689,7 +1638,8 @@ void App::PrepareHeaders(bool compressing, int compress_encoding, Header header, if( cur.request->send_as_attachment ) AddHeader(L"Content-Disposition", L"attachment"); - if( !cur.request->redirect_to.empty() && !cur.request->return_json ) + //if( !cur.request->redirect_to.empty() && !cur.request->return_json ) + if( !cur.request->redirect_to.empty() ) { PrepareHeadersRedirect(); } @@ -1713,82 +1663,6 @@ void App::PrepareHeaders(bool compressing, int compress_encoding, Header header, } -void App::PrepareStandardJSONFields() -{ - pt::Space & info = cur.request->info; - - if( !info.has_key(L"status") ) - { - info.add(L"status", cur.request->status); - } - - if( !cur.request->redirect_to.empty() && !info.has_key(L"redirect_to") ) - { - info.add(L"redirect_to", cur.request->redirect_to); - } -} - - - - -void App::FilterContent() -{ - Request & req = *cur.request; - - bool filter_main_stream = false; - bool filter_json = false; - - if( config.html_filter && !req.send_bin_stream ) - { - if( req.return_json ) - { - if( !req.return_info_only && req.out_streams_use_html_filter ) - { - filter_json = true; - } - } - else - { - if( req.out_main_stream_use_html_filter ) - filter_main_stream = true; - } - } - - if( filter_main_stream ) - { - std::wstring tmp_out_main_stream; - req.out_main_stream.to_str(tmp_out_main_stream, false); - TemplatesFunctions::html_filter.Filter(tmp_out_main_stream, html_filtered); // IMPROVEME let Filter take pt::WTextStream - - /* - * it would be better to just return a pointer from this method - * - */ - req.out_main_stream.clear(); - req.out_main_stream.PutText(html_filtered); - log << log3 << "App: html in the main stream has been filtered" << logend; - } - - if( filter_json ) - { - for(auto i = req.out_streams.streams_map.begin() ; i != req.out_streams.streams_map.end() ; ++i) - { - HtmlTextStream & stream = *i->second; - - std::wstring tmp_stream; - stream.to_str(tmp_stream, false); - - TemplatesFunctions::html_filter.Filter(tmp_stream, html_filtered); - - stream.clear(); - stream.PutText(html_filtered); - } - - log << log3 << "App: html in json out streams have been filtered" << logend; - } -} - - int App::SelectDeflateVersion() @@ -1856,11 +1730,11 @@ bool App::CanSendContent() return false; } - if( cur.request->return_json ) - { - // if there is a redirect flag then it will be put to info struct - return true; - } +// if( cur.request->return_json ) +// { +// // if there is a redirect flag then it will be put to info struct +// return true; +// } if( !cur.request->redirect_to.empty() ) { @@ -1918,79 +1792,9 @@ bool App::IsRequestedFrame() } -void App::SendTextAnswer() -{ -const pt::WTextStream * source = nullptr; -bool compressing = false; -int compress_encoding = 0; -size_t output_size = 0; - - Header header = GetHTTPStatusCode(); - - if( CanSendContent() ) - { - /* - * FIXME frames are not filtered (when is_htmx_request is true) - * - * FilterContent() should be combined with CreateJSONAnswer() and CreateFrameAnswer() somehow - */ - FilterContent(); - - // cur.request->return_json is depracated, we will create json from models/space registered through request->models object - if( cur.request->return_json ) - { - source = CreateJSONAnswer(); - } - else - if( IsRequestedFrame() ) - { - source = CreateFrameAnswer(); - - if( !source ) - { - empty_response.clear(); - source = &empty_response; - } - } - else - { - source = &cur.request->out_main_stream.get_buffer(); - } - - SelectCompression(source->size(), compressing, compress_encoding); - - pt::wide_stream_to_utf8(*source, output_8bit); - - // !! IMPROVE ME add to log the binary stream as well - if( config.log_server_answer ) - log << log1 << "App: the server's answer is:\n" << output_8bit << "\nApp: end of the server's answer" << logend; - - if( compressing ) - { - compress.Compressing(output_8bit.c_str(), output_8bit.length(), compressed_output, compress_encoding); - output_size = compressed_output.size(); - } - else - { - output_size = output_8bit.size(); - } - } - - PrepareHeaders(compressing, compress_encoding, header, output_size); - SendHeaders(); - SendCookies(); - FCGX_PutS("\r\n", fcgi_request.out); - - if( CanSendContent() ) - { - if( compressing ) - SendData(compressed_output, fcgi_request.out); - else - FCGX_PutStr(output_8bit.c_str(), output_8bit.size(), fcgi_request.out); - } -} - - +// IMPROVEME +// we can send directly from BinaryPage without copying to a temporary buffer +// (but there is no an interface in BinaryPage yet) void App::SendData(const BinaryPage & page, FCGX_Stream * out) { const size_t buf_size = 4096; @@ -2014,28 +1818,410 @@ void App::SendData(const BinaryPage & page, FCGX_Stream * out) } -void App::SendBinaryAnswer() + +void App::SendAnswer() { -BinaryPage & source = cur.request->out_bin_stream; -Header header = h_200; -Error status = cur.request->status; -bool compressing; -int compress_encoding; + output_8bit.clear(); + output_8bit2.clear(); + compressed_output.clear(); - SelectCompression(source.size(), compressing, compress_encoding); + // may use CanSendContent() method? + // what about method HEAD? + if( !cur.request->redirect_to.empty() || !cur.request->x_sendfile.empty() ) + { + Send8bitOutput(output_8bit); + return; + } - if( status == WINIX_ERR_NO_ITEM || status == WINIX_ERR_NO_FUNCTION || status == WINIX_ERR_UNKNOWN_PARAM ) - header = h_404; + if( cur.request->answer_source == Request::AnswerSource::answer_bin_stream ) + { + Send8bitOutput(cur.request->out_bin_stream); + } + else + { + // is this plugin call correct here? + plugin.Call(WINIX_CONTENT_MAKE); - if( status == WINIX_ERR_PERMISSION_DENIED || status == WINIX_ERR_CANT_CHANGE_USER || status == WINIX_ERR_CANT_CHANGE_GROUP ) - header = h_403; + if( cur.request->answer_source == Request::AnswerSource::answer_models && cur.request->use_ezc_engine ) + { + MakeEzcGenerator(); // give me a better name + + if( !cur.request->frame.empty() || cur.request->send_all_frames ) + { + cur.request->answer_source = Request::AnswerSource::answer_frame_streams; + } + else + { + cur.request->answer_source = Request::AnswerSource::answer_main_stream; + } + } + + if( cur.request->answer_source == Request::AnswerSource::answer_main_stream ) + { + const wchar_t * field_name = nullptr; + + if( cur.request->answer_container == Request::AnswerContainer::answer_xml ) + field_name = config.xml_root.c_str(); + + SerializeStream(cur.request->out_main_stream.get_buffer(), field_name); + } + else + if( cur.request->answer_source == Request::AnswerSource::answer_frame_streams ) + { + SerializeFrames(); + } + else + if( cur.request->answer_source == Request::AnswerSource::answer_models ) + { + SerializeModels(); + } + + Send8bitOutput(output_8bit); + } +} - // !! IMPROVE ME add header: content-length (size from Item struct) - // warning: if someone changed a file on the disk (in the real os) - // then winix would send an incorrect content-lenght header, - // we are waiting for the fsck winix function to be implemented - PrepareHeaders(compressing, compress_encoding, header, static_cast(-1)); +void App::SerializeStream(const pt::WTextStream & input_stream, const wchar_t * field_name) +{ + switch( cur.request->answer_container ) + { + case Request::AnswerContainer::answer_json: + SerializeStreamJson(input_stream, field_name); + break; + + case Request::AnswerContainer::answer_xml: + SerializeStreamXml(input_stream, field_name); + break; + + case Request::AnswerContainer::answer_csv: + SerializeStreamCsv(input_stream, field_name); + break; + + case Request::AnswerContainer::answer_text: + default: + FilterHtmlIfNeeded(input_stream, output_8bit); + break; + } +} + + +void App::SerializeStreamJson(const pt::WTextStream & input_stream, const wchar_t * field_name) +{ + if( field_name ) + { + output_8bit << '"'; + pt::esc_to_json(field_name, output_8bit); + output_8bit << "\":"; + } + + output_8bit << '"'; + FilterHtmlIfNeeded(input_stream, output_8bit2); + pt::esc_to_json(output_8bit2, output_8bit); + output_8bit << '"'; +} + + +void App::SerializeStreamXml(const pt::WTextStream & input_stream, const wchar_t * field_name) +{ + if( field_name ) + { + output_8bit << '<'; + pt::esc_to_xml(field_name, output_8bit); + output_8bit << '>'; + } + + FilterHtmlIfNeeded(input_stream, output_8bit2); + pt::esc_to_xml(output_8bit2, output_8bit); + + if( field_name ) + { + output_8bit << "'; + } +} + + +void App::SerializeStreamCsv(const pt::WTextStream & input_stream, const wchar_t * field_name) +{ + if( field_name ) + { + output_8bit << '"'; + pt::esc_to_csv(field_name, output_8bit); + output_8bit << "\";"; + } + + FilterHtmlIfNeeded(input_stream, output_8bit2); + output_8bit << '"'; + pt::esc_to_csv(output_8bit2, output_8bit); + output_8bit << "\";\n"; +} + + +void App::SerializeFrames() +{ + if( cur.request->answer_container == Request::AnswerContainer::answer_json ) + { + output_8bit << '{'; + } + else + if( cur.request->answer_container == Request::AnswerContainer::answer_xml ) + { + output_8bit << '<'; + pt::esc_to_xml(config.xml_root, output_8bit); + output_8bit << '>'; + } + + if( cur.request->frame.empty() || cur.request->send_all_frames ) + SerializeAllFrames(); + else + SerializeOneFrame(); + + if( cur.request->answer_container == Request::AnswerContainer::answer_json ) + { + output_8bit << '}'; + } + else + if( cur.request->answer_container == Request::AnswerContainer::answer_xml ) + { + output_8bit << "'; + } +} + + +void App::SerializeAllFrames() +{ + auto i = cur.request->out_streams.streams_map.begin(); + bool is_first = true; + + for( ; i != cur.request->out_streams.streams_map.end() ; ++i) + { + if( cur.request->answer_container == Request::AnswerContainer::answer_json && !is_first ) + { + output_8bit << ','; + } + + if( cur.request->answer_container == Request::AnswerContainer::answer_xml && i->first.empty() ) + { + log << log2 << "App: I cannot serialize a frame with an empty name to xml (frame skipped)" << logend; + } + else + { + SerializeStream(i->second->get_buffer(), i->first.c_str()); + } + + is_first = false; + } +} + + +void App::SerializeOneFrame() +{ + auto i = cur.request->out_streams.streams_map.find(cur.request->frame); + + if( i != cur.request->out_streams.streams_map.end() ) + { + SerializeStream(i->second->get_buffer(), cur.request->frame.c_str()); + } + else + { + log << log2 << "App: there is no such a frame: " << cur.request->frame << logend; + // return 404 in such a case? + } +} + + + +void App::SerializeModels() +{ + Ezc::Models::ModelsMap models_map = cur.request->models.GetMap(); + auto i = models_map.begin(); + + if( cur.request->answer_container == Request::AnswerContainer::answer_json ) + { + output_8bit << '{'; + } + else + if( cur.request->answer_container == Request::AnswerContainer::answer_xml ) + { + output_8bit << '<'; + pt::esc_to_xml(config.xml_root, output_8bit); + output_8bit << '>'; + log << log2 << "App: serializing models to xml not implemented yet" << logend; + } + + bool is_first = true; + + for( ; i != models_map.end() ; ++i) + { + if( cur.request->answer_container == Request::AnswerContainer::answer_json && !is_first ) + { + output_8bit << ','; + } + + if( cur.request->answer_container == Request::AnswerContainer::answer_xml && i->first.empty() ) + { + log << log2 << "App: I cannot serialize a model with an empty name to xml (model skipped)" << logend; + } + else + { + SerializeModel(i->second, i->first.c_str()); + } + + is_first = false; + } + + if( cur.request->answer_container == Request::AnswerContainer::answer_json ) + { + output_8bit << '}'; + } + else + if( cur.request->answer_container == Request::AnswerContainer::answer_xml ) + { + output_8bit << "'; + } +} + + +void App::SerializeModel(morm::Wrapper & wrapper, const wchar_t * field_name) +{ + switch( cur.request->answer_container ) + { + case Request::AnswerContainer::answer_json: + SerializeModelJson(wrapper, field_name); + break; + + case Request::AnswerContainer::answer_xml: + SerializeModelXml(wrapper, field_name); + break; + + case Request::AnswerContainer::answer_csv: + SerializeModelCsv(wrapper, field_name); + break; + + case Request::AnswerContainer::answer_text: + default: + SerializeModelCsv(wrapper, field_name); + break; + } +} + + +void App::SerializeModelJson(morm::Wrapper & wrapper, const wchar_t * field_name) +{ + if( field_name ) + { + output_8bit << '"'; + pt::esc_to_json(field_name, output_8bit); + output_8bit << "\":"; + } + + if( wrapper.model ) + { + serialized_model.clear(); + wrapper.model->set_connector(model_connector); + wrapper.model->to_text(serialized_model); + output_8bit << serialized_model; + } + + if( wrapper.date ) + { + output_8bit << '"'; + wrapper.date->SerializeISO(output_8bit); + output_8bit << '"'; + } + + if( wrapper.space_wrapper ) + { + wrapper.space_wrapper->get_space()->serialize_to_json_stream(output_8bit, false); + } + + if( wrapper.model_container_wrapper ) + { + wrapper.model_container_wrapper->set_iterator_at_first_model(); + bool is_first = true; + output_8bit << '['; + + while( wrapper.model_container_wrapper->is_iterator_correct() ) + { + if( !is_first ) + output_8bit << ','; + + morm::Model * model = wrapper.model_container_wrapper->get_model(); + serialized_model.clear(); + model->set_connector(model_connector); + model->to_text(serialized_model); + output_8bit << serialized_model; + + wrapper.model_container_wrapper->increment_iterator(); + is_first = false; + } + + output_8bit << ']'; + } +} + + +void App::SerializeModelXml(morm::Wrapper & wrapper, const wchar_t * field_name) +{ + // IMPROVEME + log << log2 << "App: serializing models to xml not implemented yet" << logend; +} + + +void App::SerializeModelCsv(morm::Wrapper & wrapper, const wchar_t * field_name) +{ + // IMPROVEME + log << log2 << "App: serializing models to csv not implemented yet" << logend; +} + + + + +// IMPROVEME +// gime me a better name +void App::FilterHtmlIfNeeded(const pt::WTextStream & input_stream, BinaryPage & output, bool clear_stream) +{ + if( config.html_filter && cur.request->use_html_filter ) + { + TemplatesFunctions::html_filter.filter(input_stream, output, clear_stream); + } + else + { + pt::wide_stream_to_utf8(input_stream, output, clear_stream); + } +} + + +void App::Send8bitOutput(BinaryPage & output) +{ + bool compressing = false; + int compress_encoding = 0; + Header header = GetHTTPStatusCode(); + size_t output_size = 0; + + SelectCompression(output.size(), compressing, compress_encoding); + + if( config.log_server_answer ) + { + log << log1 << "App: the server's answer is:\n" << output << "\nApp: end of the server's answer" << logend; + } + + if( compressing ) + { + compress.Compressing(output, compressed_output, compress_encoding); + output_size = compressed_output.size(); + } + else + { + output_size = output.size(); + } + + PrepareHeaders(compressing, compress_encoding, header, output_size); SendHeaders(); SendCookies(); FCGX_PutS("\r\n", fcgi_request.out); @@ -2043,29 +2229,13 @@ int compress_encoding; if( CanSendContent() ) { if( compressing ) - { - compress.Compressing(source, compressed_output, compress_encoding); SendData(compressed_output, fcgi_request.out); - } else - { - SendData(source, fcgi_request.out); - } + SendData(output, fcgi_request.out); } } -void App::SendAnswer() -{ - if( cur.request->return_json ) - PrepareStandardJSONFields(); - - if( cur.request->send_bin_stream ) - SendBinaryAnswer(); - else - SendTextAnswer(); -} - void App::LogUser(const char * msg, uid_t id) { diff --git a/winixd/core/app.h b/winixd/core/app.h index ae90f17..6de989f 100644 --- a/winixd/core/app.h +++ b/winixd/core/app.h @@ -149,9 +149,13 @@ private: std::string send_data_buf; pt::WTextStream json_out_stream; std::string aheader_name, aheader_value; - std::wstring html_filtered; - std::string output_8bit; + //std::wstring html_filtered; + //std::string output_8bit; + pt::TextStream serialized_model; + + BinaryPage output_8bit, output_8bit2; BinaryPage compressed_output; + std::wstring cookie_id_string; std::wstring http_header_name; std::wstring http_header_value; @@ -194,19 +198,32 @@ private: void CheckIfNeedSSLredirect(); void SetLocale(); void CheckPostRedirect(); - void MakePage(); + void MakeEzcGenerator(); void AddDefaultModels(); void Make(); void SaveSessionsIfNeeded(); // !! IMPROVE ME wywalic do menagera sesji?? void LogAccess(); void SendData(const BinaryPage & page, FCGX_Stream * out); - pt::WTextStream * CreateFrameAnswer(); - pt::WTextStream * CreateJSONAnswer(); void ReadRequest(); - void SendTextAnswer(); - void SendBinaryAnswer(); void SendAnswer(); + void SerializeStream(const pt::WTextStream & input_stream, const wchar_t * field_name); + void SerializeStreamJson(const pt::WTextStream & input_stream, const wchar_t * field_name); + void SerializeStreamXml(const pt::WTextStream & input_stream, const wchar_t * field_name); + void SerializeStreamCsv(const pt::WTextStream & input_stream, const wchar_t * field_name); + void SerializeFrames(); + void SerializeAllFrames(); + void SerializeOneFrame(); + void SerializeModels(); + void Send8bitOutput(BinaryPage & output); + + void SerializeModel(morm::Wrapper & wrapper, const wchar_t * field_name); + void SerializeModelJson(morm::Wrapper & wrapper, const wchar_t * field_name); + void SerializeModelXml(morm::Wrapper & wrapper, const wchar_t * field_name); + void SerializeModelCsv(morm::Wrapper & wrapper, const wchar_t * field_name); + + void FilterHtmlIfNeeded(const pt::WTextStream & input_stream, BinaryPage & output, bool clear_stream = true); + void LogEnvironmentVariables(); void LogEnvironmentHTTPVariables(); @@ -230,7 +247,6 @@ private: Header GetHTTPStatusCode(); void PrepareSessionCookie(); - void FilterContent(); void SendHeaders(); void SendCookies(); bool AddHeader(const wchar_t * name, const wchar_t * value); @@ -246,7 +262,6 @@ private: void PrepareHeadersCompression(int compress_encoding); void PrepareHeadersNormal(Header header, size_t output_size); void PrepareHeaders(bool compressing, int compress_encoding, Header header, size_t output_size); - void PrepareStandardJSONFields(); int SelectDeflateVersion(); void SelectCompression(size_t source_len, bool & compression_allowed, int & compression_encoding); bool CanSendContent(); diff --git a/winixd/core/compress.cpp b/winixd/core/compress.cpp index 28a8c7e..37b5d0b 100644 --- a/winixd/core/compress.cpp +++ b/winixd/core/compress.cpp @@ -258,6 +258,8 @@ BinaryPage::const_iterator i = page.begin(); source_len -= strm.avail_in; flush = (source_len == 0) ? Z_FINISH : Z_NO_FLUSH; strm.next_in = (Bytef*)buffer_in; + + // IMPROVE ME we can add an interface to pt::TextStreamBase<> and get all chunks of memory CopyToInputBuffer(i, strm.avail_in); do diff --git a/winixd/core/config.cpp b/winixd/core/config.cpp index d85f5d9..d3a28d6 100644 --- a/winixd/core/config.cpp +++ b/winixd/core/config.cpp @@ -285,6 +285,9 @@ void Config::AssignValues(bool stdout_is_closed) ezc_max_loop_elements = Size(L"ezc_max_loop_elements", 5000); ezc_out_streams_size = Size(L"ezc_out_streams_size", 128); request_frame_parameter = Text(L"request_frame_parameter", L"frame"); + request_all_frames_parameter = Text(L"request_all_frames_parameter", L"allframes"); + + xml_root = Text(L"xml_root", L"winix"); account_need_email_verification = Bool(L"account_need_email_verification", true); reset_password_code_expiration_time = Long(L"reset_password_code_expiration_time", 86400); diff --git a/winixd/core/config.h b/winixd/core/config.h index 3fcf0c8..9716f9a 100644 --- a/winixd/core/config.h +++ b/winixd/core/config.h @@ -676,6 +676,14 @@ public: // default: frame std::wstring request_frame_parameter; + // the name of the url parameter for returning all frames, e.g. https://domain.tld/mydir/myfunction/allframes + // default: allframes + std::wstring request_all_frames_parameter; + + // the name of the root element when serializing request answer to xml + // default: winix + std::wstring xml_root; + // when true then when a user want to create a new account // he has to provide his email and a message will be sent back to him // with a link to activate the account diff --git a/winixd/core/header.h b/winixd/core/header.h index c831033..63c8a4e 100644 --- a/winixd/core/header.h +++ b/winixd/core/header.h @@ -43,10 +43,30 @@ class Header { public: - - static constexpr const wchar_t * content_type = L"Content-Type"; + /* + * headers' names + */ + static constexpr const wchar_t * content_type = L"Content-Type"; + /* + * headers' values + */ + static constexpr const wchar_t * application_octet_stream = L"application/octet-stream"; + + static constexpr const wchar_t * text_html = L"text/html"; + static constexpr const wchar_t * application_json = L"application/json"; + static constexpr const wchar_t * application_xml = L"application/xml"; + static constexpr const wchar_t * application_xhtml_xml = L"application/xhtml+xml"; + static constexpr const wchar_t * text_csv = L"text/csv"; + static constexpr const wchar_t * text_javascript = L"text/javascript"; + + static constexpr const wchar_t * text_html_utf8 = L"text/html; charset=UTF-8"; + static constexpr const wchar_t * application_json_utf8 = L"application/json; charset=UTF-8"; + static constexpr const wchar_t * application_xml_utf8 = L"application/xml; charset=UTF-8"; + static constexpr const wchar_t * application_xhtml_xml_utf8 = L"application/xhtml+xml; charset=UTF-8"; + static constexpr const wchar_t * text_csv_utf8 = L"text/csv; charset=UTF-8"; + static constexpr const wchar_t * text_javascript_utf8 = L"text/javascript; charset=UTF-8"; }; diff --git a/winixd/core/misc.cpp b/winixd/core/misc.cpp index 9980b07..ae62a92 100644 --- a/winixd/core/misc.cpp +++ b/winixd/core/misc.cpp @@ -1500,6 +1500,18 @@ void JSONescapeStream(const pt::WTextStream & in, pt::WTextStream & out) } +void JSONescapeStream(const std::wstring & in, pt::WTextStream & out) +{ + std::wstring::const_iterator i = in.begin(); + + for( ; i != in.end() ; ++i) + { + JSONescape(*i, out); + } +} + + + bool wide_to_utf8(const wchar_t * wide_string, char * utf8, size_t utf8_size) { bool res = pt::wide_to_utf8(wide_string, utf8, utf8_size); @@ -1589,6 +1601,5 @@ void timespec_to_stream_with_unit(timespec & val, pt::Stream & stream) } - } // namespace Winix diff --git a/winixd/core/misc.h b/winixd/core/misc.h index efaa472..495977f 100644 --- a/winixd/core/misc.h +++ b/winixd/core/misc.h @@ -986,6 +986,7 @@ void JSONescape(const StringType & str, Stream & out) void JSONescapeStream(const pt::WTextStream & in, pt::WTextStream & out); +void JSONescapeStream(const std::wstring & in, pt::WTextStream & out); diff --git a/winixd/core/request.cpp b/winixd/core/request.cpp index 2ecbd65..c25cbd9 100644 --- a/winixd/core/request.cpp +++ b/winixd/core/request.cpp @@ -86,8 +86,6 @@ size_t len = 0; */ out_streams.ClearMap(); out_streams.ResizeTab(len); - out_main_stream_use_html_filter = true; - out_streams_use_html_filter = true; } @@ -116,8 +114,6 @@ void Request::Clear() out_headers.clear(); out_cookies.clear(); - page_generated = false; - env_request_method.clear(); env_request_uri.clear(); env_http_cookie.clear(); @@ -137,6 +133,12 @@ void Request::Clear() function = nullptr; param_tab.clear(); anchor.clear(); + + answer_source = AnswerSource::answer_models; + answer_container = AnswerContainer::answer_text; + use_ezc_engine = true; + frame.clear(); + send_all_frames = false; status = WINIX_ERR_OK; @@ -165,13 +167,9 @@ void Request::Clear() timespec_ezc_engine_stop.tv_nsec = 0; subdomain.clear(); - return_info_only = false; - info.clear(); - return_json = false; models.Clear(); out_bin_stream.clear(); - send_bin_stream = false; gen_trim_white = false; gen_skip_new_line = false; @@ -182,6 +180,7 @@ void Request::Clear() use_200_status_for_not_found_and_permission_denied = false; html_template.clear(); + use_html_filter = false; } @@ -207,6 +206,110 @@ void Request::RequestEnds() +bool Request::PrepareAnswerType() +{ + answer_source = AnswerSource::answer_models; + answer_container = AnswerContainer::answer_text; + use_ezc_engine = true; + + frame = ParamValue(config->request_frame_parameter); + send_all_frames = (ParamValuep(config->request_all_frames_parameter) != nullptr); + use_html_filter = config->html_filter; + + bool ok = true; + + // IMPLEMENT ME add checking for Accept header; + + ok = ok && CheckContainerParameter(); + ok = ok && CheckAnswerParameter(); + + + return ok; +} + + +// IMPROVE ME give me a better name +bool Request::CheckContainerParameter() +{ + std::wstring * container = ParamValuep(L"container"); + + if( container ) + { + // IMPROVEME do a plugin call here + // if a plugin can consume this then don't check text/json/xml/csv and just return true + + if( *container == L"text" ) + { + answer_container = Request::AnswerContainer::answer_text; + } + else + if( *container == L"json" ) + { + answer_container = Request::AnswerContainer::answer_json; + } + else + if( *container == L"xml" ) + { + answer_container = Request::AnswerContainer::answer_xml; + } + else + if( *container == L"csv" ) + { + answer_container = Request::AnswerContainer::answer_csv; + } + else + { + Log * log = get_logger(); + + if( log ) + { + (*log) << log2 << "App: an unknown 'container' parameter: " << *container << logend; + // IMPROVE ME set status to 404 + return false; + } + } + } + + return true; +} + + +// IMPROVE ME give me a better name +bool Request::CheckAnswerParameter() +{ + std::wstring * answer = ParamValuep(L"answer"); + + if( answer ) + { + // IMPROVEME do a plugin call here + // if a plugin can consume this then don't check html/data and just return true + + if( *answer == L"html" ) + { + use_ezc_engine = true; + } + else + if( *answer == L"data" ) + { + use_ezc_engine = false; + } + else + { + Log * log = get_logger(); + + if( log ) + { + (*log) << log2 << "App: an unknown 'answer' parameter: " << *answer << logend; + // IMPROVE ME set status to 404 + return false; + } + } + } + + return true; +} + + bool Request::IsPostVar(const wchar_t * var) { PostTab::iterator p; diff --git a/winixd/core/request.h b/winixd/core/request.h index c436a52..9eb9392 100644 --- a/winixd/core/request.h +++ b/winixd/core/request.h @@ -249,6 +249,181 @@ public: * */ + // the algorithm how a request's answer is created + // ------------------------------------------------------------------------------------------ + // + // at the beginning of a request winix sets + // answer_source to models + // answer_container to text + // use_ezc_engine to true + // + // next answer_container and use_ezc_engine can be changed in the following way: + // + // 1. winix will look for 'Accept' http header and depending on the header winix will set: + // + // Accept | answer_container | use_ezc_engine + // ------------------------------------|----------------- + // application/json | json | false + // application/xml | xml | false + // text/csv | csv | false + // + // + // + // 2. next answer_container is set depending on 'container' url parameter + // container | answer_container + // --------------------------------------------------------- + // not present | don't change the value + // text | text + // json | json + // xml | xml + // csv | csv + // + // use_ezc_engine is set depending on 'answer' url parameter: + // answer | use_ezc_engine + // --------------------------------- + // not present | don't change the value + // html | true + // data | false + // + // if 'answer' is html then we take into account two more parameters: + // frame: frame_name (empty default) - if set then winix returns this specific frame + // allframes: (if present then winix returns all frames) + // + // + // + // + // + // + // the whole algorithm how the answer is created is shown below: + // + // + // answer_source: bin_stream + // |--------------->-------------- send out_bin_stream + // | + // | + // | + // | + // | answer_source: models and use_ezc_engine: true + // |------------------------>------------------------ + // | | + // | use ezc engine + // | for converting models + // | to out_main_stream and frame_streams + // | | + // | change answer_source to + // | frame_stream (if there is 'allframes' parameter or 'frame' parameter is not empty) + // | or to main_stream otherwise + // | | + // |-------------------------<----------------------- + // | + // | + // | + // | + // | + // | answer_source: main_stream + // |----------------------->------------------------- + // | | + // | depending on answer_container + // | | + // | -------------------------------------------------------------------- + // | | | | | + // | text json xml csv + // | | | | | + // | send send send send + // | out_main_stream out_main_stream out_main_stream out_main_stream + // | as json text in one cell in first csv cell + // | (without making e.g. + // | an object) + // | e.g. "text" text + // | + // | + // | + // | + // | answer_source: frame_streams + // |-------->------- + // | | + // | | + // | depending on + // | 'frame' string variable and 'allframes' + // | | + // | | + // | | is 'frame' string empty or there is 'allframes' parameter + // | |----------------------->--------------------- + // | | | + // | | depending on answer_container + // | | | + // | | -------------------------------------------------------------------- + // | | | | | | + // | | text json xml csv + // | | | | | | + // | | send text serialize serialize serialize + // | | from all frames all frames all frames all frames + // | | one by one to json to xml to csv + // | | + // | | + // | | + // | | + // | | is 'frame' string not empty and there is no 'allframes' parameter + // | |----------------------->--------------------- + // | | + // | depending on answer_container + // | | + // | -------------------------------------------------------------------- + // | | | | | + // | text json xml csv + // | | | | | + // | send text serialize serialize serialize + // | from one frame one frame one frame one frame + // | to json to xml to csv + // | + // | + // | + // | + // | + // | + // | answer_source: models + // |------------------------>------------------------ + // | + // depending on answer_container + // | + // -------------------------------------------------------------------- + // | | | | + // text json xml csv + // | | | | + // serialize serialize models serialize models serialize models + // models to to json to xml to csv + // csv + // but return + // as text/plain + + + // change maybe answer_bin_stream -> source_bin_stream? + enum AnswerSource + { + answer_bin_stream, + answer_models, + answer_main_stream, + answer_frame_streams, + }; + + + // change maybe answer_text -> container_text? + enum AnswerContainer + { + answer_text, + answer_json, + answer_xml, + answer_csv, + }; + + AnswerSource answer_source; + AnswerContainer answer_container; + + bool use_ezc_engine; + + std::wstring frame; + bool send_all_frames; + // request status // !! CHANGE ME it'll be better to use ordinary http result codes @@ -280,90 +455,24 @@ public: // a value can be either a cookie value or the whole cookie string (with domain, date etc) pt::Space out_cookies; - // winix can return either a text answer or a binary answer - // if send_bin_stream is true then the binary answer is sent (out_bin_stream) - // or if send_bin_stream is false then the text answer is sent - // default: false - // - // - // winix answer send to the client's browser - // | - // | - // depending on send_bin_stream - // (if false) ------------------------------------------------- (if true) - // | | - // text answer binary answer - // | | - // depending on return_json sending out_bin_stream - // (if false) ------------------------------------ (if true) - // | | - // normal request ajax request - // | | - // sending out_main_stream | - // | - // | - // depending on return_info_only - // (if false) ------------------------------------------------------------- (if true) - // | | - // generating JSON object from: generating JSON object only from info - // out_streams and info, e.g.: e.g.: - // { { info object serialized here } - // "out": { out_streams serialized here e.g.: - // "stream_name_1": "some html content", - // "stream_name_2": "some other html content" - // }, - // "info": { info object serialized here } - // } - // - // - bool send_bin_stream; - // binary page sent to the client if send_bin_stream is true + // binary page sent to the client if answer_source is answer_bin_stream BinaryPage out_bin_stream; - // when returning the text answer we can either return the whole html page (normal requests) - // or a JSON object (for requests generated from AJAX) - // if return_json is false then we return the whole html page (which is in out_main_stream) - // if return_json is true we are creating an JSON object from out_streams - // and from info space (see above picture) - // (or just only from info if return_info_only is true) - // default: false - // return_json is set to true by App at the beginning of a request - // if reqtype:json parameter is present (in the url) - // note: return_json is only valid if send_bin_stream is false - bool return_json; - // main text output stream where the html otput is generated from ezc templates // here the whole html page (with doctype, head, body) is generated HtmlTextStream out_main_stream; - // text output streams used in ajax requests (send in JSON format to the client) + // text output streams used in ajax requests // in ezc templates you can use [ezc frame "stream_name"] or just [frame "stream_name"] keyword // to switch between streams Ezc::OutStreams out_streams; - // if true the JSON object is generated only from info (out_streams are not used) - // default: false - bool return_info_only; - - // additional info added when sending the JSON answer - pt::Space info; - // models to return or to render through ezc library Ezc::Models models; - - // if set to true then the standard template system will not be used - // default: false - bool page_generated; - - // whether or not the main html stream should be filtered by our html filter - bool out_main_stream_use_html_filter; - - // whether or not the ajax streams should be filtered by our html filter - // this filter is only aplied to streams in "out" space, "info" space is not touched - bool out_streams_use_html_filter; - + // filter html content with HTMLFilter, default the same as config.html_filter + bool use_html_filter; // if this variable is true then winix always return 200 OK header // when the status would be 404 (not found) or 403 (permission denied) @@ -375,7 +484,6 @@ public: bool gen_skip_new_line; bool gen_use_special_chars; - // index template name std::wstring html_template; @@ -384,6 +492,7 @@ public: additional variables used for common uses */ + // DEPRECATED will be removed // usually items in the current directory (depends on the function) std::vector item_tab; @@ -407,7 +516,9 @@ public: void RequestEnds(); void Clear(); - + bool PrepareAnswerType(); + bool CheckContainerParameter(); + bool CheckAnswerParameter(); bool IsParam(const wchar_t * param_name); bool IsParam(const std::wstring & param_name); diff --git a/winixd/core/system.cpp b/winixd/core/system.cpp index 0b85360..6171b63 100644 --- a/winixd/core/system.cpp +++ b/winixd/core/system.cpp @@ -1461,7 +1461,7 @@ return ok; current limitation: warning: the url is not prepared by PrepareUrl() (PrepareUrl is from functions) */ -bool System::AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url, bool overwrite_existing) +bool System::AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url, const wchar_t * mime_type, bool overwrite_existing) { if( config->common_dir.empty() ) { @@ -1489,20 +1489,14 @@ bool System::AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url, morm::Finder finder(model_connector); - bool status = finder.select().where().eq(L"parent_id", var->id).eq(L"url", url).get(file_content_item); + file_content_item = finder.select().where().eq(L"parent_id", var->id).eq(L"url", url).get(); - //if( db->GetItem(var->id, url, file_content_item) == WINIX_ERR_OK ) - if( status ) + if( file_content_item.found() ) { - if( overwrite_existing ) - { - file_content_item.remove(); - //db->DelItem(file_content_item); - } - else - { + if( !overwrite_existing ) return true; - } + + file_content_item.remove(); } file_content_item.Clear(); @@ -1517,6 +1511,9 @@ bool System::AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url, file_content_item.item_content.content_raw = file_content; file_content_item.item_content.content_raw_type = ItemContent::ct_other; + if( mime_type ) + file_content_item.item_content.file_mime_type = mime_type; + return AddFile(file_content_item, false); } diff --git a/winixd/core/system.h b/winixd/core/system.h index 2b4e87b..1fe3c47 100644 --- a/winixd/core/system.h +++ b/winixd/core/system.h @@ -210,7 +210,7 @@ public: bool follow_dir_default = false, bool stop_on_link_redirect = false, bool check_access = true); - bool AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url, bool overwrite_existing = true); + bool AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url, const wchar_t * mime_type = nullptr, bool overwrite_existing = true); // reloading time zones void ReadTimeZones(); diff --git a/winixd/functions/Makefile.dep b/winixd/functions/Makefile.dep index 7cf54af..9858015 100644 --- a/winixd/functions/Makefile.dep +++ b/winixd/functions/Makefile.dep @@ -1637,9 +1637,6 @@ functionparser.o: ../../../winix/winixd/core/config.h functionparser.o: ../../../pikotools/src/space/spaceparser.h functionparser.o: ../../../pikotools/src/space/space.h functionparser.o: ../../../pikotools/src/convert/baseparser.h -functionparser.o: ../../../winix/winixd/core/log.h -functionparser.o: ../../../winix/winixd/core/logmanipulators.h -functionparser.o: ../../../pikotools/src/log/log.h functionparser.o: ../../../pikotools/src/textstream/textstream.h functionparser.o: ../../../pikotools/src/textstream/stream.h functionparser.o: ../../../pikotools/src/space/space.h @@ -1652,6 +1649,9 @@ functionparser.o: ../../../pikotools/src/utf8/utf8_private.h functionparser.o: ../../../pikotools/src/date/date.h functionparser.o: ../../../pikotools/src/membuffer/membuffer.h functionparser.o: ../../../pikotools/src/textstream/types.h +functionparser.o: ../../../winix/winixd/core/log.h +functionparser.o: ../../../winix/winixd/core/logmanipulators.h +functionparser.o: ../../../pikotools/src/log/log.h functionparser.o: ../../../pikotools/src/log/filelog.h functionparser.o: ../../../morm/src/morm.h ../../../morm/src/morm_types.h functionparser.o: ../../../morm/src/model.h @@ -4177,9 +4177,6 @@ privchanger.o: ../../../winix/winixd/core/config.h privchanger.o: ../../../pikotools/src/space/spaceparser.h privchanger.o: ../../../pikotools/src/space/space.h privchanger.o: ../../../pikotools/src/convert/baseparser.h -privchanger.o: ../../../winix/winixd/core/log.h -privchanger.o: ../../../winix/winixd/core/logmanipulators.h -privchanger.o: ../../../pikotools/src/log/log.h privchanger.o: ../../../pikotools/src/textstream/textstream.h privchanger.o: ../../../pikotools/src/textstream/stream.h privchanger.o: ../../../pikotools/src/space/space.h @@ -4192,6 +4189,9 @@ privchanger.o: ../../../pikotools/src/utf8/utf8_private.h privchanger.o: ../../../pikotools/src/date/date.h privchanger.o: ../../../pikotools/src/membuffer/membuffer.h privchanger.o: ../../../pikotools/src/textstream/types.h +privchanger.o: ../../../winix/winixd/core/log.h +privchanger.o: ../../../winix/winixd/core/logmanipulators.h +privchanger.o: ../../../pikotools/src/log/log.h privchanger.o: ../../../pikotools/src/log/filelog.h ../../../morm/src/morm.h privchanger.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h privchanger.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h diff --git a/winixd/functions/cat.cpp b/winixd/functions/cat.cpp index e6f899d..4a0734c 100644 --- a/winixd/functions/cat.cpp +++ b/winixd/functions/cat.cpp @@ -66,6 +66,11 @@ void Cat::MakeGet() return; } + if( !cur->request->item.item_content.file_mime_type.empty() ) + { + cur->request->out_headers.add(Header::content_type, cur->request->item.item_content.file_mime_type); + } + cur->request->send_as_attachment = cur->request->IsParam(L"attachment"); } diff --git a/winixd/functions/cp.cpp b/winixd/functions/cp.cpp index 2a46aed..eda5ad0 100644 --- a/winixd/functions/cp.cpp +++ b/winixd/functions/cp.cpp @@ -311,7 +311,11 @@ long Cp::CopyDirTree(const Item & dir, long dst_dir_id) temp.item_content.link_redirect = 0; } - cur->request->status = system->dirs.AddDirectory(temp); + bool status = system->dirs.AddDirectory(temp); + + if( !status ) + cur->request->status = WINIX_ERR_PERMISSION_DENIED; + loop_checker.push_back(temp.id); // remember the new dir_id because temp can be changed diff --git a/winixd/functions/download.cpp b/winixd/functions/download.cpp index d01b75e..3802444 100644 --- a/winixd/functions/download.cpp +++ b/winixd/functions/download.cpp @@ -91,7 +91,7 @@ void Download::MakeGet() } cur->request->x_sendfile.clear(); - cur->request->send_bin_stream = true; + cur->request->answer_source = Request::AnswerSource::answer_bin_stream; } } else diff --git a/winixd/functions/emacs.cpp b/winixd/functions/emacs.cpp index 542db95..e10bf73 100644 --- a/winixd/functions/emacs.cpp +++ b/winixd/functions/emacs.cpp @@ -128,10 +128,12 @@ return WINIX_NOTIFY_CODE_ADD; } - - +// IMPROVEME +// make some kind of utils and put this method there +// because this method is used from ckeditor and other editors too void Emacs::MakePost() { + bool status = false; bool adding = !cur->request->is_item; if( !adding ) @@ -147,36 +149,46 @@ void Emacs::MakePost() if( adding ) { - cur->request->is_item = true; // !! moze lepiej nie ustawiac is_item? (bo jak wystapi blad np dodania do bazy danych - // to formularz edycji zmieni sie z 'dodaj' na 'edytuj' - cur->request->item.item_content.privileges = system->NewFilePrivileges(); - cur->request->status = system->AddFile(cur->request->item, NotifyCodeAdd()) ? WINIX_ERR_OK : WINIX_ERR_PERMISSION_DENIED; + cur->request->item.item_content.privileges = system->NewFilePrivileges(); + status = system->AddFile(cur->request->item, NotifyCodeAdd()); + + if( status ) + { + cur->request->is_item = true; + } } else { - if( system->EditFile(cur->request->item, cur->request->item.url != old_url, NotifyCodeEdit()) ) - cur->request->status = WINIX_ERR_OK; - else - cur->request->status = WINIX_ERR_PERMISSION_DENIED; + status = system->EditFile(cur->request->item, cur->request->item.url != old_url, NotifyCodeEdit()); } - if( cur->request->status == WINIX_ERR_OK ) + cur->request->status = status ? WINIX_ERR_OK : WINIX_ERR_PERMISSION_DENIED; + answer.add(L"status", status); + + if( status ) { if( adding ) { system->RedirectToLastFunction(nullptr, false); + answer.add(L"redirect_to", cur->request->redirect_to); + + if( cur->request->answer_container != Request::AnswerContainer::answer_text ) + { + cur->request->redirect_to.clear(); + } } functions->CheckSpecialFile(cur->request->item); } - else - { - log << log1 << "Emacs: error: " << cur->request->status << logend; - } + + cur->request->models.Add(L"answer", answer); } - +void Emacs::Clear() +{ + answer.clear(); +} diff --git a/winixd/functions/emacs.h b/winixd/functions/emacs.h index 60f990a..02be6f7 100644 --- a/winixd/functions/emacs.h +++ b/winixd/functions/emacs.h @@ -56,10 +56,14 @@ public: private: bool HasAccess(const Item & item); // !! takie funkcje to nie powinny byc skladowe modelu? + void Clear(); + int NotifyCodeEdit(); int NotifyCodeAdd(); std::wstring old_url; + pt::Space answer; + }; diff --git a/winixd/functions/functions.cpp b/winixd/functions/functions.cpp index d26d601..6eff8fe 100644 --- a/winixd/functions/functions.cpp +++ b/winixd/functions/functions.cpp @@ -624,7 +624,7 @@ void Functions::ReadItemFilterHtml(Item & item) html_filter.ClearOrphans(); // SetNoFilterTag doesn't have to be called (default empty tag) - html_filter.Filter(cur->request->PostVar(L"itemcontent"), item.item_content.content_raw); + html_filter.filter(cur->request->PostVar(L"itemcontent"), item.item_content.content_raw); } diff --git a/winixd/functions/mkdir.cpp b/winixd/functions/mkdir.cpp index 76dc8e2..79cb0a8 100644 --- a/winixd/functions/mkdir.cpp +++ b/winixd/functions/mkdir.cpp @@ -96,9 +96,7 @@ void Mkdir::PostFunMkdir(bool add_to_dir_tab, int privileges) cur->request->item.item_content.privileges = privileges; Item * pdir; - cur->request->status = system->dirs.AddDirectory(cur->request->item, add_to_dir_tab, &pdir); - - if( cur->request->status == WINIX_ERR_OK ) + if( system->dirs.AddDirectory(cur->request->item, add_to_dir_tab, &pdir) ) { if( pdir ) plugin->Call(WINIX_DIR_ADDED, pdir); @@ -107,7 +105,7 @@ void Mkdir::PostFunMkdir(bool add_to_dir_tab, int privileges) } else { - log << log1 << "Content: PostFunMkdir: Error: " << cur->request->status << logend; + log << log1 << "Mkdir: PostFunMkdir: cannot create directory " << logend; } } diff --git a/winixd/functions/rm.cpp b/winixd/functions/rm.cpp index e1ba711..6b7f6ef 100644 --- a/winixd/functions/rm.cpp +++ b/winixd/functions/rm.cpp @@ -514,32 +514,20 @@ void Rm::RemoveDir() void Rm::Clear() { content_item_tab.clear(); + files.clear(); } /* - * !! IMPROVE ME what about a Content-Type header for javascript? + * */ void Rm::CreateJSON(bool status) { -using TemplatesFunctions::R; -pt::WTextStream buf; + pt::Space & file = files.add_empty_space(); + file.add(cur->request->item.url, status); - JSONescape(cur->request->item.url, buf); - - auto & out = cur->request->out_main_stream; - out << R("{\"files\": [{\"") << R(buf) << R("\": "); - - if( status ) - out << R("true"); - else - out << R("false"); - - out << R("}]}"); - - cur->request->page_generated = true; - cur->request->out_main_stream_use_html_filter = false; + cur->request->models.Add(L"files", files); } diff --git a/winixd/functions/rm.h b/winixd/functions/rm.h index ce6ef6a..6ebafd8 100644 --- a/winixd/functions/rm.h +++ b/winixd/functions/rm.h @@ -88,6 +88,8 @@ private: std::vector rm_path_dir_tab; Item rm_path_item; + pt::Space files; + bool HasAccessToDir(const Item & dir, bool only_content); void Prepare(); void Clear(); diff --git a/winixd/functions/run.cpp b/winixd/functions/run.cpp index baf682b..8f47753 100644 --- a/winixd/functions/run.cpp +++ b/winixd/functions/run.cpp @@ -75,6 +75,11 @@ void Run::MakeGet() cur->request->status = WINIX_ERR_PERMISSION_DENIED; return; } + + if( !cur->request->item.item_content.file_mime_type.empty() ) + { + cur->request->out_headers.add(Header::content_type, cur->request->item.item_content.file_mime_type); + } } diff --git a/winixd/functions/tinymce.cpp b/winixd/functions/tinymce.cpp index 8667a64..8a87e5a 100644 --- a/winixd/functions/tinymce.cpp +++ b/winixd/functions/tinymce.cpp @@ -5,7 +5,7 @@ */ /* - * Copyright (c) 2008-2014, Tomasz Sowa + * Copyright (c) 2008-2021, Tomasz Sowa * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -51,7 +51,7 @@ Tinymce::Tinymce() void Tinymce::Init() { - system->AddCommonFileToVar(L"winix/tinymce.js", L"tinymce.js"); + system->AddCommonFileToVar(L"winix/tinymce.js", L"tinymce.js", Header::text_javascript_utf8); } diff --git a/winixd/functions/upload.cpp b/winixd/functions/upload.cpp index 6782ef4..aba2f44 100644 --- a/winixd/functions/upload.cpp +++ b/winixd/functions/upload.cpp @@ -394,7 +394,6 @@ void Upload::MakePost() void Upload::CreateAnswer() { Request & req = *cur->request; - pt::Space & files = req.info.add_empty_space(L"files"); for(size_t i=0 ; irequest->return_json = true; - cur->request->return_info_only = true; + cur->request->models.Add(L"files", files); } @@ -460,6 +458,12 @@ void Upload::MakeGet() } +void Upload::Clear() +{ + files.clear(); +} + + } // namespace diff --git a/winixd/functions/upload.h b/winixd/functions/upload.h index 5550bb6..177176b 100644 --- a/winixd/functions/upload.h +++ b/winixd/functions/upload.h @@ -63,9 +63,11 @@ private: //DbItemQuery query; bool is_jquery_upload; magic_t magic_cookie; + pt::Space files; void Init(); void Finish(); + void Clear(); bool HasAccess(const Item & item); bool UploadSaveStaticFile(const Item & item, const std::wstring & tmp_filename); diff --git a/winixd/html/fun_run.html b/winixd/html/fun_run.html index fd787b1..c3fc5fb 100644 --- a/winixd/html/fun_run.html +++ b/winixd/html/fun_run.html @@ -1,7 +1 @@ -[if item.content.type_is "other"][item.run][else] - -
- [item.execute] -
- -[end] +[item.execute] diff --git a/winixd/html/fun_tinymce.html b/winixd/html/fun_tinymce.html index 76ac8cb..30f1ba1 100644 --- a/winixd/html/fun_tinymce.html +++ b/winixd/html/fun_tinymce.html @@ -87,5 +87,4 @@ - diff --git a/winixd/html/fun_upload.html b/winixd/html/fun_upload.html index 69d20ef..eb6fce5 100644 --- a/winixd/html/fun_upload.html +++ b/winixd/html/fun_upload.html @@ -207,8 +207,9 @@ $('#fileupload button.start').css('display', 'none'); $('#fileupload').fileupload(\{ - "url": "[doc_base_url][dir]upload/jquery_upload", - "autoUpload": true + "url": "[doc_base_url][dir]upload/jquery_upload/container:json/answer:data", + "autoUpload": true, + "dataType": "json", \}); $('#fileupload').fileupload( diff --git a/winixd/main/Makefile.dep b/winixd/main/Makefile.dep index 0bf6a74..ab80125 100644 --- a/winixd/main/Makefile.dep +++ b/winixd/main/Makefile.dep @@ -53,7 +53,8 @@ main.o: ../../../winix/winixd/core/synchro.h main.o: ../../../pikotools/src/convert/patternreplacer.h main.o: ../../../pikotools/src/convert/strtoint.h main.o: ../../../pikotools/src/convert/text.h -main.o: ../../../pikotools/src/convert/misc.h ../../../ezc/src/ezc.h +main.o: ../../../pikotools/src/convert/misc.h +main.o: ../../../pikotools/src/utf8/utf8_stream.h ../../../ezc/src/ezc.h main.o: ../../../ezc/src/generator.h ../../../ezc/src/blocks.h main.o: ../../../ezc/src/item.h ../../../ezc/src/cache.h main.o: ../../../ezc/src/functions.h ../../../ezc/src/funinfo.h diff --git a/winixd/models/Makefile.dep b/winixd/models/Makefile.dep index f3fd18b..9e8b3b2 100644 --- a/winixd/models/Makefile.dep +++ b/winixd/models/Makefile.dep @@ -77,7 +77,8 @@ item.o: ../../../winix/winixd/core/synchro.h item.o: ../../../pikotools/src/convert/patternreplacer.h item.o: ../../../pikotools/src/convert/strtoint.h item.o: ../../../pikotools/src/convert/text.h -item.o: ../../../pikotools/src/convert/misc.h ../../../ezc/src/ezc.h +item.o: ../../../pikotools/src/convert/misc.h +item.o: ../../../pikotools/src/utf8/utf8_stream.h ../../../ezc/src/ezc.h item.o: ../../../ezc/src/generator.h ../../../ezc/src/blocks.h item.h item.o: ../../../ezc/src/cache.h ../../../ezc/src/functions.h item.o: ../../../ezc/src/funinfo.h ../../../ezc/src/objects.h @@ -215,11 +216,13 @@ itemcontent.o: ../../../winix/winixd/core/synchro.h itemcontent.o: ../../../pikotools/src/convert/patternreplacer.h itemcontent.o: ../../../pikotools/src/convert/strtoint.h itemcontent.o: ../../../pikotools/src/convert/text.h -itemcontent.o: ../../../pikotools/src/convert/misc.h ../../../ezc/src/ezc.h -itemcontent.o: ../../../ezc/src/generator.h ../../../ezc/src/blocks.h item.h -itemcontent.o: ../../../ezc/src/cache.h ../../../ezc/src/functions.h -itemcontent.o: ../../../ezc/src/funinfo.h ../../../ezc/src/objects.h -itemcontent.o: ../../../ezc/src/pattern.h ../../../ezc/src/outstreams.h +itemcontent.o: ../../../pikotools/src/convert/misc.h +itemcontent.o: ../../../pikotools/src/utf8/utf8_stream.h +itemcontent.o: ../../../ezc/src/ezc.h ../../../ezc/src/generator.h +itemcontent.o: ../../../ezc/src/blocks.h item.h ../../../ezc/src/cache.h +itemcontent.o: ../../../ezc/src/functions.h ../../../ezc/src/funinfo.h +itemcontent.o: ../../../ezc/src/objects.h ../../../ezc/src/pattern.h +itemcontent.o: ../../../ezc/src/outstreams.h itemcontent.o: ../../../ezc/src/expressionparser.h ../../../ezc/src/models.h itemcontent.o: ../../../ezc/src/patternparser.h itemcontent.o: ../../../winix/winixd/templates/htmltextstream.h @@ -345,7 +348,8 @@ user.o: ../../../winix/winixd/core/synchro.h user.o: ../../../pikotools/src/convert/patternreplacer.h user.o: ../../../pikotools/src/convert/strtoint.h user.o: ../../../pikotools/src/convert/text.h -user.o: ../../../pikotools/src/convert/misc.h ../../../ezc/src/ezc.h +user.o: ../../../pikotools/src/convert/misc.h +user.o: ../../../pikotools/src/utf8/utf8_stream.h ../../../ezc/src/ezc.h user.o: ../../../ezc/src/generator.h ../../../ezc/src/blocks.h item.h user.o: ../../../ezc/src/cache.h ../../../ezc/src/functions.h user.o: ../../../ezc/src/funinfo.h ../../../ezc/src/objects.h diff --git a/winixd/models/itemcontent.cpp b/winixd/models/itemcontent.cpp index 17aa779..6e9d2e7 100644 --- a/winixd/models/itemcontent.cpp +++ b/winixd/models/itemcontent.cpp @@ -160,17 +160,21 @@ void ItemContent::Clear() modification_user_id = -1; privileges = 0; + date_creation.Clear(); + date_modification.Clear(); + SetDateToNow(); + link_to.clear(); link_redirect = false; file_path.clear(); file_fs = -1; file_type = WINIX_ITEM_FILETYPE_NONE; + file_mime_type.clear(); file_has_thumb = false; file_hash.clear(); file_hash_type = WINIX_CRYPT_HASH_NONE; file_size = 0; - content_raw.clear(); content_raw_type = ct_formatted_text; @@ -179,8 +183,6 @@ void ItemContent::Clear() meta.clear(); admin_meta.clear(); - - SetDateToNow(); } @@ -426,7 +428,7 @@ void ItemContent::print_content(HtmlTextStream & out, const pt::WTextStream & co pt::BBCODEParser bbcode_parser; // IMPROVE ME move me to a better place std::wstring tmp_string; content.to_str(tmp_string); - bbcode_parser.Filter(tmp_string.c_str(), out_temp); + bbcode_parser.filter(tmp_string.c_str(), out_temp); out << R(out_temp); } else @@ -465,7 +467,7 @@ void ItemContent::print_content(HtmlTextStream & out, const std::wstring & conte out_temp.reserve(content.size()*2); pt::BBCODEParser bbcode_parser; // IMPROVE ME move me to a better place - bbcode_parser.Filter(content.c_str(), out_temp); + bbcode_parser.filter(content.c_str(), out_temp); out << R(out_temp); } else diff --git a/winixd/models/itemcontent.h b/winixd/models/itemcontent.h index 5fd4524..6458014 100644 --- a/winixd/models/itemcontent.h +++ b/winixd/models/itemcontent.h @@ -190,6 +190,11 @@ public: * * may it would be good to have a seperate mime_type for the thumnail? * + * IMPROVEME + * this mime type should be editable (add a 'mimetype' winix function) + * and can be return for normal items too + * can be renamed just to mime_type + * */ std::wstring file_mime_type; diff --git a/winixd/notify/Makefile.dep b/winixd/notify/Makefile.dep index 9b4e1ea..d9560e8 100644 --- a/winixd/notify/Makefile.dep +++ b/winixd/notify/Makefile.dep @@ -12,15 +12,15 @@ notify.o: ../../../pikotools/src/textstream/stream.h notify.o: ../../../pikotools/src/utf8/utf8_templates.h notify.o: ../../../pikotools/src/utf8/utf8_private.h notify.o: ../../../pikotools/src/convert/baseparser.h -notify.o: ../../../winix/winixd/core/log.h -notify.o: ../../../winix/winixd/core/logmanipulators.h -notify.o: ../../../pikotools/src/log/log.h notify.o: ../../../pikotools/src/textstream/textstream.h notify.o: ../../../pikotools/src/textstream/stream.h notify.o: ../../../pikotools/src/space/space.h notify.o: ../../../pikotools/src/date/date.h notify.o: ../../../pikotools/src/membuffer/membuffer.h notify.o: ../../../pikotools/src/textstream/types.h +notify.o: ../../../winix/winixd/core/log.h +notify.o: ../../../winix/winixd/core/logmanipulators.h +notify.o: ../../../pikotools/src/log/log.h notify.o: ../../../pikotools/src/log/filelog.h ../../../morm/src/morm.h notify.o: ../../../morm/src/morm_types.h ../../../morm/src/model.h notify.o: ../../../morm/src/modelconnector.h ../../../morm/src/clearer.h @@ -54,6 +54,7 @@ notify.o: ../../../pikotools/src/convert/patternreplacer.h notify.o: ../../../pikotools/src/convert/strtoint.h notify.o: ../../../pikotools/src/convert/text.h notify.o: ../../../pikotools/src/convert/misc.h +notify.o: ../../../pikotools/src/utf8/utf8_stream.h notify.o: ../../../winix/winixd/templates/patterns.h notify.o: ../../../winix/winixd/templates/locale.h notify.o: ../../../winix/winixd/templates/localefilter.h @@ -182,6 +183,7 @@ notifypool.o: ../../../pikotools/src/convert/patternreplacer.h notifypool.o: ../../../pikotools/src/convert/strtoint.h notifypool.o: ../../../pikotools/src/convert/text.h notifypool.o: ../../../pikotools/src/convert/misc.h +notifypool.o: ../../../pikotools/src/utf8/utf8_stream.h notifythread.o: notifythread.h ../../../winix/winixd/core/basethread.h notifythread.o: ../../../winix/winixd/core/synchro.h notifythread.o: ../../../winix/winixd/core/winixmodeldeprecated.h @@ -208,11 +210,12 @@ notifythread.o: ../../../pikotools/src/log/filelog.h notifythread.o: ../../../ezc/src/patternparser.h notifythread.o: ../../../winix/winixd/core/textstream.h notifythread.o: ../../../pikotools/src/convert/misc.h -notifythread.o: ../../../pikotools/src/convert/text.h notifypool.h +notifythread.o: ../../../pikotools/src/convert/text.h +notifythread.o: ../../../pikotools/src/textstream/types.h +notifythread.o: ../../../pikotools/src/utf8/utf8_stream.h notifypool.h notifythread.o: ../../../winix/winixd/templates/locale.h notifythread.o: ../../../pikotools/src/space/spaceparser.h notifythread.o: ../../../pikotools/src/space/space.h -notifythread.o: ../../../pikotools/src/textstream/types.h notifythread.o: ../../../pikotools/src/convert/baseparser.h notifythread.o: ../../../winix/winixd/core/winixbase.h notifythread.o: ../../../winix/winixd/core/config.h @@ -304,11 +307,12 @@ templatesnotify.o: ../../../pikotools/src/log/filelog.h templatesnotify.o: ../../../ezc/src/patternparser.h templatesnotify.o: ../../../winix/winixd/core/textstream.h templatesnotify.o: ../../../pikotools/src/convert/misc.h -templatesnotify.o: ../../../pikotools/src/convert/text.h notifypool.h +templatesnotify.o: ../../../pikotools/src/convert/text.h +templatesnotify.o: ../../../pikotools/src/textstream/types.h +templatesnotify.o: ../../../pikotools/src/utf8/utf8_stream.h notifypool.h templatesnotify.o: ../../../winix/winixd/templates/locale.h templatesnotify.o: ../../../pikotools/src/space/spaceparser.h templatesnotify.o: ../../../pikotools/src/space/space.h -templatesnotify.o: ../../../pikotools/src/textstream/types.h templatesnotify.o: ../../../pikotools/src/convert/baseparser.h templatesnotify.o: ../../../winix/winixd/core/winixbase.h templatesnotify.o: ../../../winix/winixd/core/config.h diff --git a/winixd/plugins/export/Makefile.dep b/winixd/plugins/export/Makefile.dep index 3439b66..f7c2604 100644 --- a/winixd/plugins/export/Makefile.dep +++ b/winixd/plugins/export/Makefile.dep @@ -105,9 +105,6 @@ exportinfo.o: ../../../../winix/winixd/core/config.h exportinfo.o: ../../../../pikotools/src/space/spaceparser.h exportinfo.o: ../../../../pikotools/src/space/space.h exportinfo.o: ../../../../pikotools/src/convert/baseparser.h -exportinfo.o: ../../../../winix/winixd/core/log.h -exportinfo.o: ../../../../winix/winixd/core/logmanipulators.h -exportinfo.o: ../../../../pikotools/src/log/log.h exportinfo.o: ../../../../pikotools/src/textstream/textstream.h exportinfo.o: ../../../../pikotools/src/textstream/stream.h exportinfo.o: ../../../../pikotools/src/space/space.h @@ -120,6 +117,9 @@ exportinfo.o: ../../../../pikotools/src/utf8/utf8_private.h exportinfo.o: ../../../../pikotools/src/date/date.h exportinfo.o: ../../../../pikotools/src/membuffer/membuffer.h exportinfo.o: ../../../../pikotools/src/textstream/types.h +exportinfo.o: ../../../../winix/winixd/core/log.h +exportinfo.o: ../../../../winix/winixd/core/logmanipulators.h +exportinfo.o: ../../../../pikotools/src/log/log.h exportinfo.o: ../../../../pikotools/src/log/filelog.h exportinfo.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h exportinfo.o: ../../../../morm/src/model.h diff --git a/winixd/plugins/group/Makefile.dep b/winixd/plugins/group/Makefile.dep index be4700d..f0aeaf1 100644 --- a/winixd/plugins/group/Makefile.dep +++ b/winixd/plugins/group/Makefile.dep @@ -10,6 +10,12 @@ groupinfo.o: ../../../../pikotools/src/textstream/stream.h groupinfo.o: ../../../../pikotools/src/utf8/utf8_templates.h groupinfo.o: ../../../../pikotools/src/utf8/utf8_private.h groupinfo.o: ../../../../pikotools/src/convert/baseparser.h +groupinfo.o: ../../../../pikotools/src/textstream/textstream.h +groupinfo.o: ../../../../pikotools/src/textstream/stream.h +groupinfo.o: ../../../../pikotools/src/space/space.h +groupinfo.o: ../../../../pikotools/src/date/date.h +groupinfo.o: ../../../../pikotools/src/membuffer/membuffer.h +groupinfo.o: ../../../../pikotools/src/textstream/types.h groupinfo.o: ../../../../winix/winixd/core/winixrequest.h groupinfo.o: ../../../../winix/winixd/core/winixsystem.h groupinfo.o: ../../../../winix/winixd/core/system.h @@ -22,12 +28,6 @@ groupinfo.o: ../../../../winix/winixd/core/config.h groupinfo.o: ../../../../winix/winixd/core/log.h groupinfo.o: ../../../../winix/winixd/core/logmanipulators.h groupinfo.o: ../../../../pikotools/src/log/log.h -groupinfo.o: ../../../../pikotools/src/textstream/textstream.h -groupinfo.o: ../../../../pikotools/src/textstream/stream.h -groupinfo.o: ../../../../pikotools/src/space/space.h -groupinfo.o: ../../../../pikotools/src/date/date.h -groupinfo.o: ../../../../pikotools/src/membuffer/membuffer.h -groupinfo.o: ../../../../pikotools/src/textstream/types.h groupinfo.o: ../../../../pikotools/src/log/filelog.h groupinfo.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h groupinfo.o: ../../../../morm/src/model.h @@ -76,6 +76,7 @@ groupinfo.o: ../../../../pikotools/src/convert/patternreplacer.h groupinfo.o: ../../../../pikotools/src/convert/strtoint.h groupinfo.o: ../../../../pikotools/src/convert/text.h groupinfo.o: ../../../../pikotools/src/convert/misc.h +groupinfo.o: ../../../../pikotools/src/utf8/utf8_stream.h groupinfo.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h groupinfo.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/item.h groupinfo.o: ../../../../ezc/src/cache.h ../../../../ezc/src/functions.h @@ -145,6 +146,12 @@ groups.o: ../../../../pikotools/src/textstream/stream.h groups.o: ../../../../pikotools/src/utf8/utf8_templates.h groups.o: ../../../../pikotools/src/utf8/utf8_private.h groups.o: ../../../../pikotools/src/convert/baseparser.h +groups.o: ../../../../pikotools/src/textstream/textstream.h +groups.o: ../../../../pikotools/src/textstream/stream.h +groups.o: ../../../../pikotools/src/space/space.h +groups.o: ../../../../pikotools/src/date/date.h +groups.o: ../../../../pikotools/src/membuffer/membuffer.h +groups.o: ../../../../pikotools/src/textstream/types.h groups.o: ../../../../winix/winixd/core/winixrequest.h groups.o: ../../../../winix/winixd/core/winixsystem.h groups.o: ../../../../winix/winixd/core/system.h @@ -157,12 +164,6 @@ groups.o: ../../../../winix/winixd/core/config.h groups.o: ../../../../winix/winixd/core/log.h groups.o: ../../../../winix/winixd/core/logmanipulators.h groups.o: ../../../../pikotools/src/log/log.h -groups.o: ../../../../pikotools/src/textstream/textstream.h -groups.o: ../../../../pikotools/src/textstream/stream.h -groups.o: ../../../../pikotools/src/space/space.h -groups.o: ../../../../pikotools/src/date/date.h -groups.o: ../../../../pikotools/src/membuffer/membuffer.h -groups.o: ../../../../pikotools/src/textstream/types.h groups.o: ../../../../pikotools/src/log/filelog.h ../../../../morm/src/morm.h groups.o: ../../../../morm/src/morm_types.h ../../../../morm/src/model.h groups.o: ../../../../morm/src/modelconnector.h @@ -206,12 +207,13 @@ groups.o: ../../../../winix/winixd/templates/locale.h groups.o: ../../../../pikotools/src/convert/patternreplacer.h groups.o: ../../../../pikotools/src/convert/strtoint.h groups.o: ../../../../pikotools/src/convert/text.h -groups.o: ../../../../pikotools/src/convert/misc.h ../../../../ezc/src/ezc.h -groups.o: ../../../../ezc/src/generator.h ../../../../ezc/src/blocks.h -groups.o: ../../../../ezc/src/item.h ../../../../ezc/src/cache.h -groups.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h -groups.o: ../../../../ezc/src/objects.h ../../../../ezc/src/pattern.h -groups.o: ../../../../ezc/src/outstreams.h +groups.o: ../../../../pikotools/src/convert/misc.h +groups.o: ../../../../pikotools/src/utf8/utf8_stream.h +groups.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h +groups.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/item.h +groups.o: ../../../../ezc/src/cache.h ../../../../ezc/src/functions.h +groups.o: ../../../../ezc/src/funinfo.h ../../../../ezc/src/objects.h +groups.o: ../../../../ezc/src/pattern.h ../../../../ezc/src/outstreams.h groups.o: ../../../../ezc/src/expressionparser.h ../../../../ezc/src/models.h groups.o: ../../../../ezc/src/patternparser.h groups.o: ../../../../winix/winixd/templates/htmltextstream.h @@ -337,12 +339,13 @@ init.o: ../../../../winix/winixd/templates/locale.h init.o: ../../../../pikotools/src/convert/patternreplacer.h init.o: ../../../../pikotools/src/convert/strtoint.h init.o: ../../../../pikotools/src/convert/text.h -init.o: ../../../../pikotools/src/convert/misc.h ../../../../ezc/src/ezc.h -init.o: ../../../../ezc/src/generator.h ../../../../ezc/src/blocks.h -init.o: ../../../../ezc/src/item.h ../../../../ezc/src/cache.h -init.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h -init.o: ../../../../ezc/src/objects.h ../../../../ezc/src/pattern.h -init.o: ../../../../ezc/src/outstreams.h +init.o: ../../../../pikotools/src/convert/misc.h +init.o: ../../../../pikotools/src/utf8/utf8_stream.h +init.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h +init.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/item.h +init.o: ../../../../ezc/src/cache.h ../../../../ezc/src/functions.h +init.o: ../../../../ezc/src/funinfo.h ../../../../ezc/src/objects.h +init.o: ../../../../ezc/src/pattern.h ../../../../ezc/src/outstreams.h init.o: ../../../../ezc/src/expressionparser.h ../../../../ezc/src/models.h init.o: ../../../../ezc/src/patternparser.h init.o: ../../../../winix/winixd/templates/htmltextstream.h @@ -468,12 +471,13 @@ templates.o: ../../../../pikotools/src/log/filelog.h templates.o: ../../../../ezc/src/patternparser.h templates.o: ../../../../pikotools/src/convert/misc.h templates.o: ../../../../pikotools/src/convert/text.h +templates.o: ../../../../pikotools/src/textstream/types.h +templates.o: ../../../../pikotools/src/utf8/utf8_stream.h templates.o: ../../../../winix/winixd/templates/patterncacher.h templates.o: ../../../../winix/winixd/core/winixbase.h templates.o: ../../../../winix/winixd/core/config.h templates.o: ../../../../pikotools/src/space/spaceparser.h templates.o: ../../../../pikotools/src/space/space.h -templates.o: ../../../../pikotools/src/textstream/types.h templates.o: ../../../../pikotools/src/convert/baseparser.h templates.o: ../../../../winix/winixd/core/log.h templates.o: ../../../../winix/winixd/core/logmanipulators.h diff --git a/winixd/plugins/menu/Makefile.dep b/winixd/plugins/menu/Makefile.dep index 14027b9..7475492 100644 --- a/winixd/plugins/menu/Makefile.dep +++ b/winixd/plugins/menu/Makefile.dep @@ -13,15 +13,15 @@ cache.o: ../../../../pikotools/src/textstream/stream.h cache.o: ../../../../pikotools/src/utf8/utf8_templates.h cache.o: ../../../../pikotools/src/utf8/utf8_private.h cache.o: ../../../../pikotools/src/convert/baseparser.h -cache.o: ../../../../winix/winixd/core/log.h -cache.o: ../../../../winix/winixd/core/logmanipulators.h -cache.o: ../../../../pikotools/src/log/log.h cache.o: ../../../../pikotools/src/textstream/textstream.h cache.o: ../../../../pikotools/src/textstream/stream.h cache.o: ../../../../pikotools/src/space/space.h cache.o: ../../../../pikotools/src/date/date.h cache.o: ../../../../pikotools/src/membuffer/membuffer.h cache.o: ../../../../pikotools/src/textstream/types.h +cache.o: ../../../../winix/winixd/core/log.h +cache.o: ../../../../winix/winixd/core/logmanipulators.h +cache.o: ../../../../pikotools/src/log/log.h cache.o: ../../../../pikotools/src/log/filelog.h ../../../../morm/src/morm.h cache.o: ../../../../morm/src/morm_types.h ../../../../morm/src/model.h cache.o: ../../../../morm/src/modelconnector.h ../../../../morm/src/clearer.h @@ -61,11 +61,13 @@ cache.o: ../../../../winix/winixd/core/winixbase.h cache.o: ../../../../pikotools/src/convert/patternreplacer.h cache.o: ../../../../pikotools/src/convert/strtoint.h cache.o: ../../../../pikotools/src/convert/text.h -cache.o: ../../../../pikotools/src/convert/misc.h ../../../../ezc/src/ezc.h -cache.o: ../../../../ezc/src/generator.h ../../../../ezc/src/blocks.h -cache.o: ../../../../ezc/src/item.h ../../../../ezc/src/pattern.h -cache.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h -cache.o: ../../../../ezc/src/objects.h ../../../../ezc/src/outstreams.h +cache.o: ../../../../pikotools/src/convert/misc.h +cache.o: ../../../../pikotools/src/utf8/utf8_stream.h +cache.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h +cache.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/item.h +cache.o: ../../../../ezc/src/pattern.h ../../../../ezc/src/functions.h +cache.o: ../../../../ezc/src/funinfo.h ../../../../ezc/src/objects.h +cache.o: ../../../../ezc/src/outstreams.h cache.o: ../../../../ezc/src/expressionparser.h ../../../../ezc/src/models.h cache.o: ../../../../ezc/src/patternparser.h cache.o: ../../../../winix/winixd/templates/htmltextstream.h @@ -111,15 +113,15 @@ init.o: ../../../../pikotools/src/textstream/stream.h init.o: ../../../../pikotools/src/utf8/utf8_templates.h init.o: ../../../../pikotools/src/utf8/utf8_private.h init.o: ../../../../pikotools/src/convert/baseparser.h -init.o: ../../../../winix/winixd/core/log.h -init.o: ../../../../winix/winixd/core/logmanipulators.h -init.o: ../../../../pikotools/src/log/log.h init.o: ../../../../pikotools/src/textstream/textstream.h init.o: ../../../../pikotools/src/textstream/stream.h init.o: ../../../../pikotools/src/space/space.h init.o: ../../../../pikotools/src/date/date.h init.o: ../../../../pikotools/src/membuffer/membuffer.h init.o: ../../../../pikotools/src/textstream/types.h +init.o: ../../../../winix/winixd/core/log.h +init.o: ../../../../winix/winixd/core/logmanipulators.h +init.o: ../../../../pikotools/src/log/log.h init.o: ../../../../pikotools/src/log/filelog.h ../../../../morm/src/morm.h init.o: ../../../../morm/src/morm_types.h ../../../../morm/src/model.h init.o: ../../../../morm/src/modelconnector.h ../../../../morm/src/clearer.h @@ -158,11 +160,13 @@ init.o: ../../../../winix/winixd/core/winixbase.h init.o: ../../../../pikotools/src/convert/patternreplacer.h init.o: ../../../../pikotools/src/convert/strtoint.h init.o: ../../../../pikotools/src/convert/text.h -init.o: ../../../../pikotools/src/convert/misc.h ../../../../ezc/src/ezc.h -init.o: ../../../../ezc/src/generator.h ../../../../ezc/src/blocks.h -init.o: ../../../../ezc/src/item.h ../../../../ezc/src/pattern.h -init.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h -init.o: ../../../../ezc/src/objects.h ../../../../ezc/src/outstreams.h +init.o: ../../../../pikotools/src/convert/misc.h +init.o: ../../../../pikotools/src/utf8/utf8_stream.h +init.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h +init.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/item.h +init.o: ../../../../ezc/src/pattern.h ../../../../ezc/src/functions.h +init.o: ../../../../ezc/src/funinfo.h ../../../../ezc/src/objects.h +init.o: ../../../../ezc/src/outstreams.h init.o: ../../../../ezc/src/expressionparser.h ../../../../ezc/src/models.h init.o: ../../../../ezc/src/patternparser.h init.o: ../../../../winix/winixd/templates/htmltextstream.h @@ -295,15 +299,15 @@ templates.o: ../../../../pikotools/src/textstream/stream.h templates.o: ../../../../pikotools/src/utf8/utf8_templates.h templates.o: ../../../../pikotools/src/utf8/utf8_private.h templates.o: ../../../../pikotools/src/convert/baseparser.h -templates.o: ../../../../winix/winixd/core/log.h -templates.o: ../../../../winix/winixd/core/logmanipulators.h -templates.o: ../../../../pikotools/src/log/log.h templates.o: ../../../../pikotools/src/textstream/textstream.h templates.o: ../../../../pikotools/src/textstream/stream.h templates.o: ../../../../pikotools/src/space/space.h templates.o: ../../../../pikotools/src/date/date.h templates.o: ../../../../pikotools/src/membuffer/membuffer.h templates.o: ../../../../pikotools/src/textstream/types.h +templates.o: ../../../../winix/winixd/core/log.h +templates.o: ../../../../winix/winixd/core/logmanipulators.h +templates.o: ../../../../pikotools/src/log/log.h templates.o: ../../../../pikotools/src/log/filelog.h templates.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h templates.o: ../../../../morm/src/model.h @@ -348,6 +352,7 @@ templates.o: ../../../../pikotools/src/convert/patternreplacer.h templates.o: ../../../../pikotools/src/convert/strtoint.h templates.o: ../../../../pikotools/src/convert/text.h templates.o: ../../../../pikotools/src/convert/misc.h +templates.o: ../../../../pikotools/src/utf8/utf8_stream.h templates.o: ../../../../winix/winixd/templates/htmltextstream.h templates.o: ../../../../ezc/src/funinfo.h ../../../../winix/winixd/db/db.h templates.o: ../../../../winix/winixd/db/dbbase.h diff --git a/winixd/plugins/stats/Makefile.dep b/winixd/plugins/stats/Makefile.dep index a94e574..026c9b5 100644 --- a/winixd/plugins/stats/Makefile.dep +++ b/winixd/plugins/stats/Makefile.dep @@ -59,12 +59,13 @@ init.o: ../../../../winix/winixd/core/synchro.h init.o: ../../../../pikotools/src/convert/patternreplacer.h init.o: ../../../../pikotools/src/convert/strtoint.h init.o: ../../../../pikotools/src/convert/text.h -init.o: ../../../../pikotools/src/convert/misc.h ../../../../ezc/src/ezc.h -init.o: ../../../../ezc/src/generator.h ../../../../ezc/src/blocks.h -init.o: ../../../../ezc/src/item.h ../../../../ezc/src/cache.h -init.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h -init.o: ../../../../ezc/src/objects.h ../../../../ezc/src/pattern.h -init.o: ../../../../ezc/src/outstreams.h +init.o: ../../../../pikotools/src/convert/misc.h +init.o: ../../../../pikotools/src/utf8/utf8_stream.h +init.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h +init.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/item.h +init.o: ../../../../ezc/src/cache.h ../../../../ezc/src/functions.h +init.o: ../../../../ezc/src/funinfo.h ../../../../ezc/src/objects.h +init.o: ../../../../ezc/src/pattern.h ../../../../ezc/src/outstreams.h init.o: ../../../../ezc/src/expressionparser.h ../../../../ezc/src/models.h init.o: ../../../../ezc/src/patternparser.h init.o: ../../../../winix/winixd/templates/htmltextstream.h @@ -99,8 +100,6 @@ stats.o: stats.h ../../../../winix/winixd/core/config.h stats.o: ../../../../pikotools/src/space/spaceparser.h stats.o: ../../../../pikotools/src/space/space.h stats.o: ../../../../pikotools/src/convert/baseparser.h -stats.o: ../../../../winix/winixd/core/log.h -stats.o: ../../../../pikotools/src/log/filelog.h stats.o: ../../../../pikotools/src/textstream/textstream.h stats.o: ../../../../pikotools/src/textstream/stream.h stats.o: ../../../../pikotools/src/space/space.h @@ -113,6 +112,8 @@ stats.o: ../../../../pikotools/src/utf8/utf8_private.h stats.o: ../../../../pikotools/src/date/date.h stats.o: ../../../../pikotools/src/membuffer/membuffer.h stats.o: ../../../../pikotools/src/textstream/types.h +stats.o: ../../../../winix/winixd/core/log.h +stats.o: ../../../../pikotools/src/log/filelog.h stats.o: ../../../../winix/winixd/core/winixmodeldeprecated.h stats.o: ../../../../winix/winixd/core/winixbase.h stats.o: ../../../../winix/winixd/core/log.h @@ -178,6 +179,7 @@ templates.o: ../../../../pikotools/src/convert/patternreplacer.h templates.o: ../../../../pikotools/src/convert/strtoint.h templates.o: ../../../../pikotools/src/convert/text.h templates.o: ../../../../pikotools/src/convert/misc.h +templates.o: ../../../../pikotools/src/utf8/utf8_stream.h templates.o: ../../../../pikotools/src/convert/double.h stats.h templates.o: ../../../../winix/winixd/core/config.h templates.o: ../../../../pikotools/src/space/spaceparser.h diff --git a/winixd/plugins/thread/Makefile.dep b/winixd/plugins/thread/Makefile.dep index bb71d38..566a4ec 100644 --- a/winixd/plugins/thread/Makefile.dep +++ b/winixd/plugins/thread/Makefile.dep @@ -935,9 +935,6 @@ templates.o: ../../../../winix/winixd/core/config.h templates.o: ../../../../pikotools/src/space/spaceparser.h templates.o: ../../../../pikotools/src/space/space.h templates.o: ../../../../pikotools/src/convert/baseparser.h -templates.o: ../../../../winix/winixd/core/log.h -templates.o: ../../../../winix/winixd/core/logmanipulators.h -templates.o: ../../../../pikotools/src/log/log.h templates.o: ../../../../pikotools/src/textstream/textstream.h templates.o: ../../../../pikotools/src/textstream/stream.h templates.o: ../../../../pikotools/src/space/space.h @@ -950,6 +947,9 @@ templates.o: ../../../../pikotools/src/utf8/utf8_private.h templates.o: ../../../../pikotools/src/date/date.h templates.o: ../../../../pikotools/src/membuffer/membuffer.h templates.o: ../../../../pikotools/src/textstream/types.h +templates.o: ../../../../winix/winixd/core/log.h +templates.o: ../../../../winix/winixd/core/logmanipulators.h +templates.o: ../../../../pikotools/src/log/log.h templates.o: ../../../../pikotools/src/log/filelog.h templates.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h templates.o: ../../../../morm/src/model.h @@ -1233,9 +1233,6 @@ threadinfo.o: ../../../../winix/winixd/core/config.h threadinfo.o: ../../../../pikotools/src/space/spaceparser.h threadinfo.o: ../../../../pikotools/src/space/space.h threadinfo.o: ../../../../pikotools/src/convert/baseparser.h -threadinfo.o: ../../../../winix/winixd/core/log.h -threadinfo.o: ../../../../winix/winixd/core/logmanipulators.h -threadinfo.o: ../../../../pikotools/src/log/log.h threadinfo.o: ../../../../pikotools/src/textstream/textstream.h threadinfo.o: ../../../../pikotools/src/textstream/stream.h threadinfo.o: ../../../../pikotools/src/space/space.h @@ -1248,6 +1245,9 @@ threadinfo.o: ../../../../pikotools/src/utf8/utf8_private.h threadinfo.o: ../../../../pikotools/src/date/date.h threadinfo.o: ../../../../pikotools/src/membuffer/membuffer.h threadinfo.o: ../../../../pikotools/src/textstream/types.h +threadinfo.o: ../../../../winix/winixd/core/log.h +threadinfo.o: ../../../../winix/winixd/core/logmanipulators.h +threadinfo.o: ../../../../pikotools/src/log/log.h threadinfo.o: ../../../../pikotools/src/log/filelog.h threadinfo.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h threadinfo.o: ../../../../morm/src/model.h diff --git a/winixd/plugins/ticket/Makefile.dep b/winixd/plugins/ticket/Makefile.dep index 8b73271..de6f343 100644 --- a/winixd/plugins/ticket/Makefile.dep +++ b/winixd/plugins/ticket/Makefile.dep @@ -1244,9 +1244,6 @@ ticketinfo.o: ../../../../winix/winixd/core/config.h ticketinfo.o: ../../../../pikotools/src/space/spaceparser.h ticketinfo.o: ../../../../pikotools/src/space/space.h ticketinfo.o: ../../../../pikotools/src/convert/baseparser.h -ticketinfo.o: ../../../../winix/winixd/core/log.h -ticketinfo.o: ../../../../winix/winixd/core/logmanipulators.h -ticketinfo.o: ../../../../pikotools/src/log/log.h ticketinfo.o: ../../../../pikotools/src/textstream/textstream.h ticketinfo.o: ../../../../pikotools/src/textstream/stream.h ticketinfo.o: ../../../../pikotools/src/space/space.h @@ -1259,6 +1256,9 @@ ticketinfo.o: ../../../../pikotools/src/utf8/utf8_private.h ticketinfo.o: ../../../../pikotools/src/date/date.h ticketinfo.o: ../../../../pikotools/src/membuffer/membuffer.h ticketinfo.o: ../../../../pikotools/src/textstream/types.h +ticketinfo.o: ../../../../winix/winixd/core/log.h +ticketinfo.o: ../../../../winix/winixd/core/logmanipulators.h +ticketinfo.o: ../../../../pikotools/src/log/log.h ticketinfo.o: ../../../../pikotools/src/log/filelog.h ticketinfo.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h ticketinfo.o: ../../../../morm/src/model.h