Solclient
SessionPropertiesFromDictionaryWithPrefix Method |
Creates and returns a new SessionProperties from a dictionary of key/value strings
where:
key: is a string representation of a given SessionProperties property SessionPropertiesPROPERTY prefixed with a string "prefix".
value: is a string representation of the value of that property.
Rules:
1. Keys that are not in the SessionProperties' property set SessionPropertiesPROPERTY, are ignored and a warning log is generated.
2. If a property is omitted, the default value will be used.
3. Validation and type checking will be performed on the provided values, a conversion exception will be thrown if any of the provided values cannot be converted.
4. Read-only properties are ignored.
Namespace: SolaceSystems.Solclient.Messaging
Assembly: SolaceSystems.Solclient.Messaging (in SolaceSystems.Solclient.Messaging.dll) Version: 7.2.1.27 (7.2.1.27)
Syntax
public static SessionProperties FromDictionaryWithPrefix( IDictionary<string, string> dictionary, string prefix )
Public Shared Function FromDictionaryWithPrefix ( dictionary As IDictionary(Of String, String), prefix As String ) As SessionProperties
public: static SessionProperties^ FromDictionaryWithPrefix( IDictionary<String^, String^>^ dictionary, String^ prefix )
Parameters
- dictionary
- Type: System.Collections.GenericIDictionaryString, String
- prefix
- Type: SystemString
The prefix to prepend to the property name (using '.' as a separator). If null is passed in, "SessionProperties" is assumed
Return Value
Type: SessionPropertiesReturns a new SessionProperties from a dictionary of key/value strings
Exceptions
Exception | Condition |
---|---|
FormatException | |
OverflowException |
See Also