示例#1
0
 internal AttributeConverterEntry GetConverterEntry(string propertyName, ADServerType serverType)
 {
     if (this._attributeTable == null || !this._attributeTable.ContainsKey(serverType) || !this._attributeTable[serverType].ContainsKey(propertyName))
     {
         return(null);
     }
     else
     {
         return(this._attributeTable[serverType][propertyName]);
     }
 }
示例#2
0
		internal AttributeConverterEntry GetConverterEntry(string propertyName, ADServerType serverType)
		{
			if (this._attributeTable == null || !this._attributeTable.ContainsKey(serverType) || !this._attributeTable[serverType].ContainsKey(propertyName))
			{
				return null;
			}
			else
			{
				return this._attributeTable[serverType][propertyName];
			}
		}
示例#3
0
 internal virtual void SetCmdletSessionInfo(CmdletSessionInfo cmdletSessionInfo)
 {
     if (cmdletSessionInfo != null)
     {
         this._cmdletSessionInfo = cmdletSessionInfo;
         this._connectedStore    = this._cmdletSessionInfo.ConnectedADServerType;
         return;
     }
     else
     {
         throw new ArgumentNullException("cmdletSessionInfo");
     }
 }
示例#4
0
 public CmdletSessionInfo(ADSessionInfo adSessionInfo, ADRootDSE adRootDse, string defaultQueryPath, string defaultPartitionPath, string defaultCreationPath, ADServerType connectedADServerType, IADCmdletCache cmdletSessionCache, IADCmdletMessageWriter cmdletMessageWriter, PSCmdlet psCmdlet, ADParameterSet cmdletParameters)
 {
     this._adSessionInfo         = adSessionInfo;
     this._adRootDse             = adRootDse;
     this._defaultQueryPath      = defaultQueryPath;
     this._defaultPartitionPath  = defaultPartitionPath;
     this._defaultCreationPath   = defaultCreationPath;
     this._connectedADServerType = connectedADServerType;
     this._cmdletSessionCache    = cmdletSessionCache;
     this._cmdletMessageWriter   = cmdletMessageWriter;
     this._psCmdlet         = psCmdlet;
     this._cmdletParameters = cmdletParameters;
 }
示例#5
0
		public CmdletSessionInfo(ADSessionInfo adSessionInfo, ADRootDSE adRootDse, string defaultQueryPath, string defaultPartitionPath, string defaultCreationPath, ADServerType connectedADServerType, IADCmdletCache cmdletSessionCache, IADCmdletMessageWriter cmdletMessageWriter, PSCmdlet psCmdlet, ADParameterSet cmdletParameters)
		{
			this._adSessionInfo = adSessionInfo;
			this._adRootDse = adRootDse;
			this._defaultQueryPath = defaultQueryPath;
			this._defaultPartitionPath = defaultPartitionPath;
			this._defaultCreationPath = defaultCreationPath;
			this._connectedADServerType = connectedADServerType;
			this._cmdletSessionCache = cmdletSessionCache;
			this._cmdletMessageWriter = cmdletMessageWriter;
			this._psCmdlet = psCmdlet;
			this._cmdletParameters = cmdletParameters;
		}
示例#6
0
        private static void RegisterMappingTable <MT>(Dictionary <ADServerType, MappingTable <MT> > table, MT[] map, ADServerType storeType)
            where MT : MappingTableEntry
        {
            if (!table.ContainsKey(storeType))
            {
                table.Add(storeType, new MappingTable <MT>());
            }
            MappingTable <MT> item = table[storeType];

            MT[] mTArray = map;
            for (int i = 0; i < (int)mTArray.Length; i++)
            {
                MT mT = mTArray[i];
                if (!item.ContainsKey(mT.ExtendedAttribute))
                {
                    item.Add(mT.ExtendedAttribute, mT);
                }
            }
        }
示例#7
0
 internal static void RegisterMappingTable(AttributeConverterEntry[] attributeMap, ADServerType storeType)
 {
     ADFactoryBase <T> .RegisterMappingTable <AttributeConverterEntry>(ADFactoryBase <T> ._attributeTable, attributeMap, storeType);
 }