Java 类java.rmi.activation.ActivationGroupID 实例源码

项目:OpenJSharp    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:OpenJSharp    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:jdk8u-jdk    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:jdk8u-jdk    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:openjdk-jdk10    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:openjdk-jdk10    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:openjdk9    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:openjdk9    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:jdk8u_jdk    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:jdk8u_jdk    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:lookaside_java-1.8.0-openjdk    文件:Activation.java   
public ActivationGroupID registerGroup(ActivationGroupDesc desc)
    throws ActivationException, RemoteException
{
    Thread.dumpStack();
    checkShutdown();
    // RegistryImpl.checkAccess() is done in the SameHostOnlyServerRef
    // during unmarshallCustomData and is not applicable to local access.
    checkArgs(desc, null);

    ActivationGroupID id = new ActivationGroupID(systemStub);
    GroupEntry entry = new GroupEntry(id, desc);
    // table insertion must take place before log update
    groupTable.put(id, entry);
    addLogRecord(new LogRegisterGroup(id, desc));
    return id;
}
项目:lookaside_java-1.8.0-openjdk    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:lookaside_java-1.8.0-openjdk    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:infobip-open-jdk-8    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:infobip-open-jdk-8    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:jdk8u-dev-jdk    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:jdk8u-dev-jdk    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:jdk7-jdk    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:jdk7-jdk    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:openjdk-source-code-learn    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:OLD-OpenJDK8    文件:Activation.java   
/**
 * Returns the group entry for the group id, optionally removing it.
 * Throws UnknownGroupException if the group is not registered.
 */
private GroupEntry getGroupEntry(ActivationGroupID id, boolean rm)
    throws UnknownGroupException
{
    if (id.getClass() == ActivationGroupID.class) {
        GroupEntry entry;
        if (rm) {
            entry = groupTable.remove(id);
        } else {
            entry = groupTable.get(id);
        }
        if (entry != null && !entry.removed) {
            return entry;
        }
    }
    throw new UnknownGroupException("group unknown");
}
项目:OLD-OpenJDK8    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:cn1    文件:Rmid.java   
public ActivationGroupID registerGroup(ActivationGroupDesc agdesc)
        throws ActivationException {
    waitStartup();
    ActivationGroupID agid = new ActivationGroupID(this);
    ActivationGroupInfo agi = new ActivationGroupInfo(agid, agdesc);
    if (groupInfoByGroupId.containsKey(agid)) {
        // rmi.2E=This group is already registered.
        throw new ActivationException(Messages.getString("rmi.2E")); //$NON-NLS-1$
    }
    groupInfoByGroupId.put(agid, agi);
    if (!restoreLock) {
        writeDelta(Delta.PUT, "group", agid, agdesc); //$NON-NLS-1$
        // rmi.log.45=Delta was saved:
        rLog.log(persistenceDebugLevel, Messages.getString("rmi.log.45") //$NON-NLS-1$
                + Delta.PUT + "," + "group" + ", " + agid + ", " //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
                + agdesc);
    }

    return agid;
}
项目:openjdk-jdk7u-jdk    文件:ActivationGroupImpl.java   
/**
 * Creates a default activation group implementation.
 *
 * @param id the group's identifier
 * @param data ignored
 */
public ActivationGroupImpl(ActivationGroupID id, MarshalledObject<?> data)
    throws RemoteException
{
    super(id);
    groupID = id;

    /*
     * Unexport activation group impl and attempt to export it on
     * an unshared anonymous port.  See 4692286.
     */
    unexportObject(this, true);
    RMIServerSocketFactory ssf = new ServerSocketFactoryImpl();
    UnicastRemoteObject.exportObject(this, 0, null, ssf);

    if (System.getSecurityManager() == null) {
        try {
            // Provide a default security manager.
            System.setSecurityManager(new SecurityManager());

        } catch (Exception e) {
            throw new RemoteException("unable to set security manager", e);
        }
    }
}
项目:cn1    文件:Rmid.java   
/**
 * This method is absent in Java Remote Method Invocation
 * specification.
 *
 * @param aID
 * @throws UnknownObjectException  if <code>ActivationID</code>
 * is not registered
 * @throws ActivationException  for general failure
 * @throws RemoteException  if remote call fails
 */
