On Mon, Oct 14, 2013 at 2:24 PM, Benedikt Ritter <brit...@apache.org> wrote:
> Hey,
>
> please review http://svn.apache.org/r1532011
>
> I was thinking about deprecating Validate.notNull(T) as well because we now
> have Objects.requireNotNull(Object). The "problem" is that Validate has
> notNull(T, String, Object...) which does substitution in the message, while
> Objects only has requireNotNull(Object, String). Deprecating only
> Validate.notNull(T) would be strange, wouldn't it?

I like our better because we give a message to the NPE which helps it
distinguish with a null de-reference attempt.

My beef is more that I feel like we got our Validate class wrong
because we throw an NPE instead of an ISE.

Gary

>
> Benedikt
>
>
> 2013/10/13 Henri Yandell <flame...@gmail.com>
>
>> Website fixed :)
>>
>>
>> On Sat, Oct 12, 2013 at 10:22 AM, Henri Yandell <flame...@gmail.com>
>> wrote:
>>
>> > I think this is the priority issue:
>> >
>> >     https://issues.apache.org/jira/browse/LANG-894
>> >
>> > If we can't fix and deploy our website, having new code is largely
>> > pointless :)
>> >
>> > I'm guessing we're on some new (yeah I know, probably old by now) site
>> > here and clean up still needs doing. Presumably for most components if
>> Lang
>> > hasn't been fixed.
>> >
>> > Hen
>> >
>> >
>> > On Sat, Oct 12, 2013 at 10:17 AM, Henri Yandell <flame...@gmail.com
>> >wrote:
>> >
>> >> +1 to Java 7, though if that only means a few methods should be removed
>> >> I'd go with deprecating with a note they'll be removed in Lang 4.0.
>> >>
>> >> We should deprecate the time package warning that it will be replaced
>> >> with a new package based on Java 8's new API in Lang 4.0 :) I'm assuming
>> >> 4.0 will be Java 8 focused.
>> >>
>> >> Hen
>> >>
>> >>
>> >> On Sat, Oct 12, 2013 at 4:33 AM, Gary Gregory <garydgreg...@gmail.com
>> >wrote:
>> >>
>> >>> On Oct 12, 2013, at 6:13, Benedikt Ritter <brit...@apache.org> wrote:
>> >>>
>> >>> > Hi guys,
>> >>> >
>> >>> > I'm currently cleaning up the current trunk of lang in preparation of
>> >>> a new
>> >>> > release (as always, any help is appreciated ;-).
>> >>> >
>> >>> > Now I came across methods like ObjectUtils.hashCode(Object), which is
>> >>> > obsolete in Java 7 since we have Objects.hashCode(Object) there. I'm
>> >>> sure
>> >>> > there are more examples. I'd like to mark methods that are obsolete
>> >>> > with Java 7 as deprecated, so that we can remove them with the next
>> >>> major
>> >>> > release (which should target Java 7, IMHO).
>> >>> >
>> >>> > Thoughts? Objections? (and please no "why Java 7?" ;-)
>> >>>
>> >>> Heston Java 7 :) Please make sure there is an exact equivalent in J7
>> >>> before deprecating. As James pointed out, we usually are null safe.
>> >>> >
>> >>> > Benedikt
>> >>> >
>> >>> >
>> >>> > --
>> >>> > http://people.apache.org/~britter/
>> >>> > http://www.systemoutprintln.de/
>> >>> > http://twitter.com/BenediktRitter
>> >>> > http://github.com/britter
>> >>>
>> >>> ---------------------------------------------------------------------
>> >>> To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
>> >>> For additional commands, e-mail: dev-h...@commons.apache.org
>> >>>
>> >>>
>> >>
>> >
>>
>
>
>
> --
> http://people.apache.org/~britter/
> http://www.systemoutprintln.de/
> http://twitter.com/BenediktRitter
> http://github.com/britter



-- 
E-Mail: garydgreg...@gmail.com | ggreg...@apache.org
Java Persistence with Hibernate, Second Edition
JUnit in Action, Second Edition
Spring Batch in Action
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
For additional commands, e-mail: dev-h...@commons.apache.org

Reply via email to