return std::string("AlienPiece");
}
-AlienPart::AlienPart(Store * const _store): store(_store) {}
+std::string AlienPiece::toPlainText() {
+ return std::string();
+}
+
+AlienPart::AlienPart(Store * const store): d_store(store) {}
std::string AlienPart::toString() {
- return store->toString();
+ if (d_store != 0)
+ return d_store->toString();
+ else
+ return "NULL";
+}
+
+std::string AlienPart::toPlainText() {
+ if (d_store != 0)
+ return d_store->toPlainText();
+ else
+ return std::string();
}
Alien::Alien(INTEGER id, const TypePath &path): Store(id), d_path(path), d_comps() {}
return sofar + "}";
}
+std::string Alien::toPlainText() {
+ std::string sofar = std::string();
+ for (int i = 0; i < d_comps.size(); ++i) {
+ sofar += d_comps[i]->toPlainText();
+ }
+ return sofar;
+}
+
}