Package org.springmodules.javaspaces

Examples of org.springmodules.javaspaces.JavaSpaceCallback


   * @param enable if true this proxy FIFO enabled, otherwise false.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#setFifo(boolean)}
   */
  public void setFifo(final boolean enable)
  {
    execute(new JavaSpaceCallback() {
      public Object doInSpace(JavaSpace js, Transaction tx) throws RemoteException{
        ((IJSpace)js).setFifo(enable);
        return null;
      }
    });
View Full Code Here


   * @return Returns true if this proxy FIFO enabled, otherwise false.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#isFifo()}
   */
  public boolean isFifo()
  {
    return ((Boolean) execute(new JavaSpaceCallback() {
      public Object doInSpace(JavaSpace js, Transaction tx) throws RemoteException{
        return new Boolean(((IJSpace)js).isFifo());
      }
    })).booleanValue();
  }
View Full Code Here

   * @param enable noWriteLeaseMode - write mode.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#setNOWriteLeaseMode(boolean)}
   */
  public void setNOWriteLeaseMode(final boolean enable)
  {
    execute(new JavaSpaceCallback() {
      public Object doInSpace(JavaSpace js, Transaction tx) throws RemoteException{
        ((IJSpace)js).setNOWriteLeaseMode(enable);
        return null;
      }
    });
View Full Code Here

   * @return true if do not return Lease object after write, otherwise false.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#isNOWriteLeaseMode()}
   */
  public boolean isNOWriteLeaseMode()
  {
    return ((Boolean) execute(new JavaSpaceCallback() {
      public Object doInSpace(JavaSpace js, Transaction tx) throws RemoteException{
        return new Boolean(((IJSpace)js).isNOWriteLeaseMode());
      }
    })).booleanValue();
  }
View Full Code Here

   * @return old value of modifiers.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#setUpdateModifiers(int)}
   */
  public int setUpdateModifiers(final int newModifiers)
  {
    return ((Integer) execute(new JavaSpaceCallback() {
      public Object doInSpace(JavaSpace js, Transaction tx) throws RemoteException{
        return new Integer(((IJSpace)js).setUpdateModifiers(newModifiers));
      }
    })).intValue();
  }
View Full Code Here

   * @return value of modifiers.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#getUpdateModifiers()}
   */
  public int getUpdateModifiers()
  {
    return ((Integer) execute(new JavaSpaceCallback()
    {
      public Object doInSpace(JavaSpace js, Transaction tx)
          throws RemoteException
      {
        return new Integer(((IJSpace) js).getUpdateModifiers());
View Full Code Here

   * @return old value of modifiers.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#setReadTakeModifiers(int)}
   */
  public int setReadTakeModifiers(final int newModifiers)
  {
    return ((Integer) execute(new JavaSpaceCallback() {
      public Object doInSpace(JavaSpace js, Transaction tx) throws RemoteException{
        return new Integer(((IJSpace)js).setReadTakeModifiers(newModifiers));
      }
    })).intValue();
  }
View Full Code Here

   * @return value of modifiers.
   * @see {@link http://gigaspaces.com/docs/JavaDoc/com/j_spaces/core/IJSpace.html#getReadTakeModifiers()}
   */
  public int getReadTakeModifiers()
  {
    return ((Integer) execute(new JavaSpaceCallback()
    {
      public Object doInSpace(JavaSpace js, Transaction tx)
          throws RemoteException
      {
        return new Integer((((IJSpace) js).getReadTakeModifiers()));
View Full Code Here

     * @return a object for the entry that was written to the space
     * @see {@link http://java.sun.com/products/jini/2.0/doc/api/net/jini/space/JavaSpace.html#read(net.jini.core.entry.Entry,net.jini.core.transaction.Transaction,long)}
     */
  public Object read(final Object pojo, final long lease)
  {
    return (Object) execute(new JavaSpaceCallback()
    {
      public Object doInSpace(JavaSpace js, Transaction tx)
          throws RemoteException, TransactionException,
          UnusableEntryException, InterruptedException
      {
View Full Code Here

   * @return a copy of the entry read from the space
   * @see {@link http://java.sun.com/products/jini/2.0/doc/api/net/jini/space/JavaSpace.html#readIfExists(net.jini.core.entry.Entry,net.jini.core.transaction.Transaction,long)}
   */
  public Object readIfExists(final Object pojo, final long lease)
  {
    return (Object) execute(new JavaSpaceCallback()
    {
      public Object doInSpace(JavaSpace js, Transaction tx)
          throws RemoteException, TransactionException,
          UnusableEntryException, InterruptedException
      {
View Full Code Here

TOP

Related Classes of org.springmodules.javaspaces.JavaSpaceCallback

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.