classFab.addMethod(Modifier.PUBLIC | Modifier.FINAL, new MethodSignature(void.class,
"registryDidShutdown", null, null), "{ _delegate = null; _shutdown = true; }");
}
BodyBuilder builder = new BodyBuilder();
builder.begin();
builder.addln("if (_shutdown)");
builder.addln(" throw org.apache.hivemind.HiveMind#createRegistryShutdownException();");
builder.add("return _delegate;");