org.apache.activemq.artemis.utils.Base64.encodeObject()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(5.6k)|赞(0)|评价(0)|浏览(253)

本文整理了Java中org.apache.activemq.artemis.utils.Base64.encodeObject()方法的一些代码示例,展示了Base64.encodeObject()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Base64.encodeObject()方法的具体详情如下:
包路径:org.apache.activemq.artemis.utils.Base64
类名称:Base64
方法名:encodeObject

Base64.encodeObject介绍

[英]Serializes an object and returns the Base64-encoded version of that serialized object. If the object cannot be serialized or there is another error, the method will return null. The object is not GZip-compressed before being encoded.
[中]序列化对象并返回该序列化对象的Base64编码版本。如果对象无法序列化或存在其他错误,则该方法将返回null。该对象在编码之前未进行GZip压缩。

代码示例

代码示例来源:origin: wildfly/wildfly

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: wildfly/wildfly

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

代码示例来源:origin: apache/activemq-artemis

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: org.apache.activemq/artemis-commons

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: org.apache.activemq/artemis-jms-client-all

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: apache/activemq-artemis

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: apache/activemq-artemis

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: org.jboss.eap/wildfly-client-all

  1. /**
  2. * Serializes an object and returns the Base64-encoded
  3. * version of that serialized object. If the object
  4. * cannot be serialized or there is another error,
  5. * the method will return <tt>null</tt>.
  6. * The object is not GZip-compressed before being encoded.
  7. *
  8. * @param serializableObject The object to encode
  9. * @return The Base64-encoded object
  10. * @since 1.4
  11. */
  12. public static String encodeObject(final java.io.Serializable serializableObject) {
  13. return Base64.encodeObject(serializableObject, Base64.NO_OPTIONS);
  14. } // end encodeObject

代码示例来源:origin: apache/activemq-artemis

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

代码示例来源:origin: apache/activemq-artemis

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

代码示例来源:origin: apache/activemq-artemis

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

代码示例来源:origin: org.apache.activemq/artemis-jms-client-all

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

代码示例来源:origin: org.apache.activemq/artemis-core-client

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

代码示例来源:origin: org.jboss.eap/wildfly-client-all

  1. JsonArrayBuilder innerJsonArray = JsonLoader.createArrayBuilder();
  2. for (Object data : innerArray) {
  3. String s = Base64.encodeObject((CompositeDataSupport) data);
  4. innerJsonArray.add(s);

相关文章