Commit 93efc5b5 authored by Carlos Eduardo Lara Augusto's avatar Carlos Eduardo Lara Augusto
Browse files

[SCS-230]

- Adição de descrições que estavam faltando no JavaDoc do ComponentContext.
- Correção em comentário da demo StockMarket.



git-svn-id: https://subversion.tecgraf.puc-rio.br/engdist/scs/core/java/trunk@120307 ae0415b3-e90b-0410-900d-d0be9363c56b
parent 6f644efb
......@@ -22,8 +22,8 @@ public class StockSellerContext extends ComponentContext {
/**
* Constructor.
*
* @param builder A builder associated with the ORB and POA used to create the
* servants
* @param orb The ORB.
* @param poa The POA.
* @param id This component's ComponentId
* @throws IOException
* @throws SCSException
......
......@@ -27,8 +27,17 @@ import scs.core.exception.SCSException;
*
*/
public class ComponentContext {
/**
* Name used for the IComponent facet.
*/
public static final String ICOMPONENT_FACET_NAME = "IComponent";
/**
* Name used for the IReceptacles facet.
*/
public static final String IRECEPTACLES_FACET_NAME = "IReceptacles";
/**
* Name used for the IMetaInterface facet.
*/
public static final String IMETAINTERFACE_FACET_NAME = "IMetaInterface";
private ORB orb;
......@@ -133,6 +142,14 @@ public class ComponentContext {
facets.put(name, facet);
}
/**
* Changes the servant of a facet. This method deactivates the old servant and
* activates the new one. The facet remains with the same name and interface.
*
* @param name The existent facet's name.
* @param servant The new servant, not yet activated within the POA.
* @throws SCSException If an UserException is catched.
*/
public void updateFacet(String name, Servant servant) throws SCSException {
Facet facet = this.facets.get(name);
if (facet == null) {
......
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