コード例 #1
0
        /// <summary>Writes <paramref name="outer"/> with indefinite length followed by the start of an
        /// application-defined type with indefinite length.</summary>
        /// <exception cref="ArgumentOutOfRangeException"><paramref name="innerNumber"/> is smaller than
        /// <see cref="InnerNumber.FirstApplication"/>.</exception>
        /// <exception cref="ObjectDisposedException"><see cref="Dispose"/> has been called.</exception>
        public void WriteStartApplicationDefinedType(EmberId outer, int innerNumber)
        {
            this.AssertNotDisposed();

            if (innerNumber < InnerNumber.FirstApplication)
            {
                throw new ArgumentOutOfRangeException(
                          nameof(innerNumber), "Must be greater than or equal to InnerNumber.StartFirstApplication");
            }

            this.writeBuffer.Reserve(IdentifiersAndLengthsMaxLength);
            this.WriteIdentifiersAndLengths(outer, EmberId.FromInnerNumber(innerNumber), null);
        }
コード例 #2
0
 private static string GetFallbackName(int innerNumber) => EmberId.FromInnerNumber(innerNumber).ToString();