Example #1
0
        /// <summary>
        /// Get the first header field in lpPacket which is an IncomingFaceId. This is
        /// an internal method which the application normally would not use.
        /// </summary>
        ///
        /// <param name="lpPacket">The LpPacket with the header fields to search.</param>
        /// <returns>The first IncomingFaceId header field, or null if not found.</returns>
        public static IncomingFaceId getFirstHeader(LpPacket lpPacket)
        {
            for (int i = 0; i < lpPacket.countHeaderFields(); ++i) {
                Object field = lpPacket.getHeaderField(i);
                if (field  is  IncomingFaceId)
                    return (IncomingFaceId) field;
            }

            return null;
        }
Example #2
0
        /// <summary>
        /// Get the first header field in lpPacket which is a NetworkNack. This is
        /// an internal method which the application normally would not use.
        /// </summary>
        ///
        /// <param name="lpPacket">The LpPacket with the header fields to search.</param>
        /// <returns>The first NetworkNack header field, or null if not found.</returns>
        public static NetworkNack getFirstHeader(LpPacket lpPacket)
        {
            for (int i = 0; i < lpPacket.countHeaderFields(); ++i) {
                Object field = lpPacket.getHeaderField(i);
                if (field  is  NetworkNack)
                    return (NetworkNack) field;
            }

            return null;
        }
Example #3
0
        /// <summary>
        /// Get the first header field in lpPacket which is a CongestionMark. This is
        /// an internal method which the application normally would not use.
        /// </summary>
        ///
        /// <param name="lpPacket">The LpPacket with the header fields to search.</param>
        /// <returns>The first CongestionMark header field, or null if not found.</returns>
        static public CongestionMark getFirstHeader(LpPacket lpPacket)
        {
            for (int i = 0; i < lpPacket.countHeaderFields(); ++i)
            {
                Object field = lpPacket.getHeaderField(i);
                if (field  is  CongestionMark)
                {
                    return((CongestionMark)field);
                }
            }

            return(null);
        }
Example #4
0
        /// <summary>
        /// Get the first header field in lpPacket which is an IncomingFaceId. This is
        /// an internal method which the application normally would not use.
        /// </summary>
        ///
        /// <param name="lpPacket">The LpPacket with the header fields to search.</param>
        /// <returns>The first IncomingFaceId header field, or null if not found.</returns>
        static public IncomingFaceId getFirstHeader(LpPacket lpPacket)
        {
            for (int i = 0; i < lpPacket.countHeaderFields(); ++i)
            {
                Object field = lpPacket.getHeaderField(i);
                if (field  is  IncomingFaceId)
                {
                    return((IncomingFaceId)field);
                }
            }

            return(null);
        }