summaryrefslogtreecommitdiff
path: root/cpp/demo/Ice/value/ServantFactory.cpp
diff options
context:
space:
mode:
authorMarc Laukien <marc@zeroc.com>2001-09-17 04:03:25 +0000
committerMarc Laukien <marc@zeroc.com>2001-09-17 04:03:25 +0000
commitb12f3c9681c7b264fda86c7bacdcf01f5880b359 (patch)
tree8c74062b8f4cc2ec78e4b4384956d7ed35210c66 /cpp/demo/Ice/value/ServantFactory.cpp
parentfixes, fixes, fixes.. (diff)
downloadice-b12f3c9681c7b264fda86c7bacdcf01f5880b359.tar.bz2
ice-b12f3c9681c7b264fda86c7bacdcf01f5880b359.tar.xz
ice-b12f3c9681c7b264fda86c7bacdcf01f5880b359.zip
more fixes
Diffstat (limited to 'cpp/demo/Ice/value/ServantFactory.cpp')
-rw-r--r--cpp/demo/Ice/value/ServantFactory.cpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/cpp/demo/Ice/value/ServantFactory.cpp b/cpp/demo/Ice/value/ServantFactory.cpp
new file mode 100644
index 00000000000..a94b94dec81
--- /dev/null
+++ b/cpp/demo/Ice/value/ServantFactory.cpp
@@ -0,0 +1,28 @@
+// **********************************************************************
+//
+// Copyright (c) 2001
+// MutableRealms, Inc.
+// Huntsville, AL, USA
+//
+// All Rights Reserved
+//
+// **********************************************************************
+
+#include <Ice/Ice.h>
+#include <Factory.h>
+#include <ValueI.h>
+
+using namespace std;
+
+Ice::ObjectPtr
+Factory::create(const string& id)
+{
+ if (id == "::Printer")
+ return new PrinterI;
+
+ if (id == "::DerivedPrinter")
+ return new DerivedPrinterI;
+
+ assert(false);
+ return 0;
+}