Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Regex / System / Text / RegularExpressions / CompiledRegexRunnerFactory.cs / 1305376 / CompiledRegexRunnerFactory.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System.Reflection.Emit; using System.Diagnostics; using System.Security.Permissions; #if !SILVERLIGHT namespace System.Text.RegularExpressions { internal sealed class CompiledRegexRunnerFactory : RegexRunnerFactory { DynamicMethod goMethod; DynamicMethod findFirstCharMethod; DynamicMethod initTrackCountMethod; internal CompiledRegexRunnerFactory (DynamicMethod go, DynamicMethod firstChar, DynamicMethod trackCount) { this.goMethod = go; this.findFirstCharMethod = firstChar; this.initTrackCountMethod = trackCount; //Debug.Assert(goMethod != null && findFirstCharMethod != null && initTrackCountMethod != null, "can't be null"); } protected internal override RegexRunner CreateInstance() { CompiledRegexRunner runner = new CompiledRegexRunner(); new ReflectionPermission(PermissionState.Unrestricted).Assert(); runner.SetDelegates((NoParamDelegate) goMethod.CreateDelegate(typeof(NoParamDelegate)), (FindFirstCharDelegate) findFirstCharMethod.CreateDelegate(typeof(FindFirstCharDelegate)), (NoParamDelegate) initTrackCountMethod.CreateDelegate(typeof(NoParamDelegate))); return runner; } } internal delegate RegexRunner CreateInstanceDelegate(); } #endif // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TemporaryBitmapFile.cs
- MexHttpBindingCollectionElement.cs
- XpsPackagingPolicy.cs
- HtmlWindow.cs
- EncoderParameter.cs
- ComAdminInterfaces.cs
- ExpressionBuilderContext.cs
- ScrollProperties.cs
- UnsafeNativeMethods.cs
- safesecurityhelperavalon.cs
- SqlRowUpdatingEvent.cs
- HttpWebRequest.cs
- EntityCommand.cs
- BordersPage.cs
- ExportException.cs
- WebPartDisplayModeCollection.cs
- RowParagraph.cs
- PenLineJoinValidation.cs
- SettingsPropertyIsReadOnlyException.cs
- ParserStreamGeometryContext.cs
- XmlAttributeCollection.cs
- GridViewRowEventArgs.cs
- Interfaces.cs
- ExchangeUtilities.cs
- EventProviderWriter.cs
- Ref.cs
- ZoneIdentityPermission.cs
- PageCache.cs
- ScriptReferenceEventArgs.cs
- MimePart.cs
- HttpContext.cs
- Conditional.cs
- AppDomainResourcePerfCounters.cs
- VisualTreeHelper.cs
- NativeMethodsCLR.cs
- StylusPointDescription.cs
- ConfigXmlWhitespace.cs
- SortFieldComparer.cs
- DisplayInformation.cs
- UrlPropertyAttribute.cs
- Section.cs
- AlternationConverter.cs
- Processor.cs
- IgnoreDeviceFilterElementCollection.cs
- Reference.cs
- EntityCommandExecutionException.cs
- RightNameExpirationInfoPair.cs
- BitConverter.cs
- Helpers.cs
- RoutedUICommand.cs
- IDReferencePropertyAttribute.cs
- ValidationResult.cs
- WebPartUserCapability.cs
- _ContextAwareResult.cs
- Attributes.cs
- SectionInformation.cs
- RequestCacheManager.cs
- DataGridGeneralPage.cs
- RequestTimeoutManager.cs
- AssemblyUtil.cs
- DbConnectionInternal.cs
- DesignerActionHeaderItem.cs
- ApplicationHost.cs
- ExecutedRoutedEventArgs.cs
- InertiaExpansionBehavior.cs
- CLRBindingWorker.cs
- WorkingDirectoryEditor.cs
- ApplicationContext.cs
- LocalizableAttribute.cs
- KeyGestureValueSerializer.cs
- EncoderExceptionFallback.cs
- Rect3D.cs
- FormsAuthenticationModule.cs
- SiteMapPathDesigner.cs
- ZoneButton.cs
- LabelInfo.cs
- CreateUserWizard.cs
- QueryTaskGroupState.cs
- HtmlInputText.cs
- ProcessHostFactoryHelper.cs
- OleDbStruct.cs
- SharedStream.cs
- PersonalizationStateQuery.cs
- _TransmitFileOverlappedAsyncResult.cs
- FixedDocument.cs
- Selection.cs
- VisualBasicValue.cs
- VectorCollectionValueSerializer.cs
- CmsUtils.cs
- ElapsedEventArgs.cs
- Empty.cs
- PublishLicense.cs
- HMACRIPEMD160.cs
- TimeSpanSecondsConverter.cs
- TcpSocketManager.cs
- SQLInt64Storage.cs
- DeleteHelper.cs
- AnimatedTypeHelpers.cs
- SettingsPropertyValueCollection.cs
- LinkDescriptor.cs