[Kde-pim] Review Request 122811: Coding Style for collectionstatistics.cpp collectionstatistics.h datastore.cpp dbinitializer.cpp dbinitializer_p.cpp entity.h itemretrievalmanager.cpp parttypehelper.cpp query.cpp query.h querybuilder.cpp schematypes.cpp storagedebugger.h

Daniel Vrátil dvratil at redhat.com
Wed Mar 18 11:32:38 GMT 2015



> On March 16, 2015, 12:35 p.m., Daniel Vrátil wrote:
> > > As introduced 5 august 2013, we put (almost) all the commands and options strings in ONE file private/protocol_p.h
> > > Should it be wise to do the same here?
> > 
> > What specific parts are you referring to?
> 
> Guy Maurel wrote:
>     such as
>     kdesupport/akonadi/src/server/storage/dbinitializer.cpp :298, :327, :344, 381 ...
>     and
>     kdesupport/akonadi/src/server/storage/querybuilder.cpp :38, :80, :205, :230 ...
>     and some more SQL-command parts

Ah, I see now. 

I don't think we need to have the SQL parts as macros. The SQL is well-defined and due to the way the queries are composed in Akonadi it would make the queries grossly unreadable.

The reason we did it for the protocol is that the strings are shared between the server and the client libraries and we were the ones "defining" the keywords, which is not the case of SQL.


- Daniel


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/122811/#review77569
-----------------------------------------------------------


On March 4, 2015, 5:13 p.m., Guy Maurel wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/122811/
> -----------------------------------------------------------
> 
> (Updated March 4, 2015, 5:13 p.m.)
> 
> 
> Review request for Akonadi, Daniel Vrátil and Sergio Luis Martins.
> 
> 
> Repository: akonadi
> 
> 
> Description
> -------
> 
> Details can be seen at:
>   http://techbase.kde.org/Policies/Kdepim_Coding_Style
> 
> As introduced 5 august 2013, we put (almost) all the commands and options strings in ONE file private/protocol_p.h
> Should it be wise to do the same here?
> 
> 
> Diffs
> -----
> 
>   src/server/storage/collectionstatistics.h a0b9f24 
>   src/server/storage/collectionstatistics.cpp def1235ebb8756b56477dbade49565d6a2b405ef 
>   src/server/storage/datastore.cpp c2f34d1 
>   src/server/storage/dbinitializer.cpp ce61856 
>   src/server/storage/dbinitializer_p.cpp 6c8e56d 
>   src/server/storage/entity.h fab6c58 
>   src/server/storage/itemretrievalmanager.cpp 81f1d0714d8a81d49436007539bcabae8cc0f388 
>   src/server/storage/parttypehelper.cpp 1363995 
>   src/server/storage/query.h fd4c589 
>   src/server/storage/query.cpp 6873ec9 
>   src/server/storage/querybuilder.cpp bca292ec0a345c884ba609d18ec205c1ae6d8f7d 
>   src/server/storage/schematypes.cpp 61a0fcf 
>   src/server/storage/storagedebugger.h de1ba31 
> 
> Diff: https://git.reviewboard.kde.org/r/122811/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Guy Maurel
> 
>

_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list