Ejemplo n.º 1
0
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._recordID = dis.ReadUnsignedInt();
                    this._recordSetSerialNumber = dis.ReadUnsignedInt();
                    this._recordLength = dis.ReadUnsignedShort();
                    this._recordCount = dis.ReadUnsignedShort();
                    this._recordValues = dis.ReadUnsignedShort();
                    this._pad4 = dis.ReadUnsignedByte();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
Ejemplo n.º 2
0
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._variableDatumID = dis.ReadUnsignedInt();
                    this._variableDatumLength = dis.ReadUnsignedInt();
            int variableCount = (int)(this._variableDatumLength / 64) + (this._variableDatumLength % 64 > 0 ? 1 : 0);  //Post processed

                    for (int idx = 0; idx < variableCount; idx++)
                    {
                        EightByteChunk anX = new EightByteChunk();
                        anX.Unmarshal(dis);
                        this._variableDatums.Add(anX);
                    }
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
Ejemplo n.º 3
0
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._protocolVersion = dis.ReadUnsignedByte();
                    this._exerciseID = dis.ReadUnsignedByte();
                    this._pduType = dis.ReadUnsignedByte();
                    this._protocolFamily = dis.ReadUnsignedByte();
                    this._timestamp = dis.ReadUnsignedInt();
                    this._length = dis.ReadUnsignedShort();
                    this._padding = dis.ReadShort();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
Ejemplo n.º 4
0
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._hour = dis.ReadInt();
                    this._timePastHour = dis.ReadUnsignedInt();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._recordType = dis.ReadUnsignedShort();
                    this._recordLength = dis.ReadUnsignedShort();
                    this._recordSpecificField = dis.ReadUnsignedInt();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
Ejemplo n.º 6
0
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._environmentType = dis.ReadUnsignedInt();
                    this._length = dis.ReadUnsignedByte();
                    this._index = dis.ReadUnsignedByte();
                    this._padding1 = dis.ReadUnsignedByte();
                    this._geometry = dis.ReadUnsignedByte();
                    this._padding2 = dis.ReadUnsignedByte();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._beamDataLength = dis.ReadUnsignedByte();
                    this._beamIDNumber = dis.ReadUnsignedByte();
                    this._beamParameterIndex = dis.ReadUnsignedShort();
                    this._fundamentalParameterData.Unmarshal(dis);
                    this._beamFunction = dis.ReadUnsignedByte();
                    this._numberOfTrackJamTargets = dis.ReadUnsignedByte();
                    this._highDensityTrackJam = dis.ReadUnsignedByte();
                    this._pad4 = dis.ReadUnsignedByte();
                    this._jammingModeSequence = dis.ReadUnsignedInt();

                    for (int idx = 0; idx < this.NumberOfTrackJamTargets; idx++)
                    {
                        TrackJamTarget anX = new TrackJamTarget();
                        anX.Unmarshal(dis);
                        this._trackJamTargets.Add(anX);
                    }
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._erp = dis.ReadFloat();
                    this._frequency = dis.ReadFloat();
                    this._pgrf = dis.ReadFloat();
                    this._pulseWidth = dis.ReadFloat();
                    this._burstLength = dis.ReadUnsignedInt();
                    this._applicableModes = dis.ReadUnsignedByte();
                    this._pad2 = dis.ReadUnsignedShort();
                    this._pad3 = dis.ReadUnsignedByte();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }
Ejemplo n.º 9
0
        public virtual void Unmarshal(DataInputStream dis)
        {
            if (dis != null)
            {
                try
                {
                    this._segmentNumber = dis.ReadUnsignedByte();
                    this._segmentAppearance.Unmarshal(dis);
                    this._location.Unmarshal(dis);
                    this._orientation.Unmarshal(dis);
                    this._segmentLength = dis.ReadUnsignedShort();
                    this._segmentWidth = dis.ReadUnsignedShort();
                    this._segmentHeight = dis.ReadUnsignedShort();
                    this._segmentDepth = dis.ReadUnsignedShort();
                    this._pad1 = dis.ReadUnsignedInt();
                }
                catch (Exception e)
                {
                    if (PduBase.TraceExceptions)
                    {
                        Trace.WriteLine(e);
                        Trace.Flush();
                    }

                    this.RaiseExceptionOccured(e);

                    if (PduBase.ThrowExceptions)
                    {
                        throw e;
                    }
                }
            }
        }