Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / Configuration / CompilerCollection.cs / 3 / CompilerCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.Globalization; using System.IO; using System.Text; using System.Web.Compilation; using System.Reflection; using System.Web.Hosting; using System.Web.UI; using System.CodeDom.Compiler; using System.Web.Util; using System.ComponentModel; using System.Security.Permissions; [ConfigurationCollection(typeof(Compiler), AddItemName = "compiler", CollectionType = ConfigurationElementCollectionType.BasicMap)] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class CompilerCollection : ConfigurationElementCollection { private static ConfigurationPropertyCollection _properties; static CompilerCollection() { // Property initialization _properties = new ConfigurationPropertyCollection(); } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } public CompilerCollection() : base(StringComparer.OrdinalIgnoreCase) { } // public properties public string[] AllKeys { get { return StringUtil.ObjectArrayToStringArray(BaseGetAllKeys()); } } public new Compiler this[string language] { get { return (Compiler)BaseGet(language); } } public Compiler this[int index] { get { return (Compiler)BaseGet(index); } // set // { // throw new ConfigurationErrorsException(SR.GetString(SR.Config_read_only_section_cannot_be_set, "CompilerCollection")); // if (BaseGet(index) != null) // BaseRemoveAt(index); // BaseAdd(index,value); // } } // Protected Overrides protected override ConfigurationElement CreateNewElement() { return new Compiler(); } protected override Object GetElementKey(ConfigurationElement element) { return ((Compiler)element).Language; } protected override string ElementName { get { return "compiler"; } } public override ConfigurationElementCollectionType CollectionType { get { return ConfigurationElementCollectionType.BasicMap; } } // public methods // public void Add(Compiler compiler) { // BaseAdd(compiler); // } // public void Clear() { // BaseClear(); // } public Compiler Get(int index) { return (Compiler)BaseGet(index); } public Compiler Get(string language) { return (Compiler)BaseGet(language); } public String GetKey(int index) { return (String) BaseGetKey(index); } // public void Remove(string language) { // BaseRemove(language); // } // public void RemoveAt(int index) { // BaseRemoveAt(index); // } // public void Set(Compiler compiler) { // BaseAdd(compiler,false); // } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.Globalization; using System.IO; using System.Text; using System.Web.Compilation; using System.Reflection; using System.Web.Hosting; using System.Web.UI; using System.CodeDom.Compiler; using System.Web.Util; using System.ComponentModel; using System.Security.Permissions; [ConfigurationCollection(typeof(Compiler), AddItemName = "compiler", CollectionType = ConfigurationElementCollectionType.BasicMap)] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class CompilerCollection : ConfigurationElementCollection { private static ConfigurationPropertyCollection _properties; static CompilerCollection() { // Property initialization _properties = new ConfigurationPropertyCollection(); } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } public CompilerCollection() : base(StringComparer.OrdinalIgnoreCase) { } // public properties public string[] AllKeys { get { return StringUtil.ObjectArrayToStringArray(BaseGetAllKeys()); } } public new Compiler this[string language] { get { return (Compiler)BaseGet(language); } } public Compiler this[int index] { get { return (Compiler)BaseGet(index); } // set // { // throw new ConfigurationErrorsException(SR.GetString(SR.Config_read_only_section_cannot_be_set, "CompilerCollection")); // if (BaseGet(index) != null) // BaseRemoveAt(index); // BaseAdd(index,value); // } } // Protected Overrides protected override ConfigurationElement CreateNewElement() { return new Compiler(); } protected override Object GetElementKey(ConfigurationElement element) { return ((Compiler)element).Language; } protected override string ElementName { get { return "compiler"; } } public override ConfigurationElementCollectionType CollectionType { get { return ConfigurationElementCollectionType.BasicMap; } } // public methods // public void Add(Compiler compiler) { // BaseAdd(compiler); // } // public void Clear() { // BaseClear(); // } public Compiler Get(int index) { return (Compiler)BaseGet(index); } public Compiler Get(string language) { return (Compiler)BaseGet(language); } public String GetKey(int index) { return (String) BaseGetKey(index); } // public void Remove(string language) { // BaseRemove(language); // } // public void RemoveAt(int index) { // BaseRemoveAt(index); // } // public void Set(Compiler compiler) { // BaseAdd(compiler,false); // } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DataChangedEventManager.cs
- Adorner.cs
- ConnectionAcceptor.cs
- CompilerResults.cs
- ContainerControl.cs
- DbMetaDataColumnNames.cs
- ValidationPropertyAttribute.cs
- WebPartMenuStyle.cs
- GridViewColumnCollectionChangedEventArgs.cs
- PipeSecurity.cs
- AutoSizeComboBox.cs
- DispatchChannelSink.cs
- PowerStatus.cs
- TextOnlyOutput.cs
- SQLChars.cs
- NamedObject.cs
- FlowDocumentPaginator.cs
- PersistChildrenAttribute.cs
- PageAsyncTask.cs
- PartitionedDataSource.cs
- VectorAnimationBase.cs
- JsonReaderWriterFactory.cs
- ControlBuilderAttribute.cs
- CompilerLocalReference.cs
- WebPartConnectionsDisconnectVerb.cs
- SqlNotificationEventArgs.cs
- RequestCacheManager.cs
- DBParameter.cs
- ChannelSinkStacks.cs
- BeginStoryboard.cs
- DispatcherTimer.cs
- CodeIndexerExpression.cs
- TranslateTransform.cs
- WebPartsPersonalization.cs
- DisplayInformation.cs
- SelectManyQueryOperator.cs
- OleStrCAMarshaler.cs
- WpfKnownTypeInvoker.cs
- WebPartExportVerb.cs
- SecurityChannel.cs
- BaseCollection.cs
- BitmapEditor.cs
- CorrelationTokenInvalidatedHandler.cs
- _ShellExpression.cs
- HttpCapabilitiesSectionHandler.cs
- AsymmetricKeyExchangeFormatter.cs
- AppSettingsExpressionBuilder.cs
- FixedSOMContainer.cs
- CapabilitiesAssignment.cs
- FormViewDeletedEventArgs.cs
- Atom10FormatterFactory.cs
- StylusShape.cs
- WebBrowserUriTypeConverter.cs
- ImageSource.cs
- ExternalDataExchangeService.cs
- LinqDataSourceInsertEventArgs.cs
- DBBindings.cs
- ItemsChangedEventArgs.cs
- EventDescriptor.cs
- LineUtil.cs
- XmlComment.cs
- SqlResolver.cs
- KeyValueConfigurationCollection.cs
- SymDocumentType.cs
- LayoutDump.cs
- UIElementHelper.cs
- SendMailErrorEventArgs.cs
- OptionalColumn.cs
- FontStretches.cs
- UndirectedGraph.cs
- PersonalizationDictionary.cs
- DeferredElementTreeState.cs
- TemplateBamlRecordReader.cs
- BehaviorEditorPart.cs
- FilterableAttribute.cs
- Propagator.Evaluator.cs
- PathGeometry.cs
- GeneralTransformGroup.cs
- SqlDataSourceCustomCommandEditor.cs
- DataGridViewComboBoxColumn.cs
- GridSplitter.cs
- FrameworkElementAutomationPeer.cs
- UnsafeNativeMethodsPenimc.cs
- ProgressBar.cs
- SamlDoNotCacheCondition.cs
- DataViewListener.cs
- NominalTypeEliminator.cs
- ResourcePool.cs
- ToolboxItemCollection.cs
- CompoundFileIOPermission.cs
- MultiView.cs
- HttpProfileGroupBase.cs
- TemplatePropertyEntry.cs
- Nullable.cs
- FaultHandlingFilter.cs
- XmlElementCollection.cs
- input.cs
- GridViewColumnHeaderAutomationPeer.cs
- ObjectStateEntryDbDataRecord.cs
- ParserOptions.cs