All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.edgar615.util.vertx.spi.JsonObjectCodec Maven / Gradle / Ivy

The newest version!
package com.github.edgar615.util.vertx.spi;

import io.vertx.core.json.JsonObject;

/**
 * 对象与JsonObject之间的转换.
 *
 * @author Edgar  Date 2016/10/21
 */
public interface JsonObjectCodec {

  /**
   * 将Json转换为对象 .
   *
   * @param jsonObject json
   * @return 对象
   */
  T decode(JsonObject jsonObject);

  /**
   * 将一个对象转换为json
   *
   * @param obj 需要转换的对象.
   * @return json
   */
  JsonObject encode(T obj);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy