/// <summary>
        /// Initializes a new instance of the <see cref="InteropDotNetPortableConfiguration"/> class.
        /// </summary>
        /// <param name="reader">The reader.</param>
        public InteropDotNetPortableConfiguration(IPortableReader reader)
        {
            IPortableRawReader rawReader = reader.RawReader();

            TypeConfigurations = rawReader.ReadGenericCollection <InteropDotNetPortableTypeConfiguration>();
            Types                   = rawReader.ReadGenericCollection <string>();
            DefaultNameMapper       = rawReader.ReadString();
            DefaultIdMapper         = rawReader.ReadString();
            DefaultSerializer       = rawReader.ReadString();
            DefaultMetadataEnabled  = rawReader.ReadBoolean();
            DefaultKeepDeserialized = rawReader.ReadBoolean();
        }
Example #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ClusterNodeImpl"/> class.
        /// </summary>
        /// <param name="reader">The reader.</param>
        public ClusterNodeImpl(IPortableRawReader reader)
        {
            _id = reader.ReadGuid() ?? default(Guid);

            _attrs  = reader.ReadGenericDictionary <string, object>().AsReadOnly();
            _addrs  = reader.ReadGenericCollection <string>().AsReadOnly();
            _hosts  = reader.ReadGenericCollection <string>().AsReadOnly();
            _order  = reader.ReadLong();
            _local  = reader.ReadBoolean();
            _daemon = reader.ReadBoolean();

            _metrics = reader.ReadBoolean() ? new ClusterMetricsImpl(reader) : null;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="InteropDotNetConfiguration"/> class.
        /// </summary>
        /// <param name="reader">The reader.</param>
        public InteropDotNetConfiguration(IPortableReader reader)
        {
            IPortableRawReader rawReader = reader.RawReader();

            PortableCfg = rawReader.ReadObject <InteropDotNetPortableConfiguration>();

            Assemblies = (List <string>)rawReader.ReadGenericCollection <string>();
        }