Commit 036a96ed authored by Carlos Eduardo Lara Augusto's avatar Carlos Eduardo Lara Augusto
Browse files

[SCS-230]

Modificação nas demos para usar addFacet/updateFacet no lugar de putFacet e addReceptacle no lugar de putReceptacle.



git-svn-id: https://subversion.tecgraf.puc-rio.br/engdist/scs/core/java/trunk@119807 ae0415b3-e90b-0410-900d-d0be9363c56b
parent 28241c76
......@@ -37,7 +37,7 @@ public class BasicServerApp {
ComponentContext component = new ComponentContext(orb, poa, cpId);
// adio das facetas
component.putFacet(FACET_HELLO, HelloHelper.id(), new HelloServant(
component.addFacet(FACET_HELLO, HelloHelper.id(), new HelloServant(
component));
// modificao do nome a ser exibido na mensagem da faceta Hello
......
......@@ -18,7 +18,6 @@ import org.omg.PortableServer.POAPackage.WrongPolicy;
import scs.core.ComponentId;
import scs.core.IComponent;
import scs.core.IComponentHelper;
import scs.core.exception.SCSException;
import scs.demos.stockmarket.servant.StockExchangeImpl;
import scs.demos.stockmarket.servant.StockSellerIComponentImpl;
......@@ -82,14 +81,14 @@ public class StockSellerServer {
try {
component = new StockSellerContext(orb, poa, cpId);
component.putFacet(IComponent.class.getSimpleName(), IComponentHelper
.id(), new StockSellerIComponentImpl(component));
component.putFacet(StockServer.class.getSimpleName(), StockServerHelper
component.updateFacet(IComponent.class.getSimpleName(),
new StockSellerIComponentImpl(component));
component.addFacet(StockServer.class.getSimpleName(), StockServerHelper
.id(), new StockServerImpl(component));
component.putFacet(StockExchange.class.getSimpleName(),
component.addFacet(StockExchange.class.getSimpleName(),
StockExchangeHelper.id(), new StockExchangeImpl(component));
component.putReceptacle(ExchangePrinter.class.getSimpleName(),
component.addReceptacle(ExchangePrinter.class.getSimpleName(),
ExchangePrinterHelper.id(), true);
// Writes the reference of the IComponent facet to a file
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment