Add project files.
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Configuration;
|
||||
|
||||
namespace CommonApi.Models
|
||||
{
|
||||
public class ADConfig
|
||||
{
|
||||
public string LDAPPath = "";
|
||||
public string LDAPUser = "";
|
||||
public string LDAPPassword = "";
|
||||
private TimeSpan _ADTimeOut = TimeSpan.FromSeconds(0);
|
||||
|
||||
public TimeSpan ADTimeOut
|
||||
{
|
||||
get
|
||||
{
|
||||
return _ADTimeOut;
|
||||
}
|
||||
}
|
||||
public string ADTimeOutStr
|
||||
{
|
||||
set
|
||||
{
|
||||
if (!string.IsNullOrEmpty(value))
|
||||
_ADTimeOut = TimeSpan.FromSeconds(Convert.ToDouble(value));
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
public static void Init()
|
||||
{
|
||||
LDAPPath = ConfigurationManager.AppSettings["LDAPPath"];
|
||||
LDAPUser = ConfigurationManager.AppSettings["LDAPUser"];
|
||||
LDAPPassword = ConfigurationManager.AppSettings["LDAPPassword"];
|
||||
ADTimeOut = TimeSpan.FromSeconds(Convert.ToDouble(ConfigurationManager.AppSettings["ADTimeOut"]));
|
||||
}
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user