jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sebastian Prehn <sebastian.pr...@planetswebdesign.de>
Subject DateValue.getDate not a copy
Date Mon, 18 Feb 2008 20:37:03 GMT
Hi
I noticed that getDate() in org.apache.jackrabbit.value.DateValue is returned 
by reference. According to the specification it should be a copy. (see. 
6.2.7) Do I miss something or is this a bug?


private Calendar date;

public Calendar getDate()
            throws ValueFormatException, IllegalStateException,
            RepositoryException {
        setValueConsumed();

        if (date != null) {
            return date; // <-- HERE
        } else {
            throw new ValueFormatException("empty value");
        }
    }


-- 
PLANETS-Webdesign - Web Applications
Sebastian Prehn
Balbierstr.8 67663 Kaiserslautern
www.planetswebdesign.de
PGP keyID: 0x3507AF63

Mime
View raw message