equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. Oracle designates this |
7 * published by the Free Software Foundation. Oracle designates this |
21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
22 * or visit www.oracle.com if you need additional information or have any |
22 * or visit www.oracle.com if you need additional information or have any |
23 * questions. |
23 * questions. |
24 */ |
24 */ |
25 |
25 |
26 |
|
27 package sun.security.ssl; |
26 package sun.security.ssl; |
28 |
27 |
29 import java.util.Enumeration; |
28 import java.util.Enumeration; |
|
29 import java.util.Locale; |
30 import java.util.Vector; |
30 import java.util.Vector; |
31 import java.util.Locale; |
|
32 |
|
33 import javax.net.ssl.SSLSession; |
31 import javax.net.ssl.SSLSession; |
34 import javax.net.ssl.SSLSessionContext; |
32 import javax.net.ssl.SSLSessionContext; |
35 |
|
36 import sun.security.util.Cache; |
33 import sun.security.util.Cache; |
37 |
34 |
38 |
35 |
39 final class SSLSessionContextImpl implements SSLSessionContext { |
36 final class SSLSessionContextImpl implements SSLSessionContext { |
40 private Cache<SessionId, SSLSessionImpl> sessionCache; |
37 private Cache<SessionId, SSLSessionImpl> sessionCache; |
248 public Enumeration<byte[]> getSessionIds() { |
245 public Enumeration<byte[]> getSessionIds() { |
249 return ids != null ? ids.elements() : |
246 return ids != null ? ids.elements() : |
250 new Vector<byte[]>().elements(); |
247 new Vector<byte[]>().elements(); |
251 } |
248 } |
252 } |
249 } |
253 |
|
254 } |
250 } |