Ejemplo n.º 1
0
        private LeftRight()
        {
            m_leftVersion  = new LeftRightVersion();
            m_rightVersion = new LeftRightVersion();


            m_innerChoice    = LeftRightChoice.Left;
            m_versionChoice  = LeftRightChoice.Left;
            m_writerLockRoot = new Object();
        }
Ejemplo n.º 2
0
 private LeftRightVersion getLeftRightVersion(LeftRightChoice version)
 {
     return((version == LeftRightChoice.Left) ? m_leftVersion : m_rightVersion);
 }
Ejemplo n.º 3
0
 private LeftRightVersion getWaitVersion(LeftRightChoice currentVersionChoice)
 {
     return(getLeftRightVersion(currentVersionChoice == LeftRightChoice.Left ?
                                LeftRightChoice.Right
 : LeftRightChoice.Left));
 }
Ejemplo n.º 4
0
 private void swapInstanceVersionChoice()
 {
     m_innerChoice = (m_innerChoice == LeftRightChoice.Left) ?
                     LeftRightChoice.Right
 : LeftRightChoice.Left;
 }
Ejemplo n.º 5
0
 private void swapLeftRightVersionChoice()
 {
     m_versionChoice = (m_versionChoice == LeftRightChoice.Left) ?
                       LeftRightChoice.Right
                : LeftRightChoice.Left;
 }