提交 1b3ec278 编写于 作者: A asaha

Merge

......@@ -251,6 +251,7 @@ a7d3638deb2f4e33217b1ecf889479e90f9e5b50 jdk8-b121
b8c71dae05574f8eca7ca6d703b16b450850b033 jdk8-b127
113e7569b49bca18846e5e5b74e644580b805902 jdk8-b128
5c72d74c6805d1b4f6192f7a3550d126acf37005 jdk8-b129
0683ee308085785d0455f4153e764e062843f178 jdk8-b130
5de8d42f9eb7ddcdc741445f3c21a63887d694b6 jdk8u5-b01
c750098a3ef18de28a6d739666559f0333c76c78 jdk8u5-b02
3d9b40a53134aa33031bf13581dff9fccade9048 jdk8u5-b03
......
/*
* Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2002, 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
......@@ -170,6 +170,12 @@ public abstract class ORB extends com.sun.corba.se.org.omg.CORBA.ORB
// representing LogDomain and ExceptionGroup.
private Map wrapperMap ;
static class Holder {
static final PresentationManager defaultPresentationManager =
setupPresentationManager();
}
private static final Object pmLock = new Object();
private static Map staticWrapperMap = new ConcurrentHashMap();
protected MonitoringManager monitoringManager;
......@@ -235,13 +241,24 @@ public abstract class ORB extends com.sun.corba.se.org.omg.CORBA.ORB
*/
public static PresentationManager getPresentationManager()
{
AppContext ac = AppContext.getAppContext();
PresentationManager pm = (PresentationManager) ac.get(PresentationManager.class);
if (pm == null) {
pm = setupPresentationManager();
ac.put(PresentationManager.class, pm);
SecurityManager sm = System.getSecurityManager();
if (sm != null && AppContext.getAppContexts().size() > 0) {
AppContext ac = AppContext.getAppContext();
if (ac != null) {
synchronized (pmLock) {
PresentationManager pm =
(PresentationManager) ac.get(PresentationManager.class);
if (pm == null) {
pm = setupPresentationManager();
ac.put(PresentationManager.class, pm);
}
return pm;
}
}
}
return pm;
// No security manager or AppContext
return Holder.defaultPresentationManager;
}
/** Get the appropriate StubFactoryFactory. This
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册