/**
         * <summary>Read collection.</summary>
         */
        private static object ReadCollection(PortableReaderImpl ctx, Type type)
        {
            PortableCollectionInfo info = PortableCollectionInfo.Info(type);

            return(info.IsGenericCollection
                ? info.ReadGeneric(ctx)
                : PortableUtils.ReadCollection(ctx, null, null));
        }
 /** <inheritdoc /> */
 public ICollection ReadCollection(PortableCollectionFactory factory,
                                   PortableCollectionAdder adder)
 {
     return(Read(r => PortableUtils.ReadCollection(r, factory, adder)));
 }
 /** <inheritdoc /> */
 public ICollection ReadCollection(string fieldName, PortableCollectionFactory factory,
                                   PortableCollectionAdder adder)
 {
     return(ReadField(fieldName, r => PortableUtils.ReadCollection(r, factory, adder)));
 }