Beispiel #1
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Requires("size >= 0") @Ensures("encodeStream.size() > old(encodeStream.size())") public final void encodeType(final int size, final org.broadinstitute.variant.bcf2.BCF2Type type) throws java.io.IOException
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
//JAVA TO C# CONVERTER WARNING: 'final' parameters are not allowed in .NET:
        public void encodeType(int size, BCF2Type type)
        {
            if (size <= BCF2Utils.MAX_INLINE_ELEMENTS)
            {
//JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final':
//ORIGINAL LINE: final int typeByte = org.broadinstitute.variant.bcf2.BCF2Utils.encodeTypeDescriptor(size, type);
                int typeByte = BCF2Utils.encodeTypeDescriptor(size, type);
                encodeStream.write(typeByte);
            }
            else
            {
//JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final':
//ORIGINAL LINE: final int typeByte = org.broadinstitute.variant.bcf2.BCF2Utils.encodeTypeDescriptor(org.broadinstitute.variant.bcf2.BCF2Utils.OVERFLOW_ELEMENT_MARKER, type);
                int typeByte = BCF2Utils.encodeTypeDescriptor(BCF2Utils.OVERFLOW_ELEMENT_MARKER, type);
                encodeStream.write(typeByte);
                // write in the overflow size
                encodeTypedInt(size);
            }
        }