本文整理汇总了C#中SystemId.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# SystemId.ToString方法的具体用法?C# SystemId.ToString怎么用?C# SystemId.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SystemId
的用法示例。
在下文中一共展示了SystemId.ToString方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SystemIdUriConstructorTest
public void SystemIdUriConstructorTest()
{
var _SystemId = new SystemId(new Uri("http://example.org"));
Assert.AreEqual("http://example.org/", _SystemId.ToString());
Assert.AreEqual(19, _SystemId.Length);
}
示例2: SystemIdUInt64ConstructorTest
public void SystemIdUInt64ConstructorTest()
{
var _SystemId = new SystemId(123UL);
Assert.AreEqual("123", _SystemId.ToString());
Assert.AreEqual(3, _SystemId.Length);
}
示例3: SystemIdUInt32ConstructorTest
public void SystemIdUInt32ConstructorTest()
{
var _SystemId = new SystemId(23U);
Assert.AreEqual("23", _SystemId.ToString());
Assert.AreEqual(2, _SystemId.Length);
}
示例4: SystemIdSystemIdConstructorTest
public void SystemIdSystemIdConstructorTest()
{
var _SystemId1 = SystemId.NewSystemId;
var _SystemId2 = new SystemId(_SystemId1);
Assert.AreEqual(_SystemId1.ToString(), _SystemId2.ToString());
Assert.AreEqual(_SystemId1.Length, _SystemId2.Length);
Assert.AreEqual(_SystemId1, _SystemId2);
}
示例5: SystemIdInt64ConstructorTest
public void SystemIdInt64ConstructorTest()
{
var _SystemId = new SystemId(42L);
Assert.AreEqual("42", _SystemId.ToString());
Assert.AreEqual(2, _SystemId.Length);
}
示例6: SystemIdInt32ConstructorTest
public void SystemIdInt32ConstructorTest()
{
var _SystemId = new SystemId(5);
Assert.AreEqual("5", _SystemId.ToString());
Assert.AreEqual(1, _SystemId.Length);
}