Ejemplo n.º 1
0
 //----------------------------------------------------------------------------------------------------
 /// <summary>
 ///	채널를 얻어온다.
 /// </summary>
 /// <param name="id">채널 아이디.</param>
 /// <param name="value">[출력]채널 객체.</param>
 /// <returns>성공 유무.</returns>
 //----------------------------------------------------------------------------------------------------
 public bool GetChannel( byte id, out cChannel value )
 {
     lock(s_channels)
     {
         return s_channels.TryGetValue( id, out value );
     }
 }
Ejemplo n.º 2
0
 //----------------------------------------------------------------------------------------------------
 /// <summary>
 ///	채널를 얻어온다.
 /// </summary>
 /// <param name="channel_id">채널 아이디.</param>
 /// <param name="channel">[출력]채널 객체.</param>
 /// <returns>성공 유무.</returns>
 //----------------------------------------------------------------------------------------------------
 public bool GetChannel( byte channel_id, out cChannel channel )
 {
     lock(m_channels)
     {
         return m_channels.TryGetValue( channel_id, out channel );
     }
 }
Ejemplo n.º 3
0
 //----------------------------------------------------------------------------------------------------
 /// <summary>
 ///	채널 추가.
 /// </summary>
 /// <param name="id">채널 아이디.</param>
 /// <param name="value">채널 인스턴스.</param>
 //----------------------------------------------------------------------------------------------------
 public void AddChannel( byte id, cChannel value )
 {
     lock(s_channels)
     {
         s_channels.Add( id, value );
     }
 }
Ejemplo n.º 4
0
 //----------------------------------------------------------------------------------------------------
 /// <summary>
 ///	채널 추가.
 /// </summary>
 /// <returns>채널 객체</returns>
 //----------------------------------------------------------------------------------------------------
 public cChannel AddChannel()
 {
     lock(m_channels)
     {
         cChannel channel = new cChannel();
         m_channels.Add( channel.ChannelID, channel );
         return channel;
     }
 }