@Test public void testToString() throws Exception { Assert.assertEquals("Hello SwitchYard", InputSourceTransforms.TRANSFORMER.toString(newInputSource("Hello SwitchYard"))); }
@Transformer public String toString(InputSource inSource) { Reader reader = inSource.getCharacterStream(); if (reader != null) { return ReaderTransforms.TRANSFORMER.toString(reader); } InputStream stream = inSource.getByteStream(); if (stream != null) { return InputStreamTransforms.TRANSFORMER.toString(stream); } return null; }
InputSourceTransforms { @Transformer public String toString(InputSource inSource) { Reader reader = inSource.getCharacterStream(); if (reader != null) { return ReaderTransforms.TRANSFORMER.toString(reader); } InputStream stream = inSource.getByteStream(); if (stream != null) { return InputStreamTransforms.TRANSFORMER.toString(stream); } return null; } }
InputSourceTransforms { @Transformer public String toString(InputSource inSource) { Reader reader = inSource.getCharacterStream(); if (reader != null) { return ReaderTransforms.TRANSFORMER.toString(reader); } InputStream stream = inSource.getByteStream(); if (stream != null) { return InputStreamTransforms.TRANSFORMER.toString(stream); } return null; }  }
InputSourceTransforms { @Transformer public String toString(InputSource inSource) { Reader reader = inSource.getCharacterStream(); if (reader != null) { return ReaderTransforms.TRANSFORMER.toString(reader); } InputStream stream = inSource.getByteStream(); if (stream != null) { return InputStreamTransforms.TRANSFORMER.toString(stream); } return null; }  @Transformer String toString(InputSource inSource); @Transformer Reader toReader(InputSource inSource); @Transformer InputStream toInputStream(InputSource inSource); @Transformer Integer toInteger(InputSource inSource); @Transformer Long toLong(InputSource inSource); @Transformer Short toShort(InputSource inSource); @Transformer char[] toChars(InputSource inSource); @Transformer Character toCharacter(InputSource inSource); @Transformer byte[] toBytes(InputSource inSource); @Transformer Double toDouble(InputSource inSource); @Transformer Float toFloat(InputSource inSource); }
InputSourceTransforms { @Transformer public String toString(InputSource inSource) { Reader reader = inSource.getCharacterStream(); if (reader != null) { return ReaderTransforms.TRANSFORMER.toString(reader); } InputStream stream = inSource.getByteStream(); if (stream != null) { return InputStreamTransforms.TRANSFORMER.toString(stream); } return null; }  @Transformer String toString(InputSource inSource); @Transformer Reader toReader(InputSource inSource); @Transformer InputStream toInputStream(InputSource inSource); @Transformer Integer toInteger(InputSource inSource); @Transformer Long toLong(InputSource inSource); @Transformer Short toShort(InputSource inSource); @Transformer char[] toChars(InputSource inSource); @Transformer Character toCharacter(InputSource inSource); @Transformer byte[] toBytes(InputSource inSource); @Transformer Double toDouble(InputSource inSource); @Transformer Float toFloat(InputSource inSource); static final InputSourceTransforms TRANSFORMER; }