Package org.oa4mp.delegation.server
Class OA2ConfigurationLoaderUtils
- java.lang.Object
-
- edu.uiuc.ncsa.security.util.configuration.XMLConfigUtil
-
- org.oa4mp.delegation.server.OA2ConfigurationLoaderUtils
-
- All Implemented Interfaces:
edu.uiuc.ncsa.security.util.configuration.TimeConstants
public class OA2ConfigurationLoaderUtils extends edu.uiuc.ncsa.security.util.configuration.XMLConfigUtil
Created by Jeff Gaynor
on 8/26/15 at 3:59 PM
-
-
Field Summary
-
Fields inherited from interface edu.uiuc.ncsa.security.util.configuration.TimeConstants
ONE_DAY, ONE_HOUR, ONE_MINUTES, ONE_MONTH, ONE_WEEK, ONE_YEAR, SECONDS, UNITS__WEEK, UNITS_DAYS, UNITS_DAYS_LONG, UNITS_HOURS, UNITS_HOURS_LONG, UNITS_MILLISECOND_LONG, UNITS_MILLISECOND_MULTIPLIER, UNITS_MILLISECONDS, UNITS_MINUTES, UNITS_MINUTES_LONG, UNITS_MINUTES_LONG2, UNITS_MONTHS, UNITS_MONTHS_LONG, UNITS_SECONDS, UNITS_SECONDS_LONG, UNITS_SECONDS_LONG2, UNITS_WEEK_LONG, UNITS_YEARS, UNITS_YEARS_LONG
-
-
Constructor Summary
Constructors Constructor Description OA2ConfigurationLoaderUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Map<String,List<String>>
getAdditionalParameters(org.apache.commons.configuration.tree.ConfigurationNode cn)
To read a block of parameters from a (client) configuration.static Collection<String>
getScopes(org.apache.commons.configuration.tree.ConfigurationNode cn)
The block containing the scopes.
-
-
-
Method Detail
-
getAdditionalParameters
public static Map<String,List<String>> getAdditionalParameters(org.apache.commons.configuration.tree.ConfigurationNode cn)
To read a block of parameters from a (client) configuration. These are sent along with the initial request. Format is
<parameters> <parameter key="key0" enabled=("true"|"false")>value0</parameter> <parameter key="key1">value1</parameter> ... </parameters>
where the keys and values will be properly encoded (so you don't have to do it). These will end up in the request as...&key0=value0&key1=value1&...
. Note that the value sent is the body of the element, so you can literally send anything if you include it in a CDATA tag.There is an optional flag to enable these. No flag means it is enabled. Disabling will prevent it from being included. This allows you to turn on and off parameters in the file without having to comment things out or remove them. Note that at this point, these are only sent in the initial request.
- Parameters:
cn
-- Returns:
-
getScopes
public static Collection<String> getScopes(org.apache.commons.configuration.tree.ConfigurationNode cn)
The block containing the scopes. Format is (there may be more, just add them)<scopes> <scope>openid</scope> <scope>email</scope> <scope enabled="false">edu.uiuc.ncsa.myproxy.getcert</scope> <scope>profile</scope> <scope>org.cilogon.userinfo</scope> </scopes>
Each block has anenabled
flag so you can turn these off and on without removing them.- Parameters:
cn
-- Returns:
-
-