summaryrefslogtreecommitdiffstats
path: root/umbrello/umbrello/codegenerators/cppsourcecodeclassfielddeclarationblock.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'umbrello/umbrello/codegenerators/cppsourcecodeclassfielddeclarationblock.cpp')
-rw-r--r--umbrello/umbrello/codegenerators/cppsourcecodeclassfielddeclarationblock.cpp74
1 files changed, 74 insertions, 0 deletions
diff --git a/umbrello/umbrello/codegenerators/cppsourcecodeclassfielddeclarationblock.cpp b/umbrello/umbrello/codegenerators/cppsourcecodeclassfielddeclarationblock.cpp
new file mode 100644
index 00000000..7d60b1c3
--- /dev/null
+++ b/umbrello/umbrello/codegenerators/cppsourcecodeclassfielddeclarationblock.cpp
@@ -0,0 +1,74 @@
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+/* This code generated by:
+ * Author : thomas
+ * Date : Mon Sep 1 2003
+ */
+
+#include "cppsourcecodeclassfielddeclarationblock.h"
+
+#include "cppcodeclassfield.h"
+#include "../model_utils.h"
+
+// Constructors/Destructors
+//
+
+CPPSourceCodeClassFieldDeclarationBlock::CPPSourceCodeClassFieldDeclarationBlock ( CodeClassField * parent )
+ : CodeClassFieldDeclarationBlock ( parent )
+{
+ setOverallIndentationLevel(1);
+ updateContent();
+}
+
+CPPSourceCodeClassFieldDeclarationBlock::~CPPSourceCodeClassFieldDeclarationBlock ( ) { }
+
+//
+// Methods
+//
+
+// Other methods
+//
+
+/**
+ */
+void CPPSourceCodeClassFieldDeclarationBlock::updateContent( )
+{
+
+ /*
+ CodeClassField * cf = getParentClassField();
+ ClassifierCodeDocument * doc = cf->getParentDocument();
+ CPPCodeClassField * jcf = dynamic_cast<CPPCodeClassField*>(cf);
+ CPPClassifierCodeDocument* jdoc = dynamic_cast<CPPClassifierCodeDocument*>(doc);
+
+ // Set the comment
+ QString notes = getParentObject()->getDoc();
+ getComment()->setText(notes);
+
+ // Set the body
+ QString staticValue = getParentObject()->getStatic() ? "static " : "";
+ QString scopeStr = getParentObject()->getVisibility().toString();
+
+ QString typeName = jcf->getTypeName();
+ QString fieldName = jcf->getFieldName();
+ QString initialV = jcf->getInitialValue();
+
+ QString body = staticValue+scopeStr+" "+typeName+" "+fieldName;
+ if (!initialV.isEmpty())
+ body.append(" = " + initialV);
+ setText(body+";");
+ */
+ setText("FIX ME;");
+
+
+}
+
+
+
+#include "cppsourcecodeclassfielddeclarationblock.moc"