groovyx.gpars.activeobject
Class ActiveObjectRegistry

java.lang.Object
  extended by groovyx.gpars.activeobject.ActiveObjectRegistry

public final class ActiveObjectRegistry
extends java.lang.Object

Maps string identifiers to instances of PGroup. Active objects may refer to their desired groups by the identifiers and they will look the groups up in the registry.

Author:
Vaclav Pech

Field Summary
private static ActiveObjectRegistry ourInstance
           
private  java.util.Map<java.lang.String,PGroup> registry
           
 
Constructor Summary
private ActiveObjectRegistry()
           
 
Method Summary
 PGroup findGroupById(java.lang.String groupId)
           
static ActiveObjectRegistry getInstance()
           
 void register(java.lang.String groupId, PGroup group)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ourInstance

private static final ActiveObjectRegistry ourInstance

registry

private final java.util.Map<java.lang.String,PGroup> registry
Constructor Detail

ActiveObjectRegistry

private ActiveObjectRegistry()
Method Detail

getInstance

public static ActiveObjectRegistry getInstance()

findGroupById

public PGroup findGroupById(java.lang.String groupId)

register

public void register(java.lang.String groupId,
                     PGroup group)

Copyright © 2008–2012 Václav Pech. All Rights Reserved.