diff options
author | Benoit Foucher <benoit@zeroc.com> | 2012-04-20 17:29:10 +0200 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2012-04-20 17:29:10 +0200 |
commit | 410311ac0dad54bbc0906085134b41e12ed44abb (patch) | |
tree | 678d75e04b90c289628c1ae79100317432bfe1d8 /java/src/IceInternal/ReferenceFactory.java | |
parent | Enabled again objects test (diff) | |
download | ice-410311ac0dad54bbc0906085134b41e12ed44abb.tar.bz2 ice-410311ac0dad54bbc0906085134b41e12ed44abb.tar.xz ice-410311ac0dad54bbc0906085134b41e12ed44abb.zip |
Java port
Diffstat (limited to 'java/src/IceInternal/ReferenceFactory.java')
-rw-r--r-- | java/src/IceInternal/ReferenceFactory.java | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/java/src/IceInternal/ReferenceFactory.java b/java/src/IceInternal/ReferenceFactory.java index 6388ebe5f45..21902f03703 100644 --- a/java/src/IceInternal/ReferenceFactory.java +++ b/java/src/IceInternal/ReferenceFactory.java @@ -41,6 +41,8 @@ public final class ReferenceFactory return null; } + DefaultsAndOverrides defaultsAndOverrides = _instance.defaultsAndOverrides(); + // // Create new reference // @@ -51,6 +53,7 @@ public final class ReferenceFactory "", // Facet fixedConnection.endpoint().datagram() ? Reference.ModeDatagram : Reference.ModeTwoway, fixedConnection.endpoint().secure(), + defaultsAndOverrides.defaultEncoding, fixedConnection); return updateCache(ref); } @@ -655,6 +658,7 @@ public final class ReferenceFactory "EndpointSelection", "ConnectionCached", "PreferSecure", + "EncodingVersion", "LocatorCacheTimeout", "Locator", "Router", @@ -726,6 +730,7 @@ public final class ReferenceFactory boolean collocationOptimized = defaultsAndOverrides.defaultCollocationOptimization; boolean cacheConnection = true; boolean preferSecure = defaultsAndOverrides.defaultPreferSecure; + Ice.EncodingVersion encoding = defaultsAndOverrides.defaultEncoding; Ice.EndpointSelectionType endpointSelection = defaultsAndOverrides.defaultEndpointSelection; int locatorCacheTimeout = defaultsAndOverrides.defaultLocatorCacheTimeout; @@ -778,6 +783,14 @@ public final class ReferenceFactory property = propertyPrefix + ".PreferSecure"; preferSecure = properties.getPropertyAsIntWithDefault(property, preferSecure ? 1 : 0) > 0; + property = propertyPrefix + ".EncodingVersion"; + String encodingStr = properties.getProperty(property); + if(!encodingStr.isEmpty()) + { + encoding = Ice.Util.stringToEncodingVersion(encodingStr); + Protocol.checkSupportedEncoding(encoding); + } + property = propertyPrefix + ".EndpointSelection"; if(properties.getProperty(property).length() > 0) { @@ -810,6 +823,7 @@ public final class ReferenceFactory facet, mode, secure, + encoding, endpoints, adapterId, locatorInfo, |