@Override
        public <T extends Message<T>> byte[] serialize(T message)
        {
            try
            {
                final ByteArrayOutputStream out = new ByteArrayOutputStream();
                YamlIOUtil.writeTo(out, message, message.cachedSchema(), buffer);
                return out.toByteArray();
            }
            catch (IOException e)
            {
                throw new RuntimeException(e);
            }
            finally
            {
                buffer.clear();
            }
        }
Compare the outputs of different yaml impls.

@author David Yu
@created Jul 9, 2010
protostuff-yaml/src/test/java/io/protostuff/YamlCompareOutputsTest.java