Skip to content

Commit bc4de12

Browse files
authored
Update QuickMan.cs
1 parent 5381df3 commit bc4de12

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

QuickMan.Lib/QuickMan.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public class QuickMan
1717
private int _Port = 1999;
1818
private Dictionary<string, Action<HttpListenerContext>> _Endpoints;
1919

20-
public static int _MaxSimultaneousConnections = 20;
20+
private static int _MaxSimultaneousConnections = 20;
2121
private Semaphore sem = new Semaphore(_MaxSimultaneousConnections, _MaxSimultaneousConnections);
2222

2323
/// <summary>
@@ -112,17 +112,17 @@ private void Listen()
112112
#endregion
113113
#region Server Misc.
114114

115-
public void PrintLine(string String)
115+
private void PrintLine(string String)
116116
{
117117
Console.WriteLine(Tag(String));
118118
}
119119

120-
public string Tag(string Text)
120+
private string Tag(string Text)
121121
{
122122
return "[" + DateTime.Now.ToShortDateString() + " " + DateTime.Now.ToShortTimeString() + "] " + Text;
123123
}
124124

125-
public string GetLocalIP()
125+
private string GetLocalIP()
126126
{
127127
using (System.Net.Sockets.Socket Socket = new System.Net.Sockets.Socket(System.Net.Sockets.AddressFamily.InterNetwork, System.Net.Sockets.SocketType.Dgram, 0))
128128
{
@@ -131,7 +131,7 @@ public string GetLocalIP()
131131
}
132132
}
133133

134-
public void AllowListener(string URL)
134+
private void AllowListener(string URL)
135135
{
136136
string command = $"http add urlacl url={ new Uri(URL).AbsoluteUri } user=Everyone";
137137
System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo("netsh", command) { WindowStyle = ProcessWindowStyle.Hidden, CreateNoWindow = true, Verb = "runas" });
@@ -219,7 +219,7 @@ public void Respond(FileStream Response, string ContentType, HttpListenerContext
219219
Context.Response.OutputStream.Flush();
220220
}
221221

222-
public Stream StringToStream(string s)
222+
private Stream StringToStream(string s)
223223
{
224224
var stream = new MemoryStream();
225225
var writer = new StreamWriter(stream);

0 commit comments

Comments
 (0)