com.hazelcast.client.proxy.txn

## Class ClientTxnListProxy<E>

- java.lang.Object
- - com.hazelcast.client.proxy.txn.ClientTxnListProxy<E>

- Type Parameters:
    `E` - the type of elements in this list
  All Implemented Interfaces:
    DistributedObject, TransactionalList<E>, TransactionalObject

      public class ClientTxnListProxy<E>
      extends Object
      implements TransactionalList<E>

  Proxy implementation of `TransactionalList`.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ClientTxnListProxy(String name, ClientTransactionContext transactionContext)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `add(E e)` Adds a new item to the transactional list.
    `void` | `destroy()` Destroys this object cluster-wide.
    `String` | `getName()` Returns the unique name for this DistributedObject.
    `String` | `getPartitionKey()` Returns the key of the partition that this DistributedObject is assigned to.
    `String` | `getServiceName()` Returns the service name for this object.
    `boolean` | `remove(E e)` Removes an item from the transactional list.
    `int` | `size()` Returns the size of the list.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface com.hazelcast.core.DistributedObject

      `destroy, getName, getPartitionKey`

- - ### Constructor Detail

    - #### ClientTxnListProxy

          public ClientTxnListProxy(String name,
                                    ClientTransactionContext transactionContext)

  - ### Method Detail

    - #### getServiceName

          public String getServiceName()

      Description copied from interface: `DistributedObject`
      Returns the service name for this object.
      Specified by:
        `getServiceName` in interface `DistributedObject`
      Returns:
        the service name for this object.

    - #### add

          public boolean add(E e)

      Description copied from interface: `TransactionalList`
      Adds a new item to the transactional list.
      Specified by:
        `add` in interface `TransactionalList<E>`
      Parameters:
        `e` - the new item added to the transactional list
      Returns:
        `true` if the item is added successfully

    - #### remove

          public boolean remove(E e)

      Description copied from interface: `TransactionalList`
      Removes an item from the transactional list.
      Specified by:
        `remove` in interface `TransactionalList<E>`
      Parameters:
        `e` - item to remove the transactional list
      Returns:
        `true` if the item is removed successfully

    - #### size

          public int size()

      Description copied from interface: `TransactionalList`
      Returns the size of the list.
      Specified by:
        `size` in interface `TransactionalList<E>`
      Returns:
        the size of the list

    - #### getName

          public String getName()

      Description copied from interface: `DistributedObject`
      Returns the unique name for this DistributedObject. The returned value will never be null. The suggested way for getting name is retrieving it through `DistributedObjectUtil.getName(DistributedObject)` because this might be also a `PrefixedDistributedObject`.
      Specified by:
        `getName` in interface `DistributedObject`
      Returns:
        the unique name for this object.

    - #### getPartitionKey

          public String getPartitionKey()

      Description copied from interface: `DistributedObject`
      Returns the key of the partition that this DistributedObject is assigned to. The returned value only has meaning for a non-partitioned data structure like an `IAtomicLong`. For a partitioned data structure like an `IMap`, the returned value will not be null, but otherwise undefined.
      Specified by:
        `getPartitionKey` in interface `DistributedObject`
      Returns:
        the partition key.

    - #### destroy

          public final void destroy()

      Description copied from interface: `DistributedObject`
      Destroys this object cluster-wide. Clears and releases all resources for this object.
      Specified by:
        `destroy` in interface `DistributedObject`

Copyright © 2020. All rights reserved.