public ActivationDesc getActivationDesc(ActivationID aID)
        throws UnknownObjectException {
    waitStartup();
    ActivationGroupID agid = (ActivationGroupID) groupIDByActivationID
            .get(aID);
    ActivationGroupInfo info = (ActivationGroupInfo) groupInfoByGroupId
            .get(agid);
    ActivationDesc adesc = info.getActivationDesc(aID);

    if (adesc == null) {
        // rmi.31=No ActivationDesc for ActivationID {0}
        throw new UnknownObjectException(Messages.getString("rmi.31", aID)); //$NON-NLS-1$
    }
    return adesc;
}
项目:cn1    文件:Rmid.java   
public ActivationID registerObject(ActivationDesc adesc) {
    waitStartup();
    // rmi.log.4B=ActivationSystemImpl.registerObject():
    rLog.log(commonDebugLevel,Messages.getString("rmi.log.4B")); //$NON-NLS-1$
    ActivationGroupID agid = adesc.getGroupID();
    // rmi.log.4C=agid : {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.4C", agid)); //$NON-NLS-1$
    // rmi.log.4D=Activator stub = {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.4D", thisStub)); //$NON-NLS-1$
    ActivationID aid = new ActivationID((Activator) thisStub);
    // rmi.log.4E=aid : {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.4E", aid)); //$NON-NLS-1$
    // rmi.log.4C=agid : {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.4C", agid)); //$NON-NLS-1$

    ActivationGroupInfo info = (ActivationGroupInfo) groupInfoByGroupId
            .get(agid);
    // rmi.log.50=ActivationGroupInfo = {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.50", info)); //$NON-NLS-1$

    info.registerObject(aid, adesc);
    // rmi.log.51=Activation desc was added.
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.51")); //$NON-NLS-1$
    return aid;

}
项目:cn1    文件:Rmid.java   
public MarshalledObject activate(ActivationID id, boolean force)
        throws ActivationException, UnknownObjectException,
        RemoteException {
    waitStartup();
    // rmi.log.5B=ActivatorImpl.activate({0}; {1})
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.5B", //$NON-NLS-1$
            id, force));

    ActivationGroupID agid = (ActivationGroupID) groupIDByActivationID
            .get(id);
    // rmi.log.57=agid = {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.57", agid)); //$NON-NLS-1$
    ActivationGroupInfo info = (ActivationGroupInfo) groupInfoByGroupId
            .get(agid);
    // rmi.log.5C=info = {0}
    rLog.log(commonDebugLevel, Messages.getString("rmi.log.5C", info)); //$NON-NLS-1$

    return info.activateObject(id, force);
}
项目:OpenJSharp    文件:ActivationGroupInit.java   
/**
 * Main program to start a VM for an activation group.
 */
public static void main(String args[])
{
    try {
        if (System.getSecurityManager() == null) {
            System.setSecurityManager(new SecurityManager());
        }
        // read group id, descriptor, and incarnation number from stdin
        MarshalInputStream in = new MarshalInputStream(System.in);
        ActivationGroupID id  = (ActivationGroupID)in.readObject();
        ActivationGroupDesc desc = (ActivationGroupDesc)in.readObject();
        long incarnation = in.readLong();

        // create and set group for the VM
        ActivationGroup.createGroup(id, desc, incarnation);
    } catch (Exception e) {
        System.err.println("Exception in starting ActivationGroupInit:");
        e.printStackTrace();
    } finally {
        try {
            System.in.close();
            // note: system out/err shouldn't be closed
            // since the parent may want to read them.
        } catch (Exception ex) {
            // ignore exceptions
        }
    }
}
项目:OpenJSharp    文件:Activation.java   
public void inactiveGroup(ActivationGroupID id,
                          long incarnation)
    throws UnknownGroupException, RemoteException
{
    try {
        checkShutdown();
    } catch (ActivationException e) {
        return;
    }
    RegistryImpl.checkAccess("ActivationMonitor.inactiveGroup");
    getGroupEntry(id).inactiveGroup(incarnation, false);
}
项目:OpenJSharp    文件:Activation.java   
public ActivationID registerObject(ActivationDesc desc)
    throws ActivationException, UnknownGroupException, RemoteException
{
    checkShutdown();
    RegistryImpl.checkAccess("ActivationSystem.registerObject");

    ActivationGroupID groupID = desc.getGroupID();
    ActivationID id = new ActivationID(activatorStub);
    getGroupEntry(groupID).registerObject(id, desc, true);
    return id;
}
项目:OpenJSharp    文件:Activation.java   
public ActivationGroupID registerGroup(ActivationGroupDesc desc)
    throws ActivationException, RemoteException
{
    checkShutdown();
    RegistryImpl.checkAccess("ActivationSystem.registerGroup");
    checkArgs(desc, null);

    ActivationGroupID id = new ActivationGroupID(systemStub);
    GroupEntry entry = new GroupEntry(id, desc);
    // table insertion must take place before log update
    groupTable.put(id, entry);
    addLogRecord(new LogRegisterGroup(id, desc));
    return id;
}
项目:OpenJSharp    文件:Activation.java   
public ActivationMonitor activeGroup(ActivationGroupID id,
                                     ActivationInstantiator group,
                                     long incarnation)
    throws ActivationException, UnknownGroupException, RemoteException
{
    checkShutdown();
    RegistryImpl.checkAccess("ActivationSystem.activeGroup");

    getGroupEntry(id).activeGroup(group, incarnation);
    return monitor;
}
项目:OpenJSharp    文件:Activation.java   
public void unregisterGroup(ActivationGroupID id)
    throws ActivationException, UnknownGroupException, RemoteException
{
    checkShutdown();
    RegistryImpl.checkAccess("ActivationSystem.unregisterGroup");

    // remove entry before unregister so state is updated before
    // logged
    removeGroupEntry(id).unregisterGroup(true);
}
项目:OpenJSharp    文件:Activation.java   
public ActivationGroupDesc setActivationGroupDesc(ActivationGroupID id,
                                                  ActivationGroupDesc desc)
    throws ActivationException, UnknownGroupException, RemoteException
{
    checkShutdown();
    RegistryImpl.checkAccess(
        "ActivationSystem.setActivationGroupDesc");

    checkArgs(desc, null);
    return getGroupEntry(id).setActivationGroupDesc(id, desc, true);
}
项目:OpenJSharp    文件:Activation.java   
public ActivationGroupDesc getActivationGroupDesc(ActivationGroupID id)
    throws ActivationException, UnknownGroupException, RemoteException
{
    checkShutdown();
    RegistryImpl.checkAccess
        ("ActivationSystem.getActivationGroupDesc");

    return getGroupEntry(id).desc;
}
项目:OpenJSharp    文件:Activation.java   
/**
 * Returns the groupID for a given id of an object in the group.
 * Throws UnknownObjectException if the object is not registered.
 */
