本文整理汇总了C#中ILocator类的典型用法代码示例。如果您正苦于以下问题:C# ILocator类的具体用法?C# ILocator怎么用?C# ILocator使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ILocator类属于命名空间,在下文中一共展示了ILocator类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Prepare
/// <inheritdoc />
public virtual void Prepare(ILocator locator)
{
if (!this.IsInitialized || this.IsPrepared)
throw new InvalidOperationException();
this.Locator = locator;
this.IsPrepared = true;
}
示例2: DetectAndHashJob
public DetectAndHashJob(JobDescriptor jobDescription, Guid workerId, ILocator locator) :
base(jobDescription, workerId, locator)
{
_codeLocationRepository = _serviceLocator.Locate<ICodeLocationRepository>();
_fileRepository = _serviceLocator.Locate<IFileRepository>();
_repositoryController = _serviceLocator.Locate<IRepositoryController>();
}
示例3: EncodeJobNotification
public EncodeJobNotification(IJob[] jobsReady, string OriginalAssetName, ILocator[] Locators, string UrlForClientStreaming)
{
myJobList = jobsReady;
myAssetName = OriginalAssetName;
myLocators = Locators;
myUrlForClientStreaming = UrlForClientStreaming;
}
示例4: ToggleButtonHandle
public ToggleButtonHandle(Figure owner, ILocator locator)
: base(owner, locator)
{
FillColor = new Color (1, 1, 0.0, 0.3);
Width = 15.0;
Height = 15.0;
}
示例5: ButtonHandle
public ButtonHandle(IFigure owner, ILocator locator, kindButton type)
: base(owner)
{
_locator = locator;
_clicked = false;
typeButton = type;
}
示例6: SAXParseException
/// <summary>
/// Wrap an existing exception in a SAXParseException.
/// <para>
/// This constructor is especially useful when an application is
/// creating its own exception from within a <see cref="org.xml.sax.ContentHandler" /> callback,
/// and needs to wrap an existing exception that is not a
/// subclass of <see cref="SAXException" />.
/// </para>
/// </summary>
/// <param name="message">
/// The error or warning message, or null to
/// use the message from the embedded exception.
/// </param>
/// <param name="locator">
/// The locator object for the error or warning (may be null).
/// </param>
/// <param name="ex">Any exception.</param>
/// <seealso cref="ILocator" />
public SAXParseException(string message, ILocator locator, Exception ex) : base(message, ex) {
if (locator != null) {
Init(locator.PublicId, locator.SystemId, locator.LineNumber, locator.ColumnNumber);
} else {
Init(null, null, -1, -1);
}
}
示例7: ServiceConfiguration
public ServiceConfiguration(ILocator locator, ICollection<RouteBase> routes, string[] allowedSchemes, Type contractType, Type serviceType)
{
this.locator = locator;
this.routes = routes;
this.allowedSchemes = allowedSchemes;
this.contractType = contractType;
this.serviceType = serviceType;
}
示例8: Locator2
////
/// <summary>
/// Copy an existing Locator or Locator2 object.
/// If the object implements Locator2, values of the
/// <em>encoding</em> and <em>version</em>strings are copied,
/// otherwise they set to <em>null</em>.
/// </summary>
/// <param name="locator">
/// The existing Locator object.
/// </param>
public Locator2(ILocator locator) : base(locator) {
if (locator is ILocator2) {
var l2 = (ILocator2)locator;
_version = l2.XmlVersion;
_encoding = l2.Encoding;
}
}
示例9: ProjectionGatewayConfigurationBuilder
private ProjectionGatewayConfigurationBuilder(ILocator locator)
{
_locator = locator;
var stringEqComparer = EqualityComparerFactory.Create<string>(
(x, y) => x.ToLower() == y.ToLower(),
s => s.GetHashCode());
Subscriptions = new MultiValueDictionary<string, Subscription>(stringEqComparer);
}
示例10: TransformHandle
public TransformHandle(MoonlightController controller, IHandleGroup group, ILocator locator)
: base(controller, group)
{
Locator = locator;
rotation = new RotateTransform();
Transforms.Children.Add(rotation);
}
示例11: LocatorServiceHostFactory
public LocatorServiceHostFactory(
ServiceHostConfigurator configurator,
ILocator locator,
string[] allowedSchemes)
{
this.configurator = configurator;
this.locator = locator;
this.allowedSchemes = allowedSchemes;
}
示例12: GatewayConfiguration
public GatewayConfiguration(IReadOnlyCollection<Host> hosts, UserCrenedtial userCredential, ILocator locator, int prefetchCount, int eventSubscriberThreadCount, int commandHandlerThreadCount)
{
Hosts = hosts;
UserCrenedtial = userCredential;
Locator = locator;
PrefetchCount = prefetchCount;
EventSubscriberThreadCount = eventSubscriberThreadCount;
CommandHandlerThreadCount = commandHandlerThreadCount;
}
示例13: GetLocator
public static ILocator GetLocator()
{
if (locator == null)
{
locator = new DefaultLocator(new DefaultFactoryMethodFactory());
RegisterAbstractions(locator);
}
return locator;
}
示例14: JobPoller
public JobPoller(WorkloadPresenter presenter, ILocator locator, WorkerState worker, int? intervalSeconds = null)
{
_interval = intervalSeconds ?? _interval;
_presenter = presenter;
_jobRepository = locator.Locate<IJobRepository>();
_worker = worker;
_serviceLocator = locator;
}
示例15: ContractBehavior
private IContractBehavior ContractBehavior(ILocator locator, Type serviceType)
{
var provider =
locator.IsRegistered(contractType) ?
(IContractBehavior)new LocatorInstanceProvider(locator, contractType) :
new ActivatorInstanceProvider(serviceType);
return provider;
}