Ejemplo n.º 1
0
        public override void write(Object obj1, BOutput bout1, long version)
        {
            MapTypes   obj  = (MapTypes)obj1;
            BOutputBin bout = (BOutputBin)bout1;
            BBufferBin bbuf = bout.bbuf;

            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Boolean1, false, byps.test.api.BSerializer_1279823631.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Byte1, false, byps.test.api.BSerializer_1972793385.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Byte2, false, byps.test.api.BSerializer_1799280818.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Char1, false, byps.test.api.BSerializer_8789515.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Date1, false, byps.test.api.BSerializer_1366799209.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Double1, false, byps.test.api.BSerializer_1487265161.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Float1, false, byps.test.api.BSerializer_94341197.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Int1, false, byps.test.api.BSerializer_1347703734.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Int2, false, byps.test.api.BSerializer_1633750383.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Long1, false, byps.test.api.BSerializer_1973996106.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Obj1, false, byps.test.api.BSerializer_1488550492.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.PrimitiveTypes1, false, byps.test.api.BSerializer_1831201218.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.Short1, false, byps.test.api.BSerializer_601099730.instance);
            // checkpoint byps.gen.cs.PrintContext:494
            bout.writeObj(obj.String1, false, byps.test.api.BSerializer_1710660846.instance);
        }
Ejemplo n.º 2
0
		public MapTypes(MapTypes rhs)
		{
			this.boolean1Value = rhs.boolean1Value;
			this.byte1Value = rhs.byte1Value;
			this.char1Value = rhs.char1Value;
			this.short1Value = rhs.short1Value;
			this.int1Value = rhs.int1Value;
			this.long1Value = rhs.long1Value;
			this.float1Value = rhs.float1Value;
			this.double1Value = rhs.double1Value;
			this.string1Value = rhs.string1Value;
			this.primitiveTypes1Value = rhs.primitiveTypes1Value;
			this.byte2Value = rhs.byte2Value;
			this.int2Value = rhs.int2Value;
			this.obj1Value = rhs.obj1Value;
			this.date1Value = rhs.date1Value;
		}		
Ejemplo n.º 3
0
 public MapTypes(MapTypes rhs)
 {
     this.boolean1Value        = rhs.boolean1Value;
     this.byte1Value           = rhs.byte1Value;
     this.char1Value           = rhs.char1Value;
     this.short1Value          = rhs.short1Value;
     this.int1Value            = rhs.int1Value;
     this.long1Value           = rhs.long1Value;
     this.float1Value          = rhs.float1Value;
     this.double1Value         = rhs.double1Value;
     this.string1Value         = rhs.string1Value;
     this.primitiveTypes1Value = rhs.primitiveTypes1Value;
     this.byte2Value           = rhs.byte2Value;
     this.int2Value            = rhs.int2Value;
     this.obj1Value            = rhs.obj1Value;
     this.date1Value           = rhs.date1Value;
 }
Ejemplo n.º 4
0
        public void testRemoteMapTypes() {
		    log.info("testRemoteMapTypes(");
		
		    MapTypes obj = new MapTypes();
		    obj.Boolean1 = new MyMap<String,bool>().add("bool1", true).add("bool2", false);
		    obj.Byte1 = new MyMap<double,byte>().add(1.0, (byte)1).add(2.0, (byte)2);
		    obj.Char1 = new MyMap<float, char>().add(-1.0f, 'a').add(1.0e-1f, 'b');
		    obj.Double1 = new MyMap<byte, double>().add((byte)3, -1.0e12);
		    obj.Float1 = new MyMap<char, float>().add('A', 1.0f).add('¶', 2.0f).add('€', -1.2468e-3f);
		    obj.Int1 = new MyMap<int, int>().add(1,2).add(2, 3);
		    obj.Long1 = new MyMap<short, long>().add((short)99, 33L).add((short)-99, -33L);
		    obj.PrimitiveTypes1 = new MyMap<int, PrimitiveTypes>().add(1, TestUtils.createObjectPrimitiveTypes()).add(2, TestUtils.createObjectPrimitiveTypes());
		    obj.Short1 = new MyMap<long, short>().add(-55L, (short)1234).add(0x5555555555555555L, (short)5555);
            obj.Date1 = new MyMap<string, DateTime>().add("A", new DateTime(1600, 1, 2, 3, 4, 5, 6));
		    obj.String1 = new MyMap<String, String>().add("A", "a").add("B","b");

		    remote.SetBoolean1(obj.Boolean1);
		    TestUtils.assertEquals(log, "boolean1", obj.Boolean1, remote.GetBoolean1());
		    remote.SetByte1(obj.Byte1);
		    TestUtils.assertEquals(log, "byte1", obj.Byte1, remote.GetByte1());
		    remote.SetChar1(obj.Char1);
		    TestUtils.assertEquals(log, "char1", obj.Char1, remote.GetChar1());
		    remote.SetDouble1(obj.Double1);
		    TestUtils.assertEquals(log, "double1", obj.Double1, remote.GetDouble1());
		    remote.SetFloat1(obj.Float1);
		    TestUtils.assertEquals(log, "float1", obj.Float1, remote.GetFloat1());
		    remote.SetInt1(obj.Int1);
		    TestUtils.assertEquals(log, "int1", obj.Int1, remote.GetInt1());
		    remote.SetLong1(obj.Long1);
		    TestUtils.assertEquals(log, "long1", obj.Long1, remote.GetLong1());
		    remote.SetPrimitiveTypes1(obj.PrimitiveTypes1);
		    TestUtils.assertEquals(log, "primitiveTypes1", obj.PrimitiveTypes1, remote.GetPrimitiveTypes1());
		    remote.SetShort1(obj.Short1);
		    TestUtils.assertEquals(log, "short1", obj.Short1, remote.GetShort1());
		    remote.SetString1(obj.String1);
            TestUtils.assertEquals(log, "string1", obj.String1, remote.GetString1());/* USE THIS FILE ACCORDING TO THE COPYRIGHT RULES IN LICENSE.TXT WHICH IS PART OF THE SOURCE CODE PACKAGE */

            remote.SetDate1(obj.Date1);
            TestUtils.assertEquals(log, "date1", obj.Date1, remote.GetDate1());
		
		    log.info(")testRemoteMapTypes");
	    }
Ejemplo n.º 5
0
        public override Object read(Object obj1, BInput bin1, long version)
        {
            BInputBin bin = (BInputBin)bin1;
            MapTypes  obj = (MapTypes)(obj1 != null ? obj1 : bin.onObjectCreated(new MapTypes()));

            BBufferBin bbuf = bin.bbuf;

            // checkpoint byps.gen.cs.PrintContext:449
            obj.Boolean1 = (IDictionary <String, bool>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Byte1 = (Dictionary <double, byte>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Byte2 = (IDictionary <int, byte[]>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Char1 = (Dictionary <float, char>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Date1 = (IDictionary <String, DateTime>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Double1 = (IDictionary <byte, double>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Float1 = (IDictionary <char, float>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Int1 = (IDictionary <int, int>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Int2 = (IDictionary <int, int[]>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Long1 = (IDictionary <short, long>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Obj1 = (IDictionary <String, Object>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.PrimitiveTypes1 = (IDictionary <int, byps.test.api.prim.PrimitiveTypes>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.Short1 = (IDictionary <long, short>)bin.readObj(false, null);
            // checkpoint byps.gen.cs.PrintContext:449
            obj.String1 = (IDictionary <String, String>)bin.readObj(false, null);

            return(obj);
        }