Record Class BulkOperations.BulkPutResult<K>

java.lang.Object
java.lang.Record
cloud.opencode.base.cache.bulk.BulkOperations.BulkPutResult<K>
Type Parameters:
K - key type | 键类型
Record Components:
inserted - keys that were inserted | 插入的键
skipped - keys that were skipped | 跳过的键
Enclosing class:
BulkOperations<K,V>

public static record BulkOperations.BulkPutResult<K>(Set<K> inserted, Set<K> skipped) extends Record
Result of bulk put operation 批量放置操作的结果
Since:
JDK 25, opencode-base-cache V2.0.5
Author:
Leon Soo www.LeonSoo.com
  • Constructor Summary

    Constructors
    Constructor
    Description
    BulkPutResult(Set<K> inserted, Set<K> skipped)
    Creates an instance of a BulkPutResult record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    Returns the value of the inserted record component.
    int
    Returns the inserted count | 返回插入数
    Returns the value of the skipped record component.
    int
    Returns the skipped count | 返回跳过数
    final String
    Returns a string representation of this record class.
    int
    Returns the total count | 返回总数

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • BulkPutResult

      public BulkPutResult(Set<K> inserted, Set<K> skipped)
      Creates an instance of a BulkPutResult record class.
      Parameters:
      inserted - the value for the inserted record component
      skipped - the value for the skipped record component
  • Method Details

    • insertedCount

      public int insertedCount()
      Returns the inserted count | 返回插入数
      Returns:
      inserted count | 插入数
    • skippedCount

      public int skippedCount()
      Returns the skipped count | 返回跳过数
      Returns:
      skipped count | 跳过数
    • totalCount

      public int totalCount()
      Returns the total count | 返回总数
      Returns:
      total count | 总数
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • inserted

      public Set<K> inserted()
      Returns the value of the inserted record component.
      Returns:
      the value of the inserted record component
    • skipped

      public Set<K> skipped()
      Returns the value of the skipped record component.
      Returns:
      the value of the skipped record component