33 lines
762 B
C#
33 lines
762 B
C#
using System;
|
|
|
|
namespace SmallInjectorDemo
|
|
{
|
|
/// <inheritdoc />
|
|
/// <summary>
|
|
/// Implementation of <see cref="T:SmallInjectorDemo.IServiceTwo" />.
|
|
/// </summary>
|
|
public class ServiceTwo : IServiceTwo
|
|
{
|
|
private readonly int _id;
|
|
|
|
/// <summary>
|
|
/// Creates a new instance of <see cref="ServiceTwo"/>.
|
|
/// </summary>
|
|
public ServiceTwo()
|
|
{
|
|
_id = Helper.NewRandomInteger(10, 99);
|
|
Console.WriteLine(Helper.WriteMethodString(_id));
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
public override string ToString() => Helper.WriteMethodString(_id);
|
|
}
|
|
|
|
/// <summary>
|
|
/// Interface for service two.
|
|
/// </summary>
|
|
public interface IServiceTwo
|
|
{
|
|
|
|
}
|
|
} |