Пример #1
0
//JAVA TO VB & C# CONVERTER WARNING: 'final' parameters are not allowed in .NET:
//ORIGINAL LINE: public final BList<T> parseList(final ByteBuffer buffer, final BHeader header)
        public BList <T> parseList(ByteBuffer buffer, BHeader header)
        {
            BInteger length = header.integer.parse(buffer, header);
            List <T> values = new List <T>();

            length.iterate(() => values.Add(parse(buffer, header)));
            return(new BList <T>(length, values));
        }
Пример #2
0
//JAVA TO VB & C# CONVERTER WARNING: 'final' parameters are not allowed in .NET:
//ORIGINAL LINE: public T[] asArray(final T[] array)
        public virtual T[] asArray(T[] array)
        {
            int i = 0;

            length.iterate(() => { array[i] = values[i]; i++; });

            /*new Runnable()
             * //JAVA TO VB & C# CONVERTER TODO TASK: Anonymous inner classes are not converted to .NET:
             *  {
             *
             *    private int i = 0;
             *
             *    public void run()
             *    {
             *          array[i] = values[i];
             *          i++;
             *    }
             *
             *    }
             * );*/
            return(array);
        }