2
|
1 |
/*
|
18830
|
2 |
* Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
|
2
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
4 |
*
|
|
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
|
5506
|
7 |
* published by the Free Software Foundation. Oracle designates this
|
2
|
8 |
* particular file as subject to the "Classpath" exception as provided
|
5506
|
9 |
* by Oracle in the LICENSE file that accompanied this code.
|
2
|
10 |
*
|
|
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT
|
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that
|
|
15 |
* accompanied this code).
|
|
16 |
*
|
|
17 |
* You should have received a copy of the GNU General Public License version
|
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation,
|
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
20 |
*
|
5506
|
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
|
|
23 |
* questions.
|
2
|
24 |
*/
|
|
25 |
|
|
26 |
|
|
27 |
package javax.security.auth.login;
|
|
28 |
|
|
29 |
/**
|
|
30 |
* This class defines the <i>Service Provider Interface</i> (<b>SPI</b>)
|
18830
|
31 |
* for the {@code Configuration} class.
|
2
|
32 |
* All the abstract methods in this class must be implemented by each
|
|
33 |
* service provider who wishes to supply a Configuration implementation.
|
|
34 |
*
|
|
35 |
* <p> Subclass implementations of this abstract class must provide
|
18830
|
36 |
* a public constructor that takes a {@code Configuration.Parameters}
|
2
|
37 |
* object as an input parameter. This constructor also must throw
|
|
38 |
* an IllegalArgumentException if it does not understand the
|
18830
|
39 |
* {@code Configuration.Parameters} input.
|
2
|
40 |
*
|
|
41 |
*
|
|
42 |
* @since 1.6
|
|
43 |
*/
|
|
44 |
|
|
45 |
public abstract class ConfigurationSpi {
|
|
46 |
/**
|
|
47 |
* Retrieve the AppConfigurationEntries for the specified <i>name</i>.
|
|
48 |
*
|
|
49 |
* <p>
|
|
50 |
*
|
|
51 |
* @param name the name used to index the Configuration.
|
|
52 |
*
|
|
53 |
* @return an array of AppConfigurationEntries for the specified
|
|
54 |
* <i>name</i>, or null if there are no entries.
|
|
55 |
*/
|
|
56 |
protected abstract AppConfigurationEntry[] engineGetAppConfigurationEntry
|
|
57 |
(String name);
|
|
58 |
|
|
59 |
/**
|
|
60 |
* Refresh and reload the Configuration.
|
|
61 |
*
|
|
62 |
* <p> This method causes this Configuration object to refresh/reload its
|
|
63 |
* contents in an implementation-dependent manner.
|
|
64 |
* For example, if this Configuration object stores its entries in a file,
|
18830
|
65 |
* calling {@code refresh} may cause the file to be re-read.
|
2
|
66 |
*
|
|
67 |
* <p> The default implementation of this method does nothing.
|
|
68 |
* This method should be overridden if a refresh operation is supported
|
|
69 |
* by the implementation.
|
|
70 |
*
|
|
71 |
* @exception SecurityException if the caller does not have permission
|
|
72 |
* to refresh its Configuration.
|
|
73 |
*/
|
|
74 |
protected void engineRefresh() { }
|
|
75 |
}
|