org.apache.hadoop.io.TestGenericWritable.Baz Java Examples

The following examples show how to use org.apache.hadoop.io.TestGenericWritable.Baz. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: TestWritableSerialization.java    From hadoop with Apache License 2.0 6 votes vote down vote up
@Test
public void testWritableConfigurable() throws Exception {
  
  //set the configuration parameter
  conf.set(CONF_TEST_KEY, CONF_TEST_VALUE);

  //reuse TestGenericWritable inner classes to test 
  //writables that also implement Configurable.
  FooGenericWritable generic = new FooGenericWritable();
  generic.setConf(conf);
  Baz baz = new Baz();
  generic.set(baz);
  Baz result = SerializationTestUtil.testSerialization(conf, baz);
  assertEquals(baz, result);
  assertNotNull(result.getConf());
}
 
Example #2
Source File: TestWritableSerialization.java    From big-c with Apache License 2.0 6 votes vote down vote up
@Test
public void testWritableConfigurable() throws Exception {
  
  //set the configuration parameter
  conf.set(CONF_TEST_KEY, CONF_TEST_VALUE);

  //reuse TestGenericWritable inner classes to test 
  //writables that also implement Configurable.
  FooGenericWritable generic = new FooGenericWritable();
  generic.setConf(conf);
  Baz baz = new Baz();
  generic.set(baz);
  Baz result = SerializationTestUtil.testSerialization(conf, baz);
  assertEquals(baz, result);
  assertNotNull(result.getConf());
}
 
Example #3
Source File: TestWritableSerialization.java    From RDFS with Apache License 2.0 5 votes vote down vote up
public void testWritableConfigurable() throws Exception {
  
  //set the configuration parameter
  conf.set(CONF_TEST_KEY, CONF_TEST_VALUE);

  //reuse TestGenericWritable inner classes to test 
  //writables that also implement Configurable.
  FooGenericWritable generic = new FooGenericWritable();
  generic.setConf(conf);
  Baz baz = new Baz();
  generic.set(baz);
  Baz result = testSerialization(conf, baz);
  assertNotNull(result.getConf());
}
 
Example #4
Source File: TestWritableSerialization.java    From hadoop-gpu with Apache License 2.0 5 votes vote down vote up
public void testWritableConfigurable() throws Exception {
  
  //set the configuration parameter
  conf.set(CONF_TEST_KEY, CONF_TEST_VALUE);

  //reuse TestGenericWritable inner classes to test 
  //writables that also implement Configurable.
  FooGenericWritable generic = new FooGenericWritable();
  generic.setConf(conf);
  Baz baz = new Baz();
  generic.set(baz);
  Baz result = testSerialization(conf, baz);
  assertNotNull(result.getConf());
}