コード例 #1
0
        internal int ReadStruct(byte[] b, int Offset)
        {
            uint method = 0x223;

            this.TrEntry(method, new object[] { b, Offset });
            IntPtr zero   = IntPtr.Zero;
            int    length = this.GetLength();
            int    result = 0;

            try
            {
                zero = Marshal.AllocCoTaskMem(length);
                if (length > (b.Length - Offset))
                {
                    length = b.Length - Offset;
                }
                Marshal.Copy(b, Offset, zero, length);
                this.mqPMO = (MQBase.MQPMO)Marshal.PtrToStructure(zero, typeof(MQBase.MQPMO));
                this.ClearInvalidFields(this.mqPMO.Version);
                Marshal.FreeCoTaskMem(zero);
                result = Offset + this.GetVersionLength();
            }
            finally
            {
                base.TrExit(method, result);
            }
            return(result);
        }
コード例 #2
0
 public static extern void lpiSPIPut(int hConn, int hObj, ref MQBase.MQMD mqmd, ref MQBase.MQPMO mqpmo, int bufferLength, [In] byte[] buffer, ref LPIPUTOPTS PutOptsIn, out int compCode, out int reason);
コード例 #3
0
 public static extern void MQPUT1(int hConn, IntPtr mqodPtr, ref MQBase.MQMD mqmd, ref MQBase.MQPMO mqpmo, int length, [In] byte[] buffer, out int compCode, out int reason);
コード例 #4
0
 public static extern void nmqiMultiBufMQPut1(int hConn, ref MQBase.MQOD mqod, ref MQBase.MQMD mqmd, ref MQBase.MQPMO mqpmo, int numBuffers, [In] byte[] buffer1, int length1, [In] byte[] buffer2, int length2, [In] byte[] buffer3, int length3, [In] byte[] buffer4, int length4, [In] byte[] buffer5, int length5, [In] byte[] buffer6, int length6, out int compCode, out int reason);