Java Code Examples for com.google.common.primitives.Longs.stringConverter()

The following are Jave code examples for showing how to use stringConverter() of the com.google.common.primitives.Longs class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
Example 1
Project: guava-mock   File: ConverterTest.java   Source Code and License Vote up 4 votes
public void testSerialization_andThen() {
  Converter<String, Long> converterA = Longs.stringConverter();
  Converter<Long, String> reverseConverter = Longs.stringConverter().reverse();
  Converter<String, String> composedConverter = converterA.andThen(reverseConverter);
  SerializableTester.reserializeAndAssert(composedConverter);
}
 
Example 2
Project: googles-monorepo-demo   File: ConverterTest.java   Source Code and License Vote up 4 votes
public void testSerialization_andThen() {
  Converter<String, Long> converterA = Longs.stringConverter();
  Converter<Long, String> reverseConverter = Longs.stringConverter().reverse();
  Converter<String, String> composedConverter = converterA.andThen(reverseConverter);
  SerializableTester.reserializeAndAssert(composedConverter);
}