private ActivationGroupID getGroupID(ActivationID id)
    throws UnknownObjectException
{
    ActivationGroupID groupID = idTable.get(id);
    if (groupID != null) {
        return groupID;
    }
    throw new UnknownObjectException("unknown object: " + id);
}
项目:OpenJSharp    文件:Activation.java   
/**
 * Returns the group entry for the object's id. Throws
 * UnknownObjectException if the object is not registered or the
 * object's group is not registered.
 */
private GroupEntry getGroupEntry(ActivationID id)
    throws UnknownObjectException
{
    ActivationGroupID gid = getGroupID(id);
    GroupEntry entry = groupTable.get(gid);
    if (entry != null && !entry.removed) {
        return entry;
    }
    throw new UnknownObjectException("object's group removed");
}
项目:OpenJSharp    文件:Activation.java   
synchronized ActivationGroupDesc setActivationGroupDesc(
        ActivationGroupID id,
        ActivationGroupDesc desc,
        boolean addRecord)
    throws UnknownGroupException, ActivationException
{
    checkRemoved();
    ActivationGroupDesc oldDesc = this.desc;
    this.desc = desc;
    // state update should occur before log update
    if (addRecord) {
        addLogRecord(new LogUpdateGroupDesc(id, desc));
    }
    return oldDesc;
}
项目:jdk8u-jdk    文件:ActivationGroupInit.java   
/**
 * Main program to start a VM for an activation group.
 */
public static void main(String args[])
{
    try {
        if (System.getSecurityManager() == null) {
            System.setSecurityManager(new SecurityManager());
        }
        // read group id, descriptor, and incarnation number from stdin
        MarshalInputStream in = new MarshalInputStream(System.in);
        ActivationGroupID id  = (ActivationGroupID)in.readObject();
        ActivationGroupDesc desc = (ActivationGroupDesc)in.readObject();
        long incarnation = in.readLong();

        // create and set group for the VM
        ActivationGroup.createGroup(id, desc, incarnation);
    } catch (Exception e) {
        System.err.println("Exception in starting ActivationGroupInit:");
        e.printStackTrace();
    } finally {
        try {
            System.in.close();
            // note: system out/err shouldn't be closed
            // since the parent may want to read them.
        } catch (Exception ex) {
            // ignore exceptions
        }
    }
}
项目:jdk8u-jdk    文件:Activation.java   
public void inactiveGroup(ActivationGroupID id,
                          long incarnation)
    throws UnknownGroupException, RemoteException
{
    try {
        checkShutdown();
    } catch (ActivationException e) {
        return;
    }
    RegistryImpl.checkAccess("ActivationMonitor.inactiveGroup");
    getGroupEntry(id).inactiveGroup(incarnation, false);
}