Examples of StructType


Examples of org.apache.spark.sql.api.java.StructType

  private JavaSchemaRDD artistsAsSchemaRDD() {
    String input = TestUtils.sampleArtistsDat();
    JavaRDD<String> data = sc.textFile(input);

    StructType schema = DataType
        .createStructType(new StructField[] {
            DataType.createStructField("id", DataType.IntegerType, false),
            DataType.createStructField("name", DataType.StringType, false),
            DataType.createStructField("url", DataType.StringType, true),
            DataType.createStructField("pictures", DataType.StringType, true),
View Full Code Here

Examples of org.jacorb.test.StructType

    * Tests creating a DynAny object from an Any object using the
    * DynAnyFactory object.
    */
   public void testFactoryCreateFromAny ()
   {
      StructType type = null;
      org.omg.CORBA.Any any = null;

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);

      createDynAnyFromAny (any);
   }
View Full Code Here

Examples of org.jacorb.test.StructType

    * Test comparing DynAny values.
    */
   public void testCompareDynAny ()
   {
      String msg;
      StructType type;
      org.omg.CORBA.Any any = null;
      org.omg.DynamicAny.DynStruct dynAny = null;
      org.omg.DynamicAny.DynStruct dynAny2 = null;

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny = createDynAnyFromAny (any);
      dynAny2 = createDynAnyFromAny (any);

View Full Code Here

Examples of org.jacorb.test.StructType

   {
      final String name1 = "field1"; // specific to IDL
      final String name2 = "field2"; // specific to IDL
      String msg;
      org.omg.CORBA.Any any = null;
      StructType type = null;
      int oldInt = 1;
      String oldStr = "Hello";
      int newInt = 2;
      String newStr = "GoodBye";
      org.omg.DynamicAny.DynStruct dynAny = null;
      org.omg.DynamicAny.NameValuePair [] pairs = null;

      type = new StructType (oldInt, oldStr);
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny = createDynAnyFromAny (any);

      // test extracting the name/value pairs as Anys
View Full Code Here

Examples of org.jacorb.test.StructType

   {
      final String name1 = "field1"; // specific to IDL
      final String name2 = "field2"; // specific to IDL
      String msg;
      org.omg.CORBA.Any any = null;
      StructType type = null;
      int oldInt = 1;
      String oldStr = "Hello";
      int newInt = 2;
      String newStr = "GoodBye";
      org.omg.DynamicAny.DynStruct dynAny = null;
      org.omg.DynamicAny.DynAny dynAny1 = null;
      org.omg.DynamicAny.DynAny dynAny2 = null;
      org.omg.DynamicAny.NameDynAnyPair [] pairs = null;

      type = new StructType (oldInt, oldStr);
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny = createDynAnyFromAny (any);

      // test extracting the name/value pairs as DynAnys
View Full Code Here

Examples of org.jacorb.test.StructType

    * Test initializing a DynAny object from another DynAny object.
    */
   public void testInitDynAnyFromDynAny ()
   {
      String msg;
      StructType type;
      org.omg.CORBA.Any any = null;
      org.omg.CORBA.TypeCode tc = null;
      org.omg.DynamicAny.DynStruct dynAny = null;
      org.omg.DynamicAny.DynStruct dynAny2 = null;

      tc = StructTypeHelper.type ();
      dynAny = createDynAnyFromTypeCode (tc);

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny2 = createDynAnyFromAny (any);

      msg = "Failed to initialize a DynAny object from another DynAny ";
View Full Code Here

Examples of org.jacorb.test.StructType

    * Test initializing a DynAny object from an Any value.
    */
   public void testInitDynAnyFromAny ()
   {
      String msg;
      StructType type;
      org.omg.CORBA.Any any = null;
      org.omg.CORBA.TypeCode tc = null;
      org.omg.DynamicAny.DynStruct dynAny = null;
      org.omg.DynamicAny.DynStruct dynAny2 = null;

      tc = StructTypeHelper.type ();
      dynAny = createDynAnyFromTypeCode (tc);

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny2 = createDynAnyFromAny (any);

      msg = "Failed to initialize a DynAny object from an Any object ";
View Full Code Here

Examples of org.jacorb.test.StructType

    * Test destroying a DynAny object.
    */
   public void testDestroyDynAny ()
   {
      String msg;
      StructType type;
      org.omg.CORBA.Any any = null;
      org.omg.DynamicAny.DynStruct dynAny = null;

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny = createDynAnyFromAny (any);
      dynAny.destroy ();

View Full Code Here

Examples of org.jacorb.test.StructType

    * Test destroying a component of a DynAny object.
    */
   public void testDestroyComponent ()
   {
      String msg;
      StructType type;
      org.omg.CORBA.Any any = null;
      org.omg.DynamicAny.DynStruct dynAny = null;
      org.omg.DynamicAny.DynAny comp = null;

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);
      dynAny = createDynAnyFromAny (any);

      try
View Full Code Here

Examples of org.jacorb.test.StructType

    * Tests creating a DynAny object from an Any object using the
    * DynAnyFactory object.
    */
   public void testFactoryCreateFromAny ()
   {
      StructType type = null;
      org.omg.CORBA.Any any = null;

      type = new StructType (1, "Hello");
      any = orb.create_any ();
      StructTypeHelper.insert (any, type);

      createDynAnyFromAny (any);
   }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.