Ejemplo n.º 1
0
    public void RawClone()
    {
      JRaw r1 = new JRaw("raw1");
      JToken r2 = r1.CloneToken();

      CustomAssert.IsInstanceOfType(typeof(JRaw), r2);
    }
Ejemplo n.º 2
0
        public void RawToObject()
        {
            JRaw r1 = new JRaw("1");
            int i = r1.ToObject<int>();

            Assert.AreEqual(1, i);
        }
Ejemplo n.º 3
0
    public void RawEquals()
    {
      JRaw r1 = new JRaw("raw1");
      JRaw r2 = new JRaw("raw1");
      JRaw r3 = new JRaw("raw2");

      Assert.IsTrue(JToken.DeepEquals(r1, r2));
      Assert.IsFalse(JToken.DeepEquals(r1, r3));
    }
Ejemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="JRaw"/> class from another <see cref="JRaw"/> object.
 /// </summary>
 /// <param name="other">A <see cref="JRaw"/> object to copy from.</param>
 public JRaw(JRaw other)
   : base(other)
 {
 }