Example #1
1
 public xxx m1(xxx x)
 {
     return new xxx();
 }
Example #2
0
        public static void Foo()
        {
            var items = new List <string>();

            int i = 0;

            while (i < items.Count)
            {
                items[i] = null;
                i++;
            }

            xxx j = 0;

            while (j < items.Count)
            {
                items[j] = null;
            }

            int k = 0;

            Foo();
            Foo();
            while (k < items.Count)
            {
                items[k] = null;
                k++;
            }
        }
Example #3
0
        /// <summary>
        /// Convert Spotfire xxx to parallel Mobius object
        /// </summary>
        /// <param name="s"></param>
        /// <returns></returns>

        public static xxxMsx Sx2Mx(
            xxx s)
        {
            xxxMsx m = null;

            throw new NotImplementedException();
        }
Example #4
0
File: test.cs Project: mono/gert
	public static unsafe void Convert (xxx* src, ulong* dest)
	{
		byte* pb = (byte*) dest;
		*dest = 0L;
		pb [0] = src->zzz [0];
		pb [1] = src->zzz [1];
		pb [2] = src->zzz [2];
		pb [3] = src->zzz [3];
		pb [4] = src->zzz [4];
	}
Example #5
0
File: test.cs Project: mono/gert
	public unsafe void CopyTo (xxx* dest)
	{
		fixed (ulong* p = &_rep) {
			byte* pb = (byte*) p;
			dest->zzz [0] = pb [0];
			dest->zzz [1] = pb [1];
			dest->zzz [2] = pb [2];
			dest->zzz [3] = pb [3];
			dest->zzz [4] = pb [4];
		}
	}
    static void Main(string[] args)
    {
        xxx instance = new xxx();

        instance.MyProperty = 100;     // This should print "NORMAL"
        // We serialize
        var serializer   = new XmlSerializer(typeof(xxx));
        var memoryStream = new MemoryStream();

        serializer.Serialize(memoryStream, instance);
        // Let's print our XML so we understand what's going on.
        memoryStream.Position = 0;
        var reader = new StreamReader(memoryStream);

        Console.WriteLine(reader.ReadToEnd());
        // Now we deserialize
        memoryStream.Position = 0;
        var deserialized = serializer.Deserialize(memoryStream) as xxx;     // This should print DESERIALIZED

        Console.ReadLine();
    }
Example #7
0
        public void ToList()
        {
            var sb   = new StringBuilder();
            var time = new Stopwatch();

            //var t31 = g.mysql.Select<xxx>().ToList();
            g.mysql.Select <xxx>().First();

            time.Restart();
            var t3 = g.mysql.Select <xxx>().ToList();

            time.Stop();
            sb.AppendLine($"Elapsed: {time.Elapsed}; ToList Entity Counts: {t3.Count}; ORM: FreeSql*");

            time.Restart();
            var adoarr1 = g.mysql.Ado.ExecuteArray("select * from freesql_song");

            time.Stop();
            sb.AppendLine($"Elapsed: {time.Elapsed}; ExecuteArray Entity Counts: {adoarr1.Length}; ORM: FreeSql ExecuteArray*");

            time.Restart();
            var adolist1 = new List <xxx>();

            g.mysql.Ado.ExecuteReader(fetch =>
            {
                var xim = new xxx();
                fetch.Object.GetValue(0);
                fetch.Object.GetValue(1);
                fetch.Object.GetValue(2);
                fetch.Object.GetValue(3);
                fetch.Object.GetValue(4);
                adolist1.Add(xim);
            }, "select * from freesql_song");
            time.Stop();
            sb.AppendLine($"Elapsed: {time.Elapsed}; ExecuteReader Entity Counts: {adolist1.Count}; ORM: FreeSql ExecuteReader*");

            time.Restart();
            adolist1 = new List <xxx>();
            g.mysql.Ado.ExecuteReader(fetch =>
            {
                var xim = new xxx();
                fetch.Object.GetFieldValue <int>(0);
                fetch.Object.GetFieldValue <DateTime>(1);
                fetch.Object.GetFieldValue <bool>(2);
                fetch.Object.GetFieldValue <string>(3);
                fetch.Object.GetFieldValue <string>(4);
                adolist1.Add(xim);
            }, "select * from freesql_song");
            time.Stop();
            sb.AppendLine($"Elapsed: {time.Elapsed}; ExecuteReader0000 Entity Counts: {adolist1.Count}; ORM: FreeSql ExecuteReader0000*");

            //time.Restart();
            //adolist1 = new List<xxx>();
            //g.mysql.Ado.ExecuteReader(dr =>
            //{
            //    var xim = new xxx();
            //    Utils.GetDataReaderValue(typeof(int), dr.GetValue(0));
            //    Utils.GetDataReaderValue(typeof(DateTime), dr.GetValue(1));
            //    Utils.GetDataReaderValue(typeof(bool), dr.GetValue(2));
            //    Utils.GetDataReaderValue(typeof(string), dr.GetValue(3));
            //    Utils.GetDataReaderValue(typeof(string), dr.GetValue(4));
            //    adolist1.Add(xim);
            //}, "select * from freesql_song");
            //time.Stop();
            //sb.AppendLine($"Elapsed: {time.Elapsed}; ExecuteReader1111 Entity Counts: {adolist1.Count}; ORM: FreeSql ExecuteReader1111*");


            time.Restart();
            List <xxx> dplist1 = null;

            using (var conn = g.mysql.Ado.MasterPool.Get())
            {
                dplist1 = Dapper.SqlMapper.Query <xxx>(conn.Value, "select * from freesql_song").ToList();
            }
            time.Stop();
            sb.AppendLine($"Elapsed: {time.Elapsed}; Query Entity Counts: {dplist1.Count}; ORM: Dapper");
        }
Example #8
0
 public yyy(xxx InstantiatedBy)
 {
     MyInstantiator = InstantiatedBy;
 }
Example #9
0
 public Class10(xxx e)
 {
 }
Example #10
0
 public xxx m1(xxx x)
 {
     return(new xxx());
 }
Example #11
0
        public Class10(xxx e)
        {

        }
Example #12
0
        /// <summary>
        /// Convert Mobius xxx to parallel Spotfire object
        /// </summary>
        /// <param name="m"></param>
        /// <param name="s"></param>

        public static void Mx2Sx(
            xxxMsx m,
            xxx s)
        {
            throw new NotImplementedException();
        }