クラス EntityModel<T>


public class EntityModel<T> extends RepresentationModel<EntityModel<T>>
ドメインオブジェクトをラップしてリンクを追加する単純な EntityModel
作成者:
Oliver Gierke, Greg Turnquist
  • コンストラクターの詳細

    • EntityModel

      protected EntityModel()
      空の EntityModel を作成します。
    • EntityModel

      protected EntityModel(T content)
    • EntityModel

      protected EntityModel(T content, IterableSE<Link> links)
      指定されたコンテンツと Link で新しい EntityModel を作成します。
      パラメーター:
      content - null であってはなりません。
      links - EntityModel に追加するリンク。
  • メソッドの詳細

    • of

      public static <T> EntityModel<T> of(T content)
      指定されたコンテンツで新しい EntityModel を作成します。
      パラメーター:
      content - null であってはなりません。
      戻り値:
      導入:
      1.1
    • of

      public static <T> EntityModel<T> of(T content, Link... links)
      指定されたコンテンツと Link で新しい EntityModel を作成します (オプション)。
      パラメーター:
      content - null であってはなりません。
      links - EntityModel に追加するリンク。
      戻り値:
      導入:
      1.1
    • of

      public static <T> EntityModel<T> of(T content, IterableSE<Link> links)
      指定されたコンテンツと Link で新しい EntityModel を作成します。
      パラメーター:
      content - null であってはなりません。
      links - EntityModel に追加するリンク。
      戻り値:
      導入:
      1.1
    • getContent

      @Nullable public T getContent()
      基になるエンティティを返します。
      戻り値:
      コンテンツ
    • toString

      public StringSE toString()
      オーバーライド:
      クラス RepresentationModel<EntityModel<T>>toString 
    • equals

      public boolean equals(@Nullable ObjectSE obj)
      オーバーライド:
      クラス RepresentationModel<EntityModel<T>>equals 
    • hashCode

      public int hashCode()
      オーバーライド:
      クラス RepresentationModel<EntityModel<T>>hashCode