Package org.apache.sshd.common
Class SyspropsMapWrapper
- java.lang.Object
-
- org.apache.sshd.common.SyspropsMapWrapper
-
public final class SyspropsMapWrapper extends Object implements Map<String,Object>
A wrapper that exposes a read-onlyMapaccess to the system properties. Any attempt to modify it will throwUnsupportedOperationException. The mapper uses theSYSPROPS_MAPPED_PREFIXto filter and access' only these properties, ignoring all others- Author:
- Apache MINA SSHD Project
-
-
Field Summary
Fields Modifier and Type Field Description static SyspropsMapWrapperINSTANCEThe one and only wrapper instancestatic PropertyResolverRAW_PROPS_RESOLVERExposes the "raw" system properties as aPropertyResolverwithout any further filteringstatic StringSYSPROPS_MAPPED_PREFIXPrefix of properties used by the mapper to identify SSHD related settingsstatic PropertyResolverSYSPROPS_RESOLVERAPropertyResolverwith no parent that exposes the system properties
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()booleancontainsKey(Object key)booleancontainsValue(Object value)Set<Map.Entry<String,Object>>entrySet()Objectget(Object key)static StringgetMappedSyspropKey(Object key)static StringgetUnmappedSyspropKey(Object key)booleanisEmpty()static booleanisMappedSyspropKey(String key)Set<String>keySet()Objectput(String key, Object value)voidputAll(Map<? extends String,?> m)Objectremove(Object key)intsize()StringtoString()Collection<Object>values()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
-
-
Field Detail
-
SYSPROPS_MAPPED_PREFIX
public static final String SYSPROPS_MAPPED_PREFIX
Prefix of properties used by the mapper to identify SSHD related settings- See Also:
- Constant Field Values
-
RAW_PROPS_RESOLVER
public static final PropertyResolver RAW_PROPS_RESOLVER
Exposes the "raw" system properties as aPropertyResolverwithout any further filtering
-
INSTANCE
public static final SyspropsMapWrapper INSTANCE
The one and only wrapper instance
-
SYSPROPS_RESOLVER
public static final PropertyResolver SYSPROPS_RESOLVER
APropertyResolverwith no parent that exposes the system properties
-
-
Method Detail
-
containsKey
public boolean containsKey(Object key)
- Specified by:
containsKeyin interfaceMap<String,Object>
-
containsValue
public boolean containsValue(Object value)
- Specified by:
containsValuein interfaceMap<String,Object>
-
isMappedSyspropKey
public static boolean isMappedSyspropKey(String key)
- Parameters:
key- Key to be tested- Returns:
trueif key starts withSYSPROPS_MAPPED_PREFIXand continues with a dot followed by some characters
-
getUnmappedSyspropKey
public static String getUnmappedSyspropKey(Object key)
- Parameters:
key- Key to be transformed- Returns:
- The "pure" key name if a mapped one, same as input otherwise
- See Also:
isMappedSyspropKey(String)
-
getMappedSyspropKey
public static String getMappedSyspropKey(Object key)
- Parameters:
key- The original key- Returns:
- A key prefixed by
SYSPROPS_MAPPED_PREFIX - See Also:
isMappedSyspropKey(String)
-
-