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

cn.binarywang.wx.miniapp.bean.cloud.WxCloudDatabaseCreateIndexRequest Maven / Gradle / Ivy

There is a newer version: 4.6.7.B
Show newest version
package cn.binarywang.wx.miniapp.bean.cloud;

import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.List;

/**
 * 云开发新增索引的请求对象.
 *
 * @author Binary Wang
 * created on  2020-01-26
 */
@Accessors(chain = true)
@Data
public class WxCloudDatabaseCreateIndexRequest implements Serializable {
  private static final long serialVersionUID = -8308393731157121109L;

  /**
   * name	string		是	索引名
   */
  private String name;

  /**
   * unique	boolean		是	是否唯一
   */
  private boolean unique;

  /**
   * keys	Array.		是	索引字段
   */
  private List keys;

  @Data
  @Accessors(chain = true)
  public static class IndexKey implements Serializable {
    private static final long serialVersionUID = -252641130547960325L;

    /**
     * name	string		是	字段名
     */
    private String name;

    /**
     * direction	string		是	字段排序
     * 
     *   direction 的合法值
     * 值	说明
     * "1"	升序
     * "-1"	降序
     * "2dsphere"	地理位置
     *
     * 
*/ private String direction; } }