X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Floader%2FTypeDescription.cpp;h=19974fb52cced072a31509df6453cf84117f46d6;hb=1970312e983541d32d4ff73c81b8d90156a7bb99;hp=bcc480c6af6659ef6241c14bcf97a59ee01a68ad;hpb=1907ca03c5e865c4d398170042aa384c67ffff29;p=l2e.git diff --git a/src/loader/TypeDescription.cpp b/src/loader/TypeDescription.cpp index bcc480c..19974fb 100644 --- a/src/loader/TypeDescription.cpp +++ b/src/loader/TypeDescription.cpp @@ -1,10 +1,3 @@ -/* - * TypeDescription.cpp - * - * Created on: Sep 4, 2012 - * Author: holy - */ - #include "TypeDescription.h" #include @@ -114,6 +107,20 @@ const TypeDescription &TypeDescription::Get(int id) { } +int TypeDescription::GetMaxSize() { + int max = 0; + for (map::const_iterator + i(typeDescriptions.begin()), + end(typeDescriptions.end()); + i != end; ++i) { + if (i->second.Size() > max) { + max = i->second.Size(); + } + } + return max; +} + + void TypeDescription::WriteSourceWiki(std::ostream &out) { vector types; for (map::const_iterator i(typeDescriptions.begin()), end(typeDescriptions.end()); i != end; ++i) { @@ -134,6 +141,8 @@ void TypeDescription::WriteSourceWiki(std::ostream &out) { const TypeDescription &td(Get(GetTypeId(*i))); out << "h3. " << td.TypeName() << endl << endl; + out << "Type ID: @" << td.TypeId() << "@" << endl << endl; + if (td.Description()) { out << td.Description() << endl << endl; }