예제 #1
0
        public CExtendedCodeUnit(CCodeUnit _CodeUnit, long _SourceFileID, long _NumberInGlobalWorkspace)
        {
            m_CodeUnit = _CodeUnit;

            if (_SourceFileID > DEFAULT_SOURCE_FILE_ID)
            {
                m_SourceFileID = _SourceFileID;
            }
            else
            {
                throw new ArgumentOutOfRangeException("SourceFileID");
            }

            if (_NumberInGlobalWorkspace >= CElementPosition.LINE_NUMBER_LOW_BOUND)
            {
                m_NumberInGlobalWorkspace = _NumberInGlobalWorkspace;
            }
            else
            {
                throw new ArgumentOutOfRangeException("NumberInGlobalWorkspace");
            }
        }
예제 #2
0
 /// <summary>
 /// Копирующий конструктор
 /// </summary>
 /// <param name="other"></param>
 public CExtendedCodeUnit(CExtendedCodeUnit other)
 {
     m_CodeUnit                = new CCodeUnit(other.m_CodeUnit);
     m_SourceFileID            = other.m_SourceFileID;
     m_NumberInGlobalWorkspace = other.m_NumberInGlobalWorkspace;
 }
예제 #3
0
 public CExtendedCodeUnit(CCodeUnit _CodeUnit, long _SourceFileID)
     : this(_CodeUnit, _SourceFileID, CElementPosition.LINE_NUMBER_LOW_BOUND)
 {
 }