com.gemstone.gbj

## Class GbjObject

- java.lang.Object
- - java.util.Observable
  - - com.gemstone.gbjgci.GbjGciReport
    - - com.gemstone.gbjgci.GbjGciObject
      - - com.gemstone.gbj.GbjObject

- All Implemented Interfaces:
    java.lang.Cloneable
  Direct Known Subclasses:
    GbjCollection

      public class GbjObject
      extends GbjGciObject
      implements java.lang.Cloneable

  Instances of this class represent server objects in a GemStone server. Each GbjObject holds a reference to the remote object and may also hold the value of the server object in various protected value fields.

  GbjObject defines methods for fundamental operations on server objects. Other methods for specific objects will be available on the server and may be accessed through the GbjObject instance with the sendMsg() methods.

  ## GBJ 3.2 Changes

  Added constructors taking as arguments instances of BigInteger , BigDecimal, BigDecimalFloat, BigFraction, LocalDate, LocalTime, LocalDateTime, ZonedDateTime, OffsetDateTime, Instant . Removed constructors taking as arguments instances of DoubleByteString, Calendar .

  ### Object Change Synchronization

  The subclass GbjGciObject now provides support via the Java Observable/Observer API to notify customer application when the associated GS server object has changed, either due to GS Smalltalk code execution or committed transactions from other sessions. Refer to the GbjGciObject class documentation for details.
  Version:
    3.2

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `GbjObject()` Special constructor - should only be used for generating a template object for java/GS class mapping operations
    `GbjObject(BigDecimalFloat df, GbjSession s)` Construct a GS object representing a BigDecimalFloat for this session.
    `GbjObject(java.math.BigDecimal d, GbjSession s)` Construct a GS object representing a BigDecimal for this session.
    `GbjObject(org.apache.commons.math3.fraction.BigFraction f, GbjSession s)` Construct a GS object representing a BigFraction for this session.
    `GbjObject(java.math.BigInteger i, GbjSession s)` Construct a GS object representing a BigInteger for this session.
    `GbjObject(boolean b, GbjSession s)` Construct a GS object representing a boolean for this session.
    `GbjObject(byte b, GbjSession s)` Construct a GS object representing a byte for this session.
    `GbjObject(char c, GbjSession s)` Construct a GS object representing a character for this session.
    `GbjObject(java.util.Date d, GbjSession s)` Construct a GS object representing a Date for this session.
    `GbjObject(double d, GbjSession s)` Construct a GS object representing a double for this session.
    `GbjObject(float f, GbjSession s)` Construct a GS object representing a float for this session.
    `GbjObject(GbjSession s)`
    `GbjObject(java.time.Instant i, GbjSession s)` Construct a GS object representing an Instant for this session.
    `GbjObject(int i, GbjSession s)` Construct a GS object representing an int for this session.
    `GbjObject(java.time.LocalDate d, GbjSession s)` Construct a GS object representing a LocalDate for this session.
    `GbjObject(java.time.LocalDateTime ldt, GbjSession s)` Construct a GS object representing a LocalDateTime for this session.
    `GbjObject(java.time.LocalTime t, GbjSession s)` Construct a GS object representing a LocalTime for this session.
    `GbjObject(long i, GbjSession s)` Construct a GS object representing a long for this session.
    `GbjObject(java.lang.Object o, GbjSession s)` Construct a GS object representing an object for this session.
    `GbjObject(java.time.OffsetDateTime odt, GbjSession s)` Construct a GS object representing a OffsetDateTime for this session.
    `GbjObject(short i, GbjSession s)` Construct a GS object representing a short for this session.
    `GbjObject(java.lang.String str, GbjSession s)` Construct a GS object representing a string for this session.
    `GbjObject(java.time.ZonedDateTime zdt, GbjSession s)` Construct a GS object representing a ZonedDateTime for this session.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `assignToSegment(GbjObject segment)` Assign the server object, but not its contents, to the given segment.
    `java.lang.String` | `asString()` Convert the server object to a string
    `GbjObject` | `at(int index)` Access one of the server object's anonymous instance variables.
    `java.lang.Object` | `atPut(int index, java.lang.Object value)` Update one of the server object's anonymous instance variables.
    `java.lang.Object` | `cachedValue()` This method returns the cachedValue if the receiver represents a server object for which there is a direct mapping from the Server class to a Java class .
    `boolean` | `canBeWritten()` Does the user have write access to the server object?
    `void` | `changeToSegment(GbjObject segment)` Change the server object's segment and do the same with its contents.
    `boolean` | `cluster()` Cluster the server object
    `int` | `clusterBucket()` The cluster id that the server object was assigned during the current clustering operation
    `boolean` | `clusterDepthFirst()` Cluster the server object and its contents doing a depth-first traversal.
    `java.lang.StringBuffer` | `dbStringBufferValue()` Deprecated. Use stringBufferValue()
    `java.lang.String` | `dbStringValue()` Deprecated. Use stringValue() inherited from GbjGciObject
    `GbjObject` | `deepCopy()` Return a deep copy of the server object.
    `void` | `exclusiveLock()` Lock this database object.
    `GbjObject` | `execute(java.lang.String code)` Transmit a string holding GemStone Smalltalk code to the server and compile and execute it, returning the result of execution.
    `static GbjObject` | `fromInteger(int value, GbjSession session)` Deprecated. Use GbjObject(int, GbjSession) instead.
    `static GbjObject` | `fromLong(long value, GbjSession session)` Deprecated. Use GbjObject(long, GbjSession) instead.
    `GbjSession` | `getSession()` Return the GbjSession associated with this GbjObject
    `void` | `immediateInvariant()` Make the server object invariant (immutable).
    `boolean` | `in(GbjCollection collection)` Is the server object in the given remote collection?
    `boolean` | `isBehavior()` Is the server object a class or metaclass object
    `boolean` | `isCommitted()` Was the server object in existence before the current transaction?
    `boolean` | `isConnected()` Deprecated. no longer supported by the server
    `boolean` | `isInvariant()` Is the server object invariant (immutable)?
    `boolean` | `isKindOf(GbjObject remoteClass)` Is the server object an instance of the given class or one of its superclasses?
    `boolean` | `isMemberOf(GbjObject remoteClass)` Is the server object an instance of the given class?
    `boolean` | `isWritten()` Is the server object new in this transaction or been modified in this transaction
    `void` | `moveToDisk()` Force the server object to disk if not already there
    `GbjObject[]` | `namedInstanceVariables()` Return the named instance variables of this server object, in their order of appearance (see GemStone Smalltalk Behavior>>allInstVarNames.
    `void` | `nilFields()` nil the instance variables of the server object
    `boolean` | `notNil()` Is the receiver not a nil value? Does not currently require a message send to the server.
    `int` | `page()` The page number of the server object, or nil if a special or unconnected object
    `java.util.Date` | `pageCreationTime()` The page creation time of the server object
    `GbjObject` | `perform(java.lang.String message)`
    `GbjObject` | `perform(java.lang.String message, java.lang.Object[] args, int numArgs)` Send a message to a GemStone object and expect a server object in reply.
    `java.lang.String` | `printString()` Fetch a printable representation of the server object.
    `void` | `readLock()` Lock this database object.
    `GbjObject` | `remoteClass()` Fetch the server object's class.
    `GbjObject` | `remoteClone()` Return a shallow copy of the server object.
    `GbjObject` | `remoteCopy()` Return a shallow copy of the server object.
    `boolean` | `remoteEquals(java.lang.Object arg)` Return whether the server object and the argument have equal values.
    `boolean` | `remoteEqualsIdentical(java.lang.Object arg)` Return whether the server object is identical to the given object.
    `boolean` | `remoteEqualsNoCase(java.lang.Object arg)` Return whether the server object is equal to the given object with case-insensitive comparison.
    `int` | `remoteHash()` Return the server object's equality hash code.
    `int` | `remoteIdentityHash()` Return the server object's identity hash code.
    `boolean` | `remoteIsEquivalent(GbjObject otherObj)` Is the server object equivalent to the given object? This test is oriented toward string comparisons and is not generally useful for other types of objects.
    `int` | `remoteSize()` Fetch the server object's size.
    `GbjObject` | `remoteSpecies()` The server object's class for cloning operations
    `void` | `removeLock()` Release any lock held on this object by this application.
    `boolean` | `respondsTo(java.lang.String selector)` Does the server object responds to the given message selector?
    `GbjObject` | `segment()` Answer the segment that the server object is currently assigned to.
    `GbjObject` | `sendMsg(java.lang.String selector)` Send a unary message to a GemStone object and expect an Object reply.
    `GbjObject` | `sendMsg(java.lang.String selector, java.lang.Object arg)` Send a one-keyword or binary message to a GemStone object and expect an Object reply.
    `GbjObject` | `sendMsg(java.lang.String keyword1, java.lang.Object arg1, java.lang.String keyword2, java.lang.Object arg2)` Send a two-keyword message to a GemStone object and expect an Object reply.
    `GbjObject` | `sendMsg(java.lang.String keyword1, java.lang.Object arg1, java.lang.String keyword2, java.lang.Object arg2, java.lang.String keyword3, java.lang.Object arg3)` Send a three-keyword message to a GemStone object and expect an Object reply.
    `GbjObject` | `sendMsg(java.lang.String keyword1, java.lang.Object arg1, java.lang.String keyword2, java.lang.Object arg2, java.lang.String keyword3, java.lang.Object arg3, java.lang.String keyword4, java.lang.Object arg4)` Send a four-keyword message to a GemStone object and expect an Object reply.
    `GbjObject` | `sendMsg(java.lang.String keyword1, java.lang.Object arg1, java.lang.String keyword2, java.lang.Object arg2, java.lang.String keyword3, java.lang.Object arg3, java.lang.String keyword4, java.lang.Object arg4, java.lang.String keyword5, java.lang.Object arg5)` Send a five-keyword message to a GemStone object and expect an Object reply.
    `void` | `size(int newSize)` Alter the size of the server object's anonymous part.
    `java.lang.StringBuffer` | `stringBufferValue()` Return the cached String object held by the receiver as a new StringBuffer.
    `static GbjObject` | `withOop(long oopValue, GbjSession s)` Return the GS object with this designated oop.
    `void` | `writeLock()` Lock this database object.

    - ### Methods inherited from class com.gemstone.gbjgci.GbjGciObject

      `bigDecimalFloatValue, bigDecimalValue, bigFractionValue, bigIntegerValue, booleanValue, bytesValue, byteValue, charValue, dateValue, debugPrint, doubleValue, equals, floatValue, getByte, getBytes, getIndexedSize, getNamedObj, getNamedObjs, getNamedSize, getObj, getObjs, getObjs, getObjType, getTotalSize, getValType, hashCode, instantValue, intValue, isString, localDateTimeValue, localDateValue, localTimeValue, longValue, named, offsetDateTimeValue, putByte, putBytes, putBytes, putNamedObj, putNamedObjs, putNamedObjs, putObj, putObjs, putObjs, shortValue, stringValue_, stringValue, toString, withOop, zonedDateTimeValue`

    - ### Methods inherited from class com.gemstone.gbjgci.GbjGciReport

      `clone, getOop, getValTypeString, isNil, isSpecial, javaClass, javaValue`

    - ### Methods inherited from class java.util.Observable

      `addObserver, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers`

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

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### GbjObject

          public GbjObject()

      Special constructor - should only be used for generating a template object for java/GS class mapping operations

    - #### GbjObject

          public GbjObject(GbjSession s)

    - #### GbjObject

          public GbjObject(boolean b,
                           GbjSession s)

      Construct a GS object representing a boolean for this session. Generates a GS Boolean object.
      Parameters:
        `b` - boolean
        `s` - session

    - #### GbjObject

          public GbjObject(char c,
                           GbjSession s)

      Construct a GS object representing a character for this session. Generates a GS Character object.
      Parameters:
        `c` - char
        `s` - session

    - #### GbjObject

          public GbjObject(byte b,
                           GbjSession s)

      Construct a GS object representing a byte for this session. Generates a GS SmallInteger object.
      Parameters:
        `b` - byte
        `s` - session

    - #### GbjObject

          public GbjObject(short i,
                           GbjSession s)

      Construct a GS object representing a short for this session. Generates a GS SmallInteger object.
      Parameters:
        `i` - short
        `s` - session

    - #### GbjObject

          public GbjObject(int i,
                           GbjSession s)

      Construct a GS object representing an int for this session. Generates a GS SmallInteger object.
      Parameters:
        `i` - int
        `s` - session

    - #### GbjObject

          public GbjObject(long i,
                           GbjSession s)

      Construct a GS object representing a long for this session. Generates a GS SmallInteger object.
      Parameters:
        `i` - long
        `s` - session

    - #### GbjObject

          public GbjObject(java.math.BigInteger i,
                           GbjSession s)

      Construct a GS object representing a BigInteger for this session. Generates a GS Integer or LargeInteger as appropriate
      Parameters:
        `i` - BigInteger
        `s` - session

    - #### GbjObject

          public GbjObject(float f,
                           GbjSession s)

      Construct a GS object representing a float for this session. Generates a GS SmallDouble object.
      Parameters:
        `f` - float
        `s` - session

    - #### GbjObject

          public GbjObject(double d,
                           GbjSession s)

      Construct a GS object representing a double for this session. Generates a GS Float object.
      Parameters:
        `d` - double
        `s` - session

    - #### GbjObject

          public GbjObject(java.math.BigDecimal d,
                           GbjSession s)

      Construct a GS object representing a BigDecimal for this session. Generates a GS ScaledDecimal object.
      Parameters:
        `d` - double
        `s` - session

    - #### GbjObject

          public GbjObject(BigDecimalFloat df,
                           GbjSession s)

      Construct a GS object representing a BigDecimalFloat for this session. Generates a GS DecimalFloat object.
      Parameters:
        `df` - BigDecimalFloat
        `s` - session

    - #### GbjObject

          public GbjObject(org.apache.commons.math3.fraction.BigFraction f,
                           GbjSession s)

      Construct a GS object representing a BigFraction for this session. Generates a GS Fraction object.
      Parameters:
        `f` - BigFraction
        `s` - session

    - #### GbjObject

          public GbjObject(java.lang.String str,
                           GbjSession s)

      Construct a GS object representing a string for this session. Generates either a GS String or DoubleByteString, as appropriate.
      Parameters:
        `str` - String
        `s` - session

    - #### GbjObject

          public GbjObject(java.time.LocalDate d,
                           GbjSession s)

      Construct a GS object representing a LocalDate for this session. Generates a GS Date object.
      Parameters:
        `d` - LocalDate
        `s` - session

    - #### GbjObject

          public GbjObject(java.time.LocalTime t,
                           GbjSession s)

      Construct a GS object representing a LocalTime for this session. Generates a GS Time object.
      Parameters:
        `t` - LocalTime
        `s` - session

    - #### GbjObject

          public GbjObject(java.time.LocalDateTime ldt,
                           GbjSession s)

      Construct a GS object representing a LocalDateTime for this session. Generates a GS LocalDateTime object.
      Parameters:
        `ldt` - LocalDateTime
        `s` - session

    - #### GbjObject

          public GbjObject(java.time.ZonedDateTime zdt,
                           GbjSession s)

      Construct a GS object representing a ZonedDateTime for this session. Generates a GS DateTime object.
      Parameters:
        `zdt` - LocalTime
        `s` - session

    - #### GbjObject

          public GbjObject(java.time.OffsetDateTime odt,
                           GbjSession s)

      Construct a GS object representing a OffsetDateTime for this session. Generates a GS DateAndTime object.
      Parameters:
        `odt` - OffsetDateTime
        `s` - session

    - #### GbjObject

          public GbjObject(java.util.Date d,
                           GbjSession s)

      Construct a GS object representing a Date for this session. Generates a GS DateAndTime object.
      Parameters:
        `d` - Date
        `s` - session

    - #### GbjObject

          public GbjObject(java.time.Instant i,
                           GbjSession s)

      Construct a GS object representing an Instant for this session. Generates a GS DateAndTime object.
      Parameters:
        `i` - Instant
        `s` - session

    - #### GbjObject

          public GbjObject(java.lang.Object o,
                           GbjSession s)

      Construct a GS object representing an object for this session. Note that object must be an instance of boolean, character, byte, short, int, long, float, double, date, or string. (as of GBJ 3.2.0: also LocalTime, LocalDate)
      Parameters:
        `o` - Object
        `s` - session

  - ### Method Detail

    - #### withOop

          public static GbjObject withOop(long oopValue,
                                          GbjSession s)

      Return the GS object with this designated oop. This method replaces the use of GbjObject(long, GbjSession) used prior to GBJ30.
      Parameters:
        `oopValue` - Designated oop
        `s` - GbjSession
      Returns:
        The GS object with this designated oop.

    - #### fromInteger

          @Deprecated
          public static GbjObject fromInteger(int value,
                                                          GbjSession session)

      Deprecated. Use GbjObject(int, GbjSession) instead.
      Convert a Java int to a GemStone SmallInteger
      Parameters:
        `value` - Java int
        `session` - GbjSession
      Returns:
        GbjObject

    - #### fromLong

          @Deprecated
          public static GbjObject fromLong(long value,
                                                       GbjSession session)

      Deprecated. Use GbjObject(long, GbjSession) instead.
      Convert a Java long to a GemStone SmallInteger
      Parameters:
        `value` - Java long
        `session` - GbjSession
      Returns:
        GbjObject

    - #### cachedValue

          public java.lang.Object cachedValue()

      This method returns the cachedValue if the receiver represents a server object for which there is a direct mapping from the Server class to a Java class . The direct mappings include the classes used by each of the constructors in GbjObject. See the *value() methods in GbjGciObject .
      Returns:
        java object , or null if there is not a direct mapping.

    - #### getSession

          public GbjSession getSession()

      Return the GbjSession associated with this GbjObject
      Overrides:
        `getSession` in class `GbjGciObject`
      Returns:
        GbjSession

    - #### stringBufferValue

          public java.lang.StringBuffer stringBufferValue()
                                                   throws java.lang.ClassCastException

      Return the cached String object held by the receiver as a new StringBuffer. If the receiver does not hold a StringBuffer, this throws a ClassCastException.
      Returns:
        StringBuffer
      Throws:
        `java.lang.ClassCastException` - on receiver not holding a StringBuffer

    - #### dbStringValue

          public java.lang.String dbStringValue()
                                         throws java.lang.ClassCastException

      Deprecated. Use stringValue() inherited from GbjGciObject
      Return the cached Unicode string object held by the receiver. If the receiver does not represent a GemStone DoubleByteString object, this throws a ClassCastException.
      Returns:
        The cached Unicode string object held by the receiver.
      Throws:
        `java.lang.ClassCastException` - on receiver not a DoubleByteString

    - #### dbStringBufferValue

          public java.lang.StringBuffer dbStringBufferValue()
                                                     throws java.lang.ClassCastException

      Deprecated. Use stringBufferValue()
      Return the cached Unicode string object held by the receiver as a new StringBuffer object. If the receiver does not represent a GemStone DoubleByteString object, this throws a ClassCastException.
      Returns:
        The cached Unicode string object held by the receiver.
      Throws:
        `java.lang.ClassCastException` - on receiver not a DoubleByteString

    - #### execute

          public GbjObject execute(java.lang.String code)
                            throws GbjException

      Transmit a string holding GemStone Smalltalk code to the server and compile and execute it, returning the result of execution. The code may reference "self" as the server object represented by this GbjObject instance, and may directly reference instance variables of the server object.
      Parameters:
        `code` - GemStone Smalltalk source code to be compiled and executed
      Returns:
        Result of execution
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### perform

          public GbjObject perform(java.lang.String message,
                                   java.lang.Object[] args,
                                   int numArgs)
                            throws GbjException

      Send a message to a GemStone object and expect a server object in reply. In general it is more convenient to use the sendMsg() methods to send a message to a server object. The perform() method is a lower level alternative to those methods which can be used if there are more keywords in the message than sendMsg() allows, or if it is otherwise more convenient.
      Parameters:
        `message` - a message selector that is dynamically looked up on the server
        `args` - an array of arguments that must be GbjObject instances or wrappers of fundamental types
        `numArgs` - the number of entries in args that are significant
      Returns:
        Result of perform
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### perform

          public GbjObject perform(java.lang.String message)
                            throws GbjException

      Throws:
        `GbjException`

    - #### sendMsg

          public GbjObject sendMsg(java.lang.String selector)
                            throws GbjException

      Send a unary message to a GemStone object and expect an Object reply. E.g., sendMsg("size");
      Parameters:
        `selector` - the message selector
      Returns:
        Result of message
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### sendMsg

          public GbjObject sendMsg(java.lang.String selector,
                                   java.lang.Object arg)
                            throws GbjException

      Send a one-keyword or binary message to a GemStone object and expect an Object reply. E.g., sendMsg("at:", new Integer(1));
      Parameters:
        `selector` - the message selector
        `arg` - the argument to the message.
      Returns:
        Result of message
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### sendMsg

          public GbjObject sendMsg(java.lang.String keyword1,
                                   java.lang.Object arg1,
                                   java.lang.String keyword2,
                                   java.lang.Object arg2)
                            throws GbjException

      Send a two-keyword message to a GemStone object and expect an Object reply. E.g., sendMsg("at:", new Integer(1), "put:", Boolean.TRUE);
      Parameters:
        `keyword1` - the first keyword of the message selector
        `arg1` - the argument to the message for the first keyword.
        `keyword2` - the second keyword of the message selector
        `arg2` - the argument to the message for the second keyword.
      Returns:
        Result of message
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### sendMsg

          public GbjObject sendMsg(java.lang.String keyword1,
                                   java.lang.Object arg1,
                                   java.lang.String keyword2,
                                   java.lang.Object arg2,
                                   java.lang.String keyword3,
                                   java.lang.Object arg3)
                            throws GbjException

      Send a three-keyword message to a GemStone object and expect an Object reply. E.g., sendMsg("at:", new Integer(1), "put:", Boolean.TRUE, "with:", Boolean.FALSE);
      Parameters:
        `keyword1` - the first keyword of the message selector
        `arg1` - the argument to the message for the first keyword.
        `keyword2` - the second keyword of the message selector
        `arg2` - the argument to the message for the second keyword.
        `keyword3` - the third keyword of the message selector
        `arg3` - the argument to the message for the third keyword.
      Returns:
        Result of message
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### sendMsg

          public GbjObject sendMsg(java.lang.String keyword1,
                                   java.lang.Object arg1,
                                   java.lang.String keyword2,
                                   java.lang.Object arg2,
                                   java.lang.String keyword3,
                                   java.lang.Object arg3,
                                   java.lang.String keyword4,
                                   java.lang.Object arg4)
                            throws GbjException

      Send a four-keyword message to a GemStone object and expect an Object reply.
      Parameters:
        `keyword1` - the first keyword of the message selector
        `arg1` - the argument to the message for the first keyword.
        `keyword2` - the second keyword of the message selector
        `arg2` - the argument to the message for the second keyword.
        `keyword3` - the third keyword of the message selector
        `arg3` - the argument to the message for the third keyword.
        `keyword4` - the third keyword of the message selector
        `arg4` - the argument to the message for the third keyword.
      Returns:
        Result of message
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### sendMsg

          public GbjObject sendMsg(java.lang.String keyword1,
                                   java.lang.Object arg1,
                                   java.lang.String keyword2,
                                   java.lang.Object arg2,
                                   java.lang.String keyword3,
                                   java.lang.Object arg3,
                                   java.lang.String keyword4,
                                   java.lang.Object arg4,
                                   java.lang.String keyword5,
                                   java.lang.Object arg5)
                            throws GbjException

      Send a five-keyword message to a GemStone object and expect an Object reply.
      Parameters:
        `keyword1` - the first keyword of the message selector
        `arg1` - the argument to the message for the first keyword.
        `keyword2` - the second keyword of the message selector
        `arg2` - the argument to the message for the second keyword.
        `keyword3` - the third keyword of the message selector
        `arg3` - the argument to the message for the third keyword.
        `keyword4` - the third keyword of the message selector
        `arg4` - the argument to the message for the third keyword.
        `keyword5` - the third keyword of the message selector
        `arg5` - the argument to the message for the third keyword.
      Returns:
        Result of message
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### namedInstanceVariables

          public GbjObject[] namedInstanceVariables()
                                             throws GbjException

      Return the named instance variables of this server object, in their order of appearance (see GemStone Smalltalk Behavior>>allInstVarNames.
      Returns:
        The named instance variables of this server object.
      Throws:
        `GbjException` - thrown if the session is not connected or there is a server exception

    - #### remoteSize

          public int remoteSize()
                         throws GbjException

      Fetch the server object's size.
      Returns:
        the integer size of the server object
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteClass

          public GbjObject remoteClass()
                                throws GbjException

      Fetch the server object's class.
      Returns:
        a reference to the server object's class
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### printString

          public java.lang.String printString()
                                       throws GbjException

      Fetch a printable representation of the server object.
      Returns:
        a String that can be displayed
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteEquals

          public boolean remoteEquals(java.lang.Object arg)
                               throws GbjException

      Return whether the server object and the argument have equal values.
      Parameters:
        `arg` - Argument to use
      Returns:
        Boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteEqualsIdentical

          public boolean remoteEqualsIdentical(java.lang.Object arg)

      Return whether the server object is identical to the given object.
      Parameters:
        `arg` - Argument to use
      Returns:
        Boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteEqualsNoCase

          public boolean remoteEqualsNoCase(java.lang.Object arg)
                                     throws GbjException

      Return whether the server object is equal to the given object with case-insensitive comparison.
      Parameters:
        `arg` - Argument to use
      Returns:
        Boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteIdentityHash

          public int remoteIdentityHash()

      Return the server object's identity hash code.
      Returns:
        int result

    - #### remoteHash

          public int remoteHash()
                         throws GbjException

      Return the server object's equality hash code.
      Returns:
        int result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteCopy

          public GbjObject remoteCopy()
                               throws GbjException

      Return a shallow copy of the server object.
      Returns:
        GbjObject result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteClone

          public GbjObject remoteClone()
                                throws GbjException

      Return a shallow copy of the server object.
      Returns:
        GbjObject result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### deepCopy

          public GbjObject deepCopy()
                             throws GbjException

      Return a deep copy of the server object.
      Returns:
        GbjObject result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### immediateInvariant

          public void immediateInvariant()
                                  throws GbjException

      Make the server object invariant (immutable).
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### isInvariant

          public boolean isInvariant()
                              throws GbjException

      Is the server object invariant (immutable)?
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### in

          public boolean in(GbjCollection collection)
                     throws GbjException

      Is the server object in the given remote collection?
      Parameters:
        `collection` - Collection to use
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### isKindOf

          public boolean isKindOf(GbjObject remoteClass)
                           throws GbjException

      Is the server object an instance of the given class or one of its superclasses?
      Parameters:
        `remoteClass` - Class to use
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### isMemberOf

          public boolean isMemberOf(GbjObject remoteClass)
                             throws GbjException

      Is the server object an instance of the given class?
      Parameters:
        `remoteClass` - Class to use
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### canBeWritten

          public boolean canBeWritten()
                               throws GbjException

      Does the user have write access to the server object?
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### changeToSegment

          public void changeToSegment(GbjObject segment)
                               throws GbjException

      Change the server object's segment and do the same with its contents.
      Parameters:
        `segment` - Segment to use
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### assignToSegment

          public void assignToSegment(GbjObject segment)
                               throws GbjException

      Assign the server object, but not its contents, to the given segment.
      Parameters:
        `segment` - Segment to use
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### at

          public GbjObject at(int index)
                       throws GbjException

      Access one of the server object's anonymous instance variables.
      Parameters:
        `index` - Index to use
      Returns:
        GbjObject result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### atPut

          public java.lang.Object atPut(int index,
                                        java.lang.Object value)
                                 throws GbjException

      Update one of the server object's anonymous instance variables.
      Parameters:
        `index` - Index to use
        `value` - Value to use for update
      Returns:
        value
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### segment

          public GbjObject segment()
                            throws GbjException

      Answer the segment that the server object is currently assigned to.
      Returns:
        the segment
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### size

          public void size(int newSize)
                    throws GbjException

      Alter the size of the server object's anonymous part.
      Parameters:
        `newSize` - Size to use
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteIsEquivalent

          public boolean remoteIsEquivalent(GbjObject otherObj)
                                     throws GbjException

      Is the server object equivalent to the given object? This test is oriented toward string comparisons and is not generally useful for other types of objects.
      Parameters:
        `otherObj` - given object
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### notNil

          public boolean notNil()

      Is the receiver not a nil value? Does not currently require a message send to the server.
      Returns:
        boolean result

    - #### isCommitted

          public boolean isCommitted()
                              throws GbjException

      Was the server object in existence before the current transaction?
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### isConnected

          public boolean isConnected()
                              throws GbjException

      Deprecated. no longer supported by the server
      Returns:
        boolean result , always false
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### isWritten

          public boolean isWritten()
                            throws GbjException

      Is the server object new in this transaction or been modified in this transaction
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### isBehavior

          public boolean isBehavior()
                             throws GbjException

      Is the server object a class or metaclass object
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### asString

          public java.lang.String asString()
                                    throws GbjException

      Convert the server object to a string
      Returns:
        String result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### page

          public int page()
                   throws GbjException

      The page number of the server object, or nil if a special or unconnected object
      Returns:
        result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### pageCreationTime

          public java.util.Date pageCreationTime()
                                          throws GbjException

      The page creation time of the server object
      Returns:
        Date result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### moveToDisk

          public void moveToDisk()
                          throws GbjException

      Force the server object to disk if not already there
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### cluster

          public boolean cluster()
                          throws GbjException

      Cluster the server object
      Returns:
        boolean whether the server object has already been clustered in this transaction
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### clusterDepthFirst

          public boolean clusterDepthFirst()
                                    throws GbjException

      Cluster the server object and its contents doing a depth-first traversal.
      Returns:
        boolean whether the server object has already been clustered in this transaction
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### clusterBucket

          public int clusterBucket()
                            throws GbjException

      The cluster id that the server object was assigned during the current clustering operation
      Returns:
        int result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### nilFields

          public void nilFields()
                         throws GbjException

      nil the instance variables of the server object
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### respondsTo

          public boolean respondsTo(java.lang.String selector)
                             throws GbjException

      Does the server object responds to the given message selector?
      Parameters:
        `selector` - message selector to check
      Returns:
        boolean result
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### remoteSpecies

          public GbjObject remoteSpecies()
                                  throws GbjException

      The server object's class for cloning operations
      Returns:
        result GbjObject
      Throws:
        `GbjException` - thrown if there is a server exception

    - #### readLock

          public void readLock()
                        throws GbjException

      Lock this database object. Throws an exception if another session holds a conflicting lock on this object. Also throws an exception if another session has committed a change to this object (LOCK_ERR_OBJ_HAS_CHANGED). You may not read-lock an object that you already have a write or exclusive lock upon.
      Throws:
        `GbjException` - thrown if there is a server exception
      See Also:
        `GbjGemStoneErrors.LOCK_ERR_OBJ_HAS_CHANGED`

    - #### writeLock

          public void writeLock()
                         throws GbjException

      Lock this database object. Throws an exception if another session holds a conflicting lock on this object. Also throws an exception if another session has committed a change to this object (LOCK_ERR_OBJ_HAS_CHANGED).
      Throws:
        `GbjException` - thrown if there is a server exception
      See Also:
        `GbjGemStoneErrors.LOCK_ERR_OBJ_HAS_CHANGED`

    - #### exclusiveLock

          public void exclusiveLock()
                             throws GbjException

      Lock this database object. Throws an exception if another session holds a conflicting lock on this object. Also throws an exception if another session has committed a change to this object (LOCK_ERR_OBJ_HAS_CHANGED).
      Throws:
        `GbjException` - thrown if there is a server exception
      See Also:
        `GbjGemStoneErrors.LOCK_ERR_OBJ_HAS_CHANGED`

    - #### removeLock

          public void removeLock()
                          throws GbjException

      Release any lock held on this object by this application. If the object is not locked by this session, a GbjException with number LOCK_ERR_REMOVE is thrown.
      Throws:
        `GbjException` - thrown if there is a server exception
      See Also:
        `GbjGemStoneErrors.LOCK_ERR_REMOVE`