aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/io/ObjectStreamField.java
AgeCommit message (Collapse)AuthorFilesLines
2004-02-282004-02-28 Guilhem Lavaux <guilhem@kaffe.org>Guilhem Lavaux1-43/+88
* java/io/ObjectInputStream.java (readClassDescriptor): Keep elements of the mapping non null. (checkTypeConsistency): New method. (readFields): Fixed main loop and base logic. Small reindentation. * java/io/ObjectStreamField.java (lookupField): New method to update the field reference. (checkFieldType): New method. * java/io/ObjectStreamClass.java (setClass, setFields): Call lookupField when building the field database. Check the real field type. From-SVN: r78627
2004-02-06ObjectInputStream.java: Made all calls to dumpElement[ln] conditional on ↵Jeroen Frijters1-5/+120
dump flag. 2004-02-06 Jeroen Frijters <jeroen@frijters.net> * java/io/ObjectInputStream.java: Made all calls to dumpElement[ln] conditional on dump flag. (readObject): Changed to use cached info from ObjectStreamClass. (readClassDescriptor): Cache more information in ObjectStreamClass. (processResolution, readFields): Use cached info from ObjectStreamClass. (newObject): Throw exception instead of returning null for failure. (getField, getMethod, callReadMethod, setBooleanField, setByteField, setCharField, setDoubleField, setFloatField, setIntField, setLongField, setShortField, setObjectField, readObjectParams): Removed. (dumpElement, dumpElementln): Removed dump flag condition check. * java/io/ObjectStreamField.java (hasReadMethod): Removed. (setClass): Added call to cacheMethods() (findMethod): New method. (cacheMethods): New method. (ObjectStreamClass): Added call to cacheMethods(). (setFields): Cache fields. (getClassUID): Use AccessController.doPrivileged to invoke setAccessible. (readObjectMethod, readResolveMethod, realClassIsSerializable, realClassIsExternalizable, fieldMapping, firstNonSerializableParent): New fields. * java/io/ObjectStreamField.java (ObjectStreamField): New constructor. (ObjectStreamField): Removed FIXME workaround. (getTypeString, isPrimitive): Made safe for cases where type == null. (setBooleanField, setByteField, setCharField, setShortField, setIntField, setLongField, setFloatField, setDoubleField, setObjectField): New methods. From-SVN: r77395
2003-12-20ObjectStreamField.java (isUnshared): Added documentation.Michael Koch1-0/+6
2003-12-20 Michael Koch <konqueror@gmx.de> * java/io/ObjectStreamField.java (isUnshared): Added documentation. From-SVN: r74894
2003-12-16ObjectStreamField.java: A few methods were added in prevision of the ↵Guilhem Lavaux1-6/+159
upcoming upgrade of the... 2003-12-16 Guilhem Lavaux <guilhem@kaffe.org> * java/io/ObjectStreamField.java: A few methods were added in prevision of the upcoming upgrade of the serialization code. This also adds some missing documentation. (ObjectStreamField): We should throw a NullPointerException when 'name' is null. From-SVN: r74690
2003-06-202003-06-20 Michael Koch <konqueror@gmx.de>Michael Koch1-6/+18
* java/io/ObjectStreamField.java (unshared): new member variable. (ObjectStreamField): New constructor. (isUnshared): New method. From-SVN: r68261
2003-03-18BufferedReader.java, [...]: Merged from classpath.Michael Koch1-7/+12
2003-03-18 Michael Koch <konqueror@gmx.de> * java/io/BufferedReader.java, java/io/BufferedWriter.java, java/io/ByteArrayOutputStream.java, java/io/FileFilter.java, java/io/FilePermission.java, java/io/FileReader.java, java/io/FileWriter.java, java/io/FilenameFilter.java, java/io/FilterInputStream.java, java/io/FilterOutputStream.java, java/io/FilterReader.java, java/io/FilterWriter.java, java/io/ObjectInput.java, java/io/ObjectInputValidation.java, java/io/ObjectOutput.java, java/io/ObjectStreamField.java, java/io/PipedInputStream.java, java/io/PipedReader.java, java/io/PrintWriter.java, java/io/PushbackReader.java, java/io/Reader.java, java/io/SerializablePermission.java, java/io/StringReader.java, java/io/Writer.java: Merged from classpath. From-SVN: r64525
2003-02-28Makefile.am (nat_source_files): Remove java/io/natObjectOutputStream.cc.Mark Wielaard1-3/+20
* Makefile.am (nat_source_files): Remove java/io/natObjectOutputStream.cc. * Makefile.in: Regenerated. * mauve-libgcj: Don't exclude java.io.ObjectInputOutput tests. * java/io/ObjectStreamField.java (typename): New field. (ObjectStreamField(String, Class)): Initialize new field. (ObjectStreamField(String, String)): New Constructor. (getTypeCode): Use new field. (getTypeString): Use new field. * java/io/ObjectOutputStream.java (writeObject): Rethrow fatal ObjectStreamExceptions. Remember and reset old BlockDataMode. Handle reading of Proxy classes. Never drain(), just write TC_ENDBLOCKDATA. Rethrow ObjectStreamExceptions. (drain): Check writeDataAsBlocks before calling writeBlockDataHeader. (flush): Call flush(), not just drain(). (writeBoolean): Always use blockDataOutput. (writeByte): Likewise. (writeShort): Likewise. (writeChar): Likewise. (writeInt): Likewise. (writeLong): Likewise. (writeFloat): Likewise. (writeDouble): Likewise. (writeBytes): Likewise. (putfield (put(String,Object))): Throw IllegalArgumentException if field cannot be found. (putfield (write(ObjectOutput))): Remember old BlockDataMode. (writeArraySizeAndElements): Write byte[] in one go. (writeFields): Write TC_ENDBLOCKDATA when call_write_method, otherwise set BlockDataMode to false. (annotateProxyClass): New method. (defaultProtocolVersion): Now defaults to PROTOCOL_VERSION_2 (getField): No longer native. (getMethod): Likewise. (setBlockDataMode): Always drain() on switch, return old mode. (static): New static code block. * java/io/natObjectOutputStream.cc: Removed. * java/io/ObjectInputStream.java (getField): No longer native. (getMethod): Likewise. (readObject): Remember and reset old BlockDataMode. Track whether object is consumed. Handle TC_ENDBLOCKDATA, TC_PROXYCLASSDESC and TC_LONGSTRING. (defaultReadObject): Set BlockDataMode to false during readFields. (resolveClass): Create new SecurityManager if necessary. Use Class.forName() if null ClassLoader found. (read(byte[],int,int): Copy remaining bytes to data before calling readNextBlock(). (readFields): Set and reset BlockDataMode on call_read_method. Catch NoSuchFieldErrors. (setBlockDataMode): Return old mode. (static): New static code block. * java/io/natObjectInputStream.cc (getField): Removed. (getMethod): Likewise. From-SVN: r63556
2002-01-22Add license clarification.Mark Wielaard1-5/+16
From-SVN: r49104
2000-05-19Jumbo patch:Tom Tromey1-0/+99
* Imported beans and serialization * Updated IA-64 port * Miscellaneous bug fixes From-SVN: r34028