mirror of
https://github.com/openjdk/jdk.git
synced 2026-02-16 05:15:22 +00:00
6412286: DOC: LTP: Unspecified NPE in java.beans.DefaultPersistenceDelegate.instantiate method
Reviewed-by: peterz
This commit is contained in:
parent
3b48821ace
commit
46cb7c49ab
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2008 Sun Microsystems, Inc. All Rights Reserved.
|
||||
* Copyright 2000-2010 Sun Microsystems, Inc. All Rights Reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -146,6 +146,8 @@ public class DefaultPersistenceDelegate extends PersistenceDelegate {
|
||||
* @param out The code output stream.
|
||||
* @return An expression whose value is <code>oldInstance</code>.
|
||||
*
|
||||
* @throws NullPointerException if {@code out} is {@code null}
|
||||
*
|
||||
* @see #DefaultPersistenceDelegate(String[])
|
||||
*/
|
||||
protected Expression instantiate(Object oldInstance, Encoder out) {
|
||||
@ -367,6 +369,8 @@ public class DefaultPersistenceDelegate extends PersistenceDelegate {
|
||||
* @param newInstance The instance that is to be modified.
|
||||
* @param out The stream to which any initialization statements should be written.
|
||||
*
|
||||
* @throws NullPointerException if {@code out} is {@code null}
|
||||
*
|
||||
* @see java.beans.Introspector#getBeanInfo
|
||||
* @see java.beans.PropertyDescriptor
|
||||
*/
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2006 Sun Microsystems, Inc. All Rights Reserved.
|
||||
* Copyright 2000-2010 Sun Microsystems, Inc. All Rights Reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -105,6 +105,8 @@ public abstract class PersistenceDelegate {
|
||||
*
|
||||
* @param oldInstance The instance that will be created by this expression.
|
||||
* @param out The stream to which this expression will be written.
|
||||
*
|
||||
* @throws NullPointerException if {@code out} is {@code null}
|
||||
*/
|
||||
public void writeObject(Object oldInstance, Encoder out) {
|
||||
Object newInstance = out.get(oldInstance);
|
||||
@ -158,6 +160,8 @@ public abstract class PersistenceDelegate {
|
||||
* @param oldInstance The instance that will be created by this expression.
|
||||
* @param out The stream to which this expression will be written.
|
||||
* @return An expression whose value is <code>oldInstance</code>.
|
||||
*
|
||||
* @throws NullPointerException if {@code out} is {@code null}
|
||||
*/
|
||||
protected abstract Expression instantiate(Object oldInstance, Encoder out);
|
||||
|
||||
@ -196,6 +200,8 @@ public abstract class PersistenceDelegate {
|
||||
* @param oldInstance The instance to be copied.
|
||||
* @param newInstance The instance that is to be modified.
|
||||
* @param out The stream to which any initialization statements should be written.
|
||||
*
|
||||
* @throws NullPointerException if {@code out} is {@code null}
|
||||
*/
|
||||
protected void initialize(Class<?> type,
|
||||
Object oldInstance, Object newInstance,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user