System.Diagnostics.Log.AddStream C# (CSharp) 메소드

AddStream() 공개 정적인 메소드

public static AddStream ( Stream stream ) : void
stream Stream
리턴 void
    	public static void AddStream(Stream stream)
    	{
    		if (stream==null)
    			throw new ArgumentNullException("stream");
    		if (m_iStreamArraySize <= m_iNumOfStreamDevices)
    		{
    				// increase array size in chunks of 4
    				Stream[] newArray = new Stream [m_iStreamArraySize+4];
    
    				// copy the old array objects into the new one.
    	            if (m_iNumOfStreamDevices > 0) 
    					Array.Copy(m_rgStream, newArray, m_iNumOfStreamDevices);
    
    				m_iStreamArraySize += 4;
    
    		        m_rgStream = newArray;
    		}
    
    		m_rgStream [m_iNumOfStreamDevices++] = stream;
    